Problems with Podman in systemd
by Eric Gustavsson
Hi all,
I've been having issues with systemd and Podman. Especially when the
service is restarting.
Starting it initially works without problem, though when restarting I run
into one of two issues.
--reboot--
Jul 08 10:00:49 KeyraGuest1 systemd[1]: Started Bitwarden.
Jul 08 10:00:59 KeyraGuest1 podman[536]: Error: could not get runtime:
error creating tmpdir /run/user/1000/libpod/tmp: mkdir /run/user/1000:
permission denied
Jul 08 10:00:59 KeyraGuest1 systemd[1]: bitwarden.service: Main process
exited, code=exited, status=125/n/a
Jul 08 10:00:59 KeyraGuest1 systemd[1]: bitwarden.service: Failed with
result 'exit-code'.
Jul 08 10:01:29 KeyraGuest1 systemd[1]: bitwarden.service: Service
RestartSec=30s expired, scheduling restart.
Jul 08 10:01:29 KeyraGuest1 systemd[1]: bitwarden.service: Scheduled
restart job, restart counter is at 1.
Jul 08 10:01:29 KeyraGuest1 systemd[1]: Stopped Bitwarden.
And:
Jul 08 10:01:29 KeyraGuest1 systemd[1]: Started Bitwarden.
Jul 08 10:01:39 KeyraGuest1 podman[914]: 2019-07-08 10:01:39.067436802
+0000 UTC m=+1.076662432 system refresh
Jul 08 10:01:53 KeyraGuest1 podman[894]: Error: error creating container
storage: the container name "bitwarden" is already in use by
"34fb34844382c9118be3d377e9f41de6f21485329c824cdd0da109304a2506f3". You
have to remove that container to be able to reuse that name.: that name is
already in use
Jul 08 10:01:53 KeyraGuest1 systemd[1]: bitwarden.service: Main process
exited, code=exited, status=125/n/a
Jul 08 10:01:53 KeyraGuest1 systemd[1]: bitwarden.service: Failed with
result 'exit-code'.
Jul 08 10:02:23 KeyraGuest1 systemd[1]: bitwarden.service: Service
RestartSec=30s expired, scheduling restart.
Jul 08 10:02:23 KeyraGuest1 systemd[1]: bitwarden.service: Scheduled
restart job, restart counter is at 2.
Jul 08 10:02:23 KeyraGuest1 systemd[1]: Stopped Bitwarden.
I've attached the bitwarden_service, which runs podman with --rm, so it
should automatically remove the pod from before. With the first issue with
permission denied, I'm not sure what's causing that either.
Any help would be appreciated :)
Thanks,
Eric Gustavsson
He / Him
Associate Software Engineer
Red Hat <https://www.redhat.com>
IM: Telegram: @SpyTec
<https://www.redhat.com>
5 years, 4 months
SELinux denials on pod member containers for hosts and resolv.conf
by Chris Vale
Hello,
Just starting to experiment with Podman on RHEL8 and I’m seeing SELinux denials (on the host) related to containers I create within a pod for the files automatically created as overlays, most typically hosts and resolv.conf, when performing network related tasks that require name resolution. Of course the containers are unable to read the files in question due to the denials. I don’t see this behavior when deploying containers outside of a pod.
On containers that work as expected I notice the SELinux type for the files in question on the host are container_file_t. However, for containers that experience the denials the SELinux type for the files in question on the host are set to container_var_run_t. Interestingly enough the pod infrastructure container has files labeled with container_file_t
Is this normal behavior for containers added to a pod or perhaps I’m missing something?
5 years, 5 months
CMD file not found
by Boyd Kelly
Hi,
I'm just exploring podman and buildah, but noticed something weird; not
sure if it could be a bug or misconfiguration. But I don't know where to
look for clues as to what is happening. Sometimes when I start a container
I get a file not found error message and then 2 seconds later it starts and
runs just fine. What could be the problem? Thanks for any suggestions.
(This is a container running Fedora 30)
[bkelly@zbox ~]$ podman container start syncthing
Error: unable to start container "syncthing": time="2019-07-04T07:23:41Z"
level=error msg="container_linux.go:346: starting container process caused
\"exec: \\\"/startup.sh\\\": stat /startup.sh: no such file or
directory\"\n"
container_linux.go:346: starting container process caused "exec:
\"/startup.sh\": stat /startup.sh: no such file or directory"
: OCI runtime error
[bkelly@zbox ~]$ podman container start syncthing
syncthing
5 years, 5 months