foundryvtt / foundryvtt

Public issue tracking and documentation for Foundry Virtual Tabletop - software connecting RPG gamers in a shared multiplayer environment with an intuitive interface and powerful API.
https://foundryvtt.com/
198 stars 10 forks source link

Backups will fail silently if they run out of disk space #10859

Open jsavko opened 3 weeks ago

jsavko commented 3 weeks ago

What happened?

If you run out of disk space while a backup is being created it will fail silently.

image

The disk space check appears to only happen when creating a snapshot backup, and not when individually backing up modules or worlds.

What ways of accessing Foundry can you encounter this issue in?

Reproduction Steps

  1. Fill up your disk space.
  2. Backup a single module or world
  3. Foundry Fails to make the backup, but continues to wait for the backup to finish

Backupoutput.webm

What core version are you reporting this for?

11.315

Relevant log output

FoundryVTT | 2024-05-07 11:02:13 | [info] createBackup archive progress - 27%
FoundryVTT | 2024-05-07 11:02:14 | [info] createBackup archive progress - 28%
FoundryVTT | 2024-05-07 11:02:16 | [info] createBackup archive progress - 29%
FoundryVTT | 2024-05-07 11:02:17 | [info] createBackup archive progress - 30%
FoundryVTT | 2024-05-07 11:02:18 | [error] ENOSPC: no space left on device, write
Error: ENOSPC: no space left on device, write
    at Object.writeSync (node:fs:929:3)
    at Module.writeFileSync (node:fs:2328:26)
    at #t (file:///home/jsavko/foundry/resources/app/dist/packages/package-backups.mjs:1:5340)
    at WriteStream.<anonymous> (file:///home/jsavko/foundry/resources/app/dist/packages/package-backups.mjs:1:1879)
    at WriteStream.emit (node:events:517:28)
    at emitCloseNT (node:internal/streams/destroy:132:10)
    at emitErrorCloseNT (node:internal/streams/destroy:117:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
FoundryVTT | 2024-05-07 11:02:39 | [warn] Found JSON file '/home/jsavko/foundryuserdata/Backups/modules/tabletop-rpg-music/module.tabletop-rpg-music.2024-05-07.1715104890711.json' that was not a valid backup manifest: Unexpected end of JSON input
FoundryVTT | 2024-05-07 11:02:50 | [info] Writing backup for module 'tabletop-rpg-music'.
FoundryVTT | 2024-05-07 11:02:50 | [error] ENOSPC: no space left on device, write
Error: ENOSPC: no space left on device, write
    at Object.writeSync (node:fs:929:3)
    at Module.writeFileSync (node:fs:2328:26)
    at #t (file:///home/jsavko/foundry/resources/app/dist/packages/package-backups.mjs:1:5340)
    at WriteStream.<anonymous> (file:///home/jsavko/foundry/resources/app/dist/packages/package-backups.mjs:1:1879)
    at WriteStream.emit (node:events:517:28)
    at emitCloseNT (node:internal/streams/destroy:132:10)
    at emitErrorCloseNT (node:internal/streams/destroy:117:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
FoundryVTT | 2024-05-07 11:02:50 | [info] createBackup archive progress - 0%

Bug Checklist