Alfresco BART usage:
But what really modes are? With modes I mean different ways to use Alfresco BART depending of what do you want to do, for instance:
- backup: runs an incremental backup or a full if first time
- restore: runs the restore, wizard if no arguments, see below more commands with arguments [set] [date] [dest], while [set] can also be “all” for all sets.
- verify: verifies the backup, it compares what you have backed up and what you have in your live system.
- collection: shows all the backup sets already in the backup archive that might be restored.
- list: lists the files currently backed up in the archive. It shows files contained in the last backup.
- no value: use all backup sets
- index: use index backup set (group) for selected mode.
- db: use data base backup set (group) for selected mode.
- cs: use content store backup set (group) for selected mode.
- files: use rest of files backup set (group) for selected mode.
Now lets see how to use Alfresco BART.
To make a backup:
NOTE1: if first time, it makes a full backup
NOTE2: you should add this command to your root crontab with something like “0 5 * * * /path/to/alfresco-bart.sh backup” (without quotes) if you want to run your backup daily at 5AM (after Alfresco’s nightly backups and maintenance jobs).
NOTE3: running command above with without any data sets (index, db, cs or files) it will perform a backup of all data sets configured in alfresco-bart.properties. You can run “./alfresco-bart.sh backup files” to only perform a backup of your configuration files, installation and customization files or “./alfresco-bart.sh backup cs” to create a backup (full if first time or incremental if not) of your contentstore and additional stores configured.
Commands and options to restore backup:
To restore an existing backup guided by the wizard:
To restore the last (now) existing backup of all sets (all) and leave it in /tmp:
To restore a DB backup from 14 days ago to /tmp:
To restore the indexes backup from december 2nd 2013:
Valid date format is: now: for last backup, s: for second, m: minutes, h: hours, D: days, W: weeks, M: months or Y: years, all date values must be specified without spaces, i.e: 4D, 2W, 1Y, 33m. Dates may also be like: YYYY/MM/DD, YYYY-MM-DD, MM/DD/YYYY or MM-DD-YYYY.
To restore a single file deleted on the repository but existing in previous backup please use the backup wizard by typing: “./alfresco-bart.sh restore” and then follow instructions in the menu option “3”.
To restore the alfresco-global.properties configuration file from a given date please use the backup wizard by typing: “./alfresco-bart.sh restore” and then follow instructions in the menu option “4”.
Finally if you want to restore any other configuration, installation or custom file from your existing backup on a given date follow instructions by choosing option 5 in the recovery wizard.
NOTE4: Alfresco BART restore options or recovery wizard never will overrides your existing Alfresco files, you should specify a temporary recovery folder with enough space, then you have to move that content manually or following the instructions on the screen.
In case of source mismatch error with Duplicity try running this command: