Optimize Shutdown Behavior - Manual - Industrial Edge - Industrial Edge - Industrial Edge - Documentation of the Industrial Edge Platform - IEM - Hub - Industrial - Device - IED - Edge - IEH

Industrial Edge Platform Operation - Build a Device

Portfolio
Industrial Edge
Product
Industrial Edge
Software version
v25.06
Edition
06/2025
Language
en-US (original)

When Docker is running on a system under high load, it may fail to stop all processes properly during shutdown. To mitigate this issue, you can optimize the shutdown-timeout parameter for the Docker daemon.

The shutdown-timeout parameter specifies the number of seconds Docker will wait for containers to stop before forcefully terminating them during a shutdown or restart.

To test and optimize this setting for your system:

  1. Locate the Docker daemon configuration file, typically found at /etc/docker/daemon.json.

  2. Open the file and add or update the shutdown-timeout parameter. For example:

{
    "shutdown-timeout": 15
}

In this example, Docker will wait 15 seconds for containers to stop before forcefully terminating them.

  1. Save the file and restart the Docker daemon for the changes to take effect.
sudo systemctl restart docker
  1. Test the new shutdown-timeout value by performing a system shutdown or Docker restart, and observe the behavior. Adjust the value as needed, based on the time required for your containers to stop gracefully.

By optimizing the shutdown-timeout parameter, you can ensure that Docker has sufficient time to properly stop all running containers, even under high system load conditions.