Skip to content

Archives and Backups

Olivier van Helden edited this page Nov 15, 2026 · 7 revisions

Back up configuration and data

Back up a grid, or a simulator when named:

opensim backup my-grid
opensim backup my-grid my-grid.welcome --logs --archives --output /srv/backups --keep 7

A backup includes configuration, data, and databases. --logs and --archives add logs and user archives. --keep N retains the newest N backups in the series.

Without --output, backups go to the backup root, a folder per grid and, for a simulator, one per simulator: <BackupRoot>/<grid>/ and <BackupRoot>/<grid>/<simulator>/. BackupRoot is a setting of opensim.conf; the default is /var/backups/opensim on a system install, a backups folder beside the data otherwise. It is never inside the data. The backup root must exist (a mounted storage, for example): the command stops with a message when it does not.

A grid backup holds the databases of Robust and of all its simulators. A restore command does not exist yet: unpack the archive and load the dumps of db/ by hand.

On a fleet where the storage box is mounted under /var/backups, a setting such as BackupRoot = /var/backups/localhost/opensim/opensim-charm groups the backups by user, then by format (opensim-charm is the 3.x series).

Daily backup

The package ships a systemd timer, not enabled by default:

sudo systemctl enable --now opensim-backup.timer

It runs opensim backup --keep 14 every day around 03:30 as the opensim user, which keeps the last 14 backups of each series.

Region backups (OAR)

opensim backup --oars [GRID [SIMULATOR]] [--keep N] saves the OAR of every enabled region of the simulators that run, to <BackupRoot>/<grid>/<simulator>/<grid>-<simulator>-<region>-<date>.oar (the names sort by region, then by date). --keep N keeps the N newest of each region. A simulator that does not run is skipped, a region that does not answer within 15 minutes is reported as failed, and the others go on. The grid backup does not include them (--archives is for the OARs and IARs saved by hand). Inventories (IAR) are not scheduled: they need the password of the avatar.

A second timer, not enabled by default, runs it every Sunday around 05:00 with --keep 4:

sudo systemctl enable --now opensim-backup-oar.timer

Inventory archives (IAR)

Save an avatar inventory and load it later:

opensim save iar my-grid my-grid.welcome First Last /path/to/inventory
opensim load iar my-grid my-grid.welcome First Last /path/to/inventory

The save command can prompt for the avatar password. OPENSIM_IAR_PASSWORD can provide it non-interactively. Add --merge to a load when inventory contents should be merged.

Region archives (OAR)

Save or load a region archive through a running simulator:

opensim save oar my-grid my-grid.welcome
opensim load oar my-grid my-grid.welcome /path/to/region.oar

Without a filename, save creates a timestamped archive in the grid's data area; load uses the newest matching archive there. Use --merge when loading should merge with the current region. Run opensim save --help or opensim load --help for archive-specific options.

Clone this wiki locally