Tag Archives: OCI runtime create failed: container with id exists

[Solved] Docker Container Start Error: OCI runtime create failed: container with ID exists

environment

System: CentOS 7.6

Docker:20.10.7

symptom

After executing the following startup command, docker start mysqlserver an exception occurs and an error is reported

1 docker start mysqlserver
2 Error response from daemon: OCI runtime create failed: container with id exists: c29c0bc9836880aa883d1ac7e50da56656ed9b2c5499831f3610d775997aa5f2: unknown
3 Error: failed to start containers: mysqlserver

Solution

 1 # Go to the following directory
 2 cd /run/docker/runtime-runc/moby
 3 
 4 # Run the ls command to see a similar display
 5 ls
 6 2901da5462f792296b36ce7e982d8ef66233fce3c78c8c150522893625768e56
 7 c29c0bc9836880aa883d1ac7e50da56656ed9b2c5499831f3610d775997aa5f2
 8 ed4c1c5e03c74b3ce4c41aafbb5f276064d51546f8359ed493b3623a0baaf648
 9 
10 # Delete folder by rm -rf command
11 # For example, delete the folder corresponding to the error id (c29c0bc9836880aa883d1ac7e50da56656ed9b2c5499831f3610d775997aa5f2) in the symptom
12 rm -rf c29c0bc9836880aa883d1ac7e50da56656ed9b2c5499831f3610d775997aa5f2/
13 
14 # Delete and re-execute the command to start the container
15 docker start mysqlserver