Cleanup and checkpoints