LoginSignup
1
2

More than 5 years have passed since last update.

docker daemonのrestart時にrestart=alwaysなコンテナが起動しない問題

Posted at

docker runで--restart=alwaysにして起動したコンテナが、docker daemonの再起動後に立ち上がったり、立ち上がらなかったりする状況なので、調査過程をメモ。

ubuntu系なのでtail -f /var/log/upstart/docker.logでログを確認。
service docker stopを実行すると、そこそこの頻度で以下のようなログが出力される。

No endpoints in sandbox while trying to remove endpoint <container-name>

この時、そのコンテナは次回に service docker startしても立ち上がってこない。

docker inspect でコンテナ起動時のエラーを見てみると、

"failed sandbox add: failed to create new sandbox: open /var/run/docker/netns/default: permission denied"

とのこと

1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2