Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Creating Backups

Back up your server’s data to a physical drive or a network folder.

Important

Creating backups is an essential responsibility of self-hosting. If you do not make backups, you will eventually lose your data.

Watch The Video

Important Info

  1. You can create backups to a physical drive plugged directly into your server, or over-the-air to another device on the same LAN (a network folder).

  2. Backups are encrypted using your master password. If you change your password prior backups retain the original password.

  3. Services may choose to exclude certain files or folders from the backup. For example, Bitcoin excludes the blockchain, since it can be recovered by re-syncing.

  4. Backups can take minutes or hours to complete, depending on your hardware and quantity of data.

  5. To back up a service, StartOS first stops it (if it was running), performs the backup, then restarts it — but only if it was running beforehand. A service that was already stopped stays stopped. Consequently a service cannot be used while it is backing up, though you may continue to use your server and other services in the meantime.

  6. Upon completion, StartOS issues a backup report, indicating which services were backed up, as well as any errors.

  7. Backups are differential — each new backup to the same target overwrites the previous one. To maintain multiple backup points, use multiple backup targets.

  8. The backup targets list shows the free space available on each drive and network folder, so you can confirm your backup will fit before you start.

  9. Backups taken from a specific system architecture (x86, ARM, RISC-V) are backed up for just that architecture. If restored to another architecture, they will likely need to be reinstalled to run efficiently.

  10. The backup format changed. New backups are written to a StartOSBackupsV2 folder on the target, replacing the older StartOSBackups (V1) format. StartOS helps you clean up the obsolete V1 data:

    • When you select a target that still holds a V1 backup for this server, StartOS warns you before backing up and shows how much free space remains on the target (see below).
    • After a backup completes, if the target still contains this server’s V1 backup, StartOS raises a notification reminding you it is no longer needed.
    • On the Create Backup page, any target holding this server’s V1 backup shows a Delete old backup button — whether or not a new (V2) backup exists yet. After you confirm, StartOS removes this server’s old V1 backup to reclaim space; your current StartOSBackupsV2 backup — and any backups belonging to other servers that share the target — are untouched. If this server has no current (V2) backup on that target, StartOS asks for an extra confirmation first, since deleting the old backup would leave this server with no backup there.

    Warning

    Before backing up, check the free space remaining on the target and make sure your selected services will fit. If space is tight, use the Delete old backup button to reclaim the space this server’s old backup occupies, or choose another drive.

Best Practices

Even with proper backups the risk of data corruption is always non-zero. Therefore it is recommended to take additional care when backing up highly valuable or irreplaceable data like a lightning node:

  • High quality SSDs should be favored over HDDs as a backup target.
  • Backup to multiple targets.
  • If backing up to multiple targets make sure all backups are up to date.

Physical Drive

EXT4 is the recommended format of your backup drive. fat32 and exFAT are not recommended and may not work.

Warning

Backing up to USB thumb drives or SD card media is not recommended unless you are using high-endurance, high-quality storage. Low-quality flash memory is prone to corruption and failure over time.

If you are using a Raspberry Pi, backup drive must be self-powered, or be connected via a powered USB hub, to prevent possible data corruption.

Network Folder

A network folder backup sends your encrypted backup over the LAN to a shared folder on another device. First, create a shared folder on the target device, then connect to it from StartOS.

Step 1. Create a Shared Folder

  1. Identify or create a folder to store your server backups.

    Tip

    This folder can be located on an external drive connected to your Mac.

  2. Go to System Settings > General > Sharing and click the “info” icon.

  3. Click the toggle to enable file sharing, then click the “plus” icon and select your backups folder.

  4. Click “Options” and ensure “Share files and folders using SMB” is checked.

  5. Check the box next to the user who owns the folder, then click “Done”.

Tip

You can find the hostname at the top of the sharing window. The hostname will be an address beginning with smb://. To use as hostname, disregard the smb:// and simply enter the IP address that follows it. Alternatively, you can use the computer hostname (open Terminal and type hostname). Either method will work.

Step 2. Connect from StartOS

  1. In StartOS, go to System > Create Backup.

  2. Click “Open New”.

  3. Complete the form:

  1. Hostname: The hostname or IP address of your Mac (see the tip in the section above).
  2. Path: The name of your shared folder, not the full directory path.
  3. Username: Your Mac user who owns the shared folder.
  4. Password: Your password for the above user.

Warning

If you receive Filesystem I/O Error mount error(13): Permission denied, ensure you have entered the correct values. The hostname can be particularly tricky.