0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

docker stopがpermission deniedで失敗するときの対処法(Linux / AppArmor)

0
Last updated at Posted at 2026-05-11

症状

docker stopdocker compose downでコンテナを停止できない。

Error response from daemon: cannot stop container: <id>: permission denied

解決

AppArmorを一時停止してからコンテナを停止する。

sudo systemctl stop apparmor
docker stop <container>      # または docker compose down 等
sudo systemctl start apparmor

原因

Dockerデーモンの再起動やシステムアップデート後にAppArmorの古いプロファイルが残り、コンテナへのシグナル送信がブロックされる。AppArmorを停止すると、このプロファイルによるアクセス制御が無効になるため、Dockerがコンテナを正常に停止できるようになる。

参考

0
0
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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?