Docker Overlay FS

In the "Install docker-ce and docker compose packages on App Server 1 ", I was getting the error:

level=error msg=“Handler for POST /v1.52/containers/create returned error: failed to mount /tmp/containerd-mount2790912164: mount source: "overlay", target: "/tmp/containerd-mount2790912164", fstype: overlay, flags: 0, data: "workdir=/var/lib/containerd/io.containerd.snapshotter.v1.overlayfs/snapshots/3/work,upperdir=/var/lib/containerd/io.containerd.snapshotter.v1.overlayfs/snapshots/3/fs,lowerdir=/var/lib/containerd/io.containerd.snapshotter.v1.overlayfs/snapshots/2/fs,userxattr,index=off", err: invalid argument”

Chatgpt told me that this is due to Docker not being able to mount OverlayFS on the server due to the underlying filesystem being unsupportive of Overlay FS. So as per its instruction I edited the /etc/docker/daemon.json and added the storage driver as:

{
  "storage-driver": "vfs"
}

docker run hello-world worked after this.

Was all this complication by design? Were we meant to investigate and find out about OverlayFS? If not, I think this is a bug

No, I suspect (as happens) that ChatGPT led you somewhat astray. I would guess rather that you need to install, enable and the docker service as root, using sudo.