Home >Operation and Maintenance >Docker >How to check the data path of docker
The default Docker storage location is:/var/lib/docker
Command to view the specific location
docker info | grep "Docker Root Dir"
The specific docker container storage location:
docker ps -a
docker inspect container id | grep "volumes" //View data directory_data
docker inspect container id | grep "ResolvConfPath" //View docker container startup Configuration file directory
Modify the storage location:
The simplest way is to mount the partition to this directory. Since there is data in the data disk, modify the storage path of the image and container to achieve the purpose. This is achieved through soft connections.
For more related tutorials, please pay attention to the docker tutorial column on the PHP Chinese website.
The above is the detailed content of How to check the data path of docker. For more information, please follow other related articles on the PHP Chinese website!