System Backup and Restore

A GigaFox system backup will save the necessary directories, files, and system-specific data to restore GigaFox to its state at the time of the backup.

Save a system backup

  • To save a system backup, run the following script as root:
  • 
       sudo /usr/local/deviceconnect/Build/Scripts/dcbackup-periodic.sh
        

Additional Parameters

  • --help: Will display additional parameters with a description of each.
  • --install: Sets up a system backup cronjob to run daily at midnight. --install must be run with sudo and has to be the first additional argument.
    If --install needs to be run at additional times, the original additions to the crontab must be edited out by manually running sudo crontab -e.
  • --all: Include the influxdb database.
  • --dir <directory>: Write backups to a specific directory. By default, backups are saved in /Users/deviceconnect/dcbackup.
  • --max-age <days>: Keep this many previous number of days of backups. By default, 30 days of backups will be saved. To disable this feature, use 0.
    Example: To keep backups for the previous five (5) days:
    
       sudo /usr/local/deviceconnect/Build/Scripts/dcbackup-periodic.sh --max-age 5
        

Restore from System Backup

  • To restore a system from a saved backup, run:
    
       sudo /usr/local/deviceconnect/Build/Scripts/dcrestore.sh ~/dcbackup/<savedbackup>.tar.gz