Andrei Berenda
Andrei Berenda

Reputation: 1986

Cannot run or delete images or container (fail overlay2)

When I want to delete all my container I see that error

Command:

docker rm $(docker ps -aq)

the error is:

Error response from daemon: driver "overlay2" failed to remove root filesystem for 4bf2fc329d2fab3c055dd136a740c5ee2000e35e26fea6a38c94801fd8dfb109: remove /var/lib/docker/overlay2/7991f36adaa25d4046ef6106c3da8bbbb1f3ce7478b07a30021669a7783b4b6c/diff/root/.ipython: read-only file system

Also I have tried

docker rm -f $(docker ps -aq)

But the result was the same

Also I have tried to delete that image:

docker rmi -f <images_id>

And the result was the same.

How can I delete the container?

Upvotes: 10

Views: 20878

Answers (1)

VonC
VonC

Reputation: 1324248

Check what your filesystem is: moby/moby issue 9939 reports:

Does the overlay2 driver work on a btrfs file system?
The documentation says only ext4 and xfs are supported.

See also if docker system prune can help.

Restarting the computer, to clear any locked file can help too.

Upvotes: 9

Related Questions