I managed to find the containers under directory /var/lib/docker/containers
, but I can't find the images.
What are the directories and files under /var/lib/docker
?
I managed to find the containers under directory /var/lib/docker/containers
, but I can't find the images.
What are the directories and files under /var/lib/docker
?
On Debian Unstable/Sid,
docker info
to find system-wide information.images are stored at
/var/lib/docker/image/overlay2/imagedb/content
andcontainers are stored at
/var/lib/docker/containers
docker version
18.06.0-ce
, API version1.38
The contents of the
/var/lib/docker
directory vary depending on the driver Docker is using for storage.By default this will be
aufs
but can fall back tooverlay
,overlay2
,btrfs
,devicemapper
orzfs
depending on your kernel support. In most places this will beaufs
but the RedHats went withdevicemapper
.You can manually set the storage driver with the
-s
or--storage-driver=
option to the Docker daemon./var/lib/docker/{driver-name}
will contain the driver specific storage for contents of the images./var/lib/docker/graph/<id>
now only contains metadata about the image, in thejson
andlayersize
files.In the case of
aufs
:/var/lib/docker/aufs/diff/<id>
has the file contents of the images./var/lib/docker/repositories-aufs
is a JSON file containing local image information. This can be viewed with the commanddocker images
.In the case of
devicemapper
:/var/lib/docker/devicemapper/devicemapper/data
stores the images/var/lib/docker/devicemapper/devicemapper/metadata
the metadataWhen using Docker for Mac Application, it appears that the containers are stored within the VM located at:
In Docker for Windows, the logs are here:
%USERPROFILE%\AppData\Local\Docker
On Ubuntu you can "play" with images running
Actually, images are stored within
/var/lib/docker/aufs/diff
check for the docker folder in
/var/lib
the images are stored at below location: