What is the difference between KILL and STOP commands?

KILL and STOP are two commands in docker used to stop a container from execution. A docker STOP command issues a SIGTERM signal to the main process running within the container, while KILL command issues a SIGKILL signal to the process.

  • docker STOP leads to a safe exit
  • docker KILL leads to an unsafe exit
  • if a process doesn't exit for a STOP command within a specified timeout, docker issues a KILL command implicitly.

> docker stop|kill <container_id>

Docker Posted May 17, 2020

You can now show your support. 😊

We use cookies to provide you with a great user experience, analyze traffic and serve targeted promotions.   Learn More   Accept