overlay2 issue in docker not supported

Docker Error Creating Overlay Mount To Invalid Argument

Docker Error Creating Overlay, If you’re facing an issue related to Docker storage driver type like “

/usr/bin/docker-current: Error response from daemon: error creating overlay mount to /var/lib/docker/overlay2/7e9da3eaf646f3060f2a6be2fe3e677207e75e49662dfaf04c5c02396106509d-init/merged: invalid argument.”. By default, Docker Storage driver is Overlay2 which is recommended. 

There are different type of Storage driver available in Docker.

1. Overlay2 : This predefined Storage driver and it supports all Operating System.

2. aufs : Preferable Storage Driver for Docker 18.06 and older. If you run it on Ubuntu 14.04 on Kernel 3.13 which has no support to overlay2.

3. Devicemapper : This supported but requires direct-lvm for production environment.

4. vfs : This Storage Driver basically used for testing purpose. It gives a poor performance and can be used where no copy-on-write filesystem.

Check Out : Docker Service Start to Failed

What’s the solution for this?

First you will need to find Storage type of your docker installed on the machine.

Docker info

You will have to troubleshoot with following commands until you don’t get resolve this issue.

Check Out :  Check Running Container In Docker

You can also change Backing filesystem from xfs to ext4 . In most cases, it works.

You can also try this to find the storage type. If ftype is 1, this supports overlay2

xfs_info /var/lib/docker/overlay2 | grep ftype

In my case, it’s 0 and this does not support overlay2

Another way to find Storage driver type

Check Out : Take Backup of a Container In Docker

docker info | egrep ‘^(Server Version|Storage)’

After all these you still have this issue then you may define this code in file /etc/docker/daemon.json and restart the docker service

{ “storage-driver”: “devicemapper” }{}

As Docker CE installed On Centos, Supports both devicemapper and vfs Storage driver.

Check Out : Install Rancher Server

Now i will try to install Rancher Server and it’s working.

You’re done

Sponsored

LEAVE A REPLY

Please enter your comment!
Please enter your name here

11 − four =