2

When I run podman run --init, I get

$> podman run --init -ti cp /sbin/init
Error: container-init binary not found on the host: stat /usr/libexec/podman/catatonit: no such file or directory

But I can easily verify that there is an init there,

$> podman run cp ls -- /sbin | grep init
init
telinit

What is catatonit? Why am I getting this error and how can I resolve it?

Evan Carroll
  • 28,578
  • 45
  • 164
  • 290

2 Answers2

3

The error isn’t complaining about /sbin/init but about /usr/libexec/podman/catatonit, which points to /usr/libexec/catatonit/catatonit. The latter is provided by the catatonit package which is presumably not installed on your system (it’s only a weak dependency for podman).

On Fedora,

sudo dnf install catatonit

should fix things (but the package should be installed for you if you install podman).

On Debian, you’re running into #971815; you’ll have to either wait for a fix for that bug, or provide your own container init. One method is

sudo ln -sf /usr/bin/docker-init /usr/libexec/podman/catatonit

or configure podman to use docker-init directly instead of catatonit (in ~/.config/containers/containers.conf).

[containers]
init_path="/usr/bin/docker-init"
Evan Carroll
  • 28,578
  • 45
  • 164
  • 290
Stephen Kitt
  • 411,918
  • 54
  • 1,065
  • 1,164
0

You can install container-init binary and define it p in containers.conf, such as tini:

[containers]
init_path= "/usr/bin/tini"

Maybe don't need it at all:

[containers]
init = false