KOPANO-BACKUP(8)

πŸ“¦ version 8.7.0, in ubuntu jammy

πŸ’– KOPANO-BACKUP(8) πŸ’–

okay bestie, listen up β€” this is kopano-backup, the Kopano Backup tool, and it's about to become your new favorite thing in the whole entire world. no cap.


✨ SYNOPSIS ✨

kopano-backup [OPTION...] [PATH]

πŸŽ€ DESCRIPTION πŸŽ€

So like. kopano-backup is the tool you use to make backups of user data β€” or to restore them. We're talking one or more stores, or folders. Emails, calendar items, contacts, etc., plus user settings like rules, permissions and WebApp settings. the whole vibe. πŸ’…

Backups happen incrementally, okay? Which means: if a backup directory already exists for a given user/store, then only the changes that happened since the last backup run get processed. not me being efficient or anything. ✨

And for backup (not restore!!) you can process multiple stores in parallel. obsessed.

There are also options to peek inside a backup directory, and to restore just individual messages/items. slay.


πŸ‘‘ OPTIONS πŸ‘‘

  • --auth-pass, -P PASS β€” authenticate with the password you specify. πŸ”
  • --auth-user, -U NAME β€” authenticate as the user you specify.
  • --company, -C NAME β€” back up the users and public store for the company you specify.
  • --config, -c FILE β€” load your configuration settings from the file you specify.
  • --deletes YESNO β€” backup/restore/show deleted items and folders. The tea here: when you're backing up, the default is to keep data that's been soft- or hard-deleted. When you're restoring, the default is to NOT restore that data. And when you're viewing the contents of a backup directory, the default is to show it. three different defaults, iconic behavior tbh.
  • --differential β€” create 'differential' backup(s), containing all the changes since the previous or regular backup(s), in separate directories called 'differential/username/N'. You can inspect differential backups with --index and --stats. Also go look at --merge. πŸ¦‹
  • --folder, -f PATH β€” backup/restore only the folder(s) with the path you specify. You can specify multiple folders. Subfolders can come along for the ride with --recursive.
  • --index β€” list the messages/items inside the backup directory you specify, in CSV format. For every message/item you get sourcekeys, the respective folders, last modified dates and subjects. receipts! πŸ“‹
  • --merge β€” merge 'differential' backups for a given user into the regular backup. See --differential.
  • --log-level, -l NAME β€” specify the log-level, for example 'error', 'warning' 'info' or 'debug'.
  • --only-meta β€” only backup/restore meta data, like settings, permissions and rules.
  • --output-dir, -O PATH β€” create/update backup directories in the directory you specify, instead of the local directory.
  • --period-begin, -b DATE β€” backup/restore data that was last modified on or after the date you specify (YYYY-MM-DD).
  • --period-end, -e DATE β€” backup/restore data that was last modified before the date you specify (YYYY-MM-DD).
  • --purge N β€” permanently delete data from the backup directory that's been marked as deleted more than the number of days you specify ago. > bestie this one is PERMANENT. like gone gone. 🫣
  • --recursive β€” when you specify folders (--folder), also include subfolders in backup/restore.
  • --restore β€” restore the contents of the backup directory you specify. The respective store is determined automatically, but you can also specify it explicitly, for example with --user.
  • --restore-root PATH β€” when restoring, put the data under a folder with the path (or name) you specify, for example 'some_folder' or 'Inbox/some_subfolder'.
  • --server-socket, -s SOCKET β€” connect to the storage server through the socket you specify.
  • --sourcekey SOURCEKEY β€” restore the message/item with the sourcekey you specify (as shown using --index). Must be combined with --restore. You can specify multiple sourcekeys. πŸ’…
  • --skip-attachments β€” don't backup/restore attachments.
  • --skip-deleted β€” don't backup/restore the deleted mail folder.
  • --skip-junk β€” don't backup/restore the junk folder.
  • --skip-meta β€” don't backup/restore meta data, like settings, permissions and rules.
  • --skip-public β€” don't backup/restore the public store.
  • --ssl-key, -k FILE β€” specify the SSL key file.
  • --ssl-pass, -p PASSWORD β€” specify the SSL key password.
  • --stats β€” list the folders inside the backup directory you specify, in CSV format. Folder sizes get shown for each folder. πŸ“Š
  • --store, -S GUID β€” backup the store you specify. Instead of a GUID you can also say 'public', to denote the public store.
  • --user, -u NAME β€” backup data of the user you specify. You can specify multiple users. By default, all users are included. When restoring, restore into the store of the user you specify.
  • --worker-processes, -w N β€” when backing up data from multiple stores, process those stores in parallel, using the number of workers you specify. ✨

🌈 EXAMPLES 🌈

Backup user 'henk', creating/updating a backup directory with the same name:

kopano-backup -u henk

Restore the same user (possibly on another server):

kopano-backup --restore henk

Backup users 'henk' and 'fred', in parallel, in a specified directory:

kopano-backup -u henk -u fred -w 2 -O backups

Search for a message with a specific subject:

kopano-backup --index backups/henk | grep subject

Restore a single message:

kopano-backup --restore backup/henk --sourcekey 72EE69D0A283408E89BFC35AD251E9B3830000000000

Backup calendars of all users:

kopano-backup -f Calendar -O calendars

Recursively restore inbox of 'fred' into store of 'henk', in a certain subfolder:

kopano-backup --restore fred -f Inbox -u henk --recursive --restore-root from_fred

Restore everything last modified in 2014:

kopano-backup --restore fred -b 2014-01-01 -e 2015-01-01

Create differential backup for 'fred':

kopano-backup --differential -u fred

Inspect specific differential backups:

kopano-backup --stats differential/fred/1
kopano-backup --stats differential/fred/2

Merge differential backups for 'fred':

kopano-backup --merge fred

πŸ’œ AUTHOR πŸ’œ

Written by Kopano.


and that's the whole page bestie, we ate and left no crumbs πŸ“ β€” this was Kopano 8, from November 2016, and yeah it lives in the KOPANO-BACKUP(8) section of the manual. go forth and back up your life. πŸŽ€βœ¨πŸ¦‹

πŸ“¦ where this page comes from