Explain `live-restore` and when to use it.
AdvancedScenarioLimits, logging, health checks and restarts
Answer
Situation read → Daemon upgrades would otherwise stop all containers.
What I'd do → Set {"live-restore": true} in daemon.json, systemctl reload docker (SIGHUP), then upgrades or restarts of dockerd leave containers running (containerd-shim keeps them). Not supported in Swarm mode and certain config changes still need container recreation.
Why → Reduces downtime during patching.
Interview tip → Cannot be combined with Swarm.
More on Limits, logging, health checks and restarts
A Java container is OOM-killed at 512 MB. Why isn't the heap the whole story?IntermediateHow do you cap CPU and memory for a container and what happens on exceed?BeginnerLatency spikes though CPU usage looks low (50%).Advanced`docker logs` is empty but the app is running.BeginnerConfigure log rotation globally.BeginnerShip container logs to a central system.Intermediate