Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ERROR: readlink /var/lib/docker/overlay2: invalid argument

This morning I was getting this error when executing docker-compose up:

docker-compose up

ERROR: readlink /var/lib/docker/overlay2: invalid argument

like image 440
Daniel Ramos Avatar asked Mar 25 '19 09:03

Daniel Ramos


3 Answers

I think the easier way is to remove all cache and containers and pull them again.

docker system prune --all
docker volume prune 
docker-compose up

I think this will solve the error.

like image 124
Tony Aziz Avatar answered Nov 15 '22 02:11

Tony Aziz


The problem was that one or more image where corrupted.

I had to start running my images one by one with:

docker-compose up <service 1> <service 2>...

until I found the broken one, which was the backoffice image.

Then I rebuilt that image with:

docker-compose build --no-cache <broken service>

and finally everything started working nicely again.

like image 31
Daniel Ramos Avatar answered Nov 15 '22 01:11

Daniel Ramos


To troubleshoot run with the verbose flag --verbose

 docker-compose.exe --verbose -f ./compose.yml up

In my case I had to remove specific corrupt images that were only indicated when running up with the verbose flag

like image 2
Aussie Ash Avatar answered Nov 15 '22 00:11

Aussie Ash