Keep GPU jobs running: find the failure and test the recovery
Find the first failure, reproduce it on a small run and check that saved progress can be restored.
Scale up only after both the job and its recovery work.
The short version
A memory error, a stalled worker and a bad restart need different fixes. Before changing anything, save the error, input, code version, environment and last completed step.
We’ll follow a hypothetical training run that fails at minute 95, with its latest complete checkpoint saved at minute 90.
- 01Reproduce the failureReducing the batch size helps only with the parts that depend on the batch.
- 02Add GPUs graduallyOne worker’s failure can cause errors in all the others, so investigate the earliest relevant error first.
- 03Record the environmentThe scheduler starts and places jobs; your training code is responsible for loading saved progress.
- 04Keep changes comparableFine-tuning and reinforcement learning can change quality and resource use even when the job completes successfully.
- 05Test recoveryA checkpoint only counts once it has been restored: load it in a fresh process and continue the run.
