Home > Article > Operation and Maintenance > How to connect to docker after restarting
How to connect to docker after restarting?
How to reconnect to docker after restarting the server
The azure cloud service was inexplicably disconnected today (it automatically restarted), and I broke out in a cold sweat. Fortunately, docker There is storage.
Check the containers that were closed due to restart
docker ps -a
You can see that two containers were closed before 13 minutes
Restart the container
docker restart 1236a
If restarted If it fails, check if the graphics card driver is normal. If not,
sudo nvidia-persistenced --persistence-mode
Check if the container is restarted
docker ps
See if pycharm can update the code. Generally, it can be updated after restarting
Set up a permanent restart and self-start
sudo docker update --restart=always 1236a
This restart and self-start operation can be done in one step in docker run
docker run --restart=always
Recommended learning: docker tutorial.
The above is the detailed content of How to connect to docker after restarting. For more information, please follow other related articles on the PHP Chinese website!