Skip to content

deucalion register

Uses a drive as it is for backups: creates a Deucalion-Backup folder on it (or reuses the one that is there) and adds it to your backup drives. Nothing on the drive is erased or changed.

Use it to:

  • back up to a drive you formatted yourself (NTFS, exFAT, ext4…), without a copy of Deucalion on it (for that, use setup-drive --layout as-is);
  • add a backup drive you already have, for example on a new computer;
  • make an existing backup drive the default one.
$ deucalion register --help
usage: deucalion register [-h] [--name NAME] [--default] path

use a drive (or a folder on it) for backups

positional arguments:
  path         where the drive is mounted, e.g. /media/you/MyDrive

options:
  -h, --help   show this help message and exit
  --name NAME  a friendly name for this backup drive
  --default    make it the default drive
Option What it does
path Where the drive is mounted (/media/alex/MyDrive), a folder on it, or an existing Deucalion-Backup folder.
--name NAME A name for this backup drive. Default: the folder's name. Only used when a new backup folder is created.
--default Make it the default drive. The first drive you register is always the default.

How the path is used

  • If path is a backup folder (it has .deucalion/drive-id inside), that backup is registered.
  • If path contains a Deucalion-Backup backup folder, that one is registered.
  • Otherwise a new Deucalion-Backup folder is created inside path.

Then it prints what it found:

$ deucalion register "/media/alex/Alex Backup2/Deucalion-Backup" --default
Registered backup drive 'Alex Backup'.
  Backup folder: /media/alex/Alex Backup2/Deucalion-Backup
  Filesystem:    exfat  (names stored exFAT-safe)
  Encrypted:     yes
  Free space:    5.3 GB
  • Filesystem and how names are stored: as they are on Linux filesystems (ext4, Btrfs, XFS…), exFAT-safe on others (exFAT, NTFS, FAT).
  • Encrypted: whether the drive is encrypted (VeraCrypt or LUKS, once unlocked).

A folder on the disk your system runs from is refused:

$ deucalion register ~/Backups
/home/alex/Backups is on the same disk as your system. A backup there would be lost together with the system. Choose an external drive.

Changing the default drive

Register the backup folder again with --default. Use the exact path that deucalion targets shows for that drive, so you don't create a new backup folder somewhere else by mistake:

deucalion targets
deucalion register "/media/alex/Alex Backup2/Deucalion-Backup" --default

Registering a drive again keeps everything Deucalion knows about it, such as how to unlock it.

Encrypted drives

To add an encrypted backup drive on a new computer, use deucalion open: it finds the encrypted backup, unlocks it, and registers it, remembering how to unlock it next time. register only sees a drive that is already unlocked.

Exit codes

0 registered; 1 an error (for example "… is not a folder.").