Skip to content

Commit

Permalink
Stop heartbeats before snapshotting
Browse files Browse the repository at this point in the history
  • Loading branch information
mattnappo committed Jul 12, 2024
1 parent 2f73121 commit f3c04c6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions modal/_container_io_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -609,6 +609,9 @@ async def memory_snapshot(self) -> None:
if self.checkpoint_id:
logger.debug(f"Checkpoint ID: {self.checkpoint_id} (Memory Snapshot ID)")

# Heartbeats can leave the modal.sock file open, causing gVisor to crash
self.stop_heartbeat()

await self._client.stub.ContainerCheckpoint(
api_pb2.ContainerCheckpointRequest(checkpoint_id=self.checkpoint_id)
)
Expand Down

0 comments on commit f3c04c6

Please sign in to comment.