nativeInstalleredx

Create and restore application backups

Before running the commands shown on this page, you should load the Bitnami stack environment by executing the installdir/use_APPNAME script (Linux and Mac OS X) or by clicking the shortcut in the Start Menu under “Start -> Bitnami APPNAME Stack -> Application console” (Windows). Learn more.

Backup

The Open edX powered by Bitnami is self-contained and the simplest option for performing a backup is to copy or compress the Bitnami stack installation directory. To do so in a safe manner, you will need to stop all servers, so this method may not be appropriate if you have people accessing the application continuously.

Follow these steps:

  • Change to the directory in which you wish to save your backup:

    $ cd /your/directory
    
  • Stop all servers using the graphical manager or the command-line script. Here’s an example:

    $ sudo installdir/ctlscript.sh stop
    
  • Create a compressed file with the stack contents using the command below:

    $ sudo tar -pczvf application-backup.tar.gz installdir
    
  • Restart all servers using the graphical manager or the command-line script:

    $ sudo installdir/ctlscript.sh restart
    

You should now download or transfer the application-backup.tar.gz file to a safe location.

Restore

Follow these steps:

  • Change to the directory containing your backup:

    $ cd /your/directory
    
  • Stop all servers using the graphical manager or the command-line script. Here’s an example:

    $ sudo installdir/ctlscript.sh stop
    
  • Move the current stack to a different location:

    $ sudo mv installdir /tmp/bitnami-backup
    
  • Uncompress the backup file to the original directory using the command below:

    $ sudo tar -pxzvf application-backup.tar.gz -C /
    
  • Start all servers using the graphical manager or the command-line script:

    $ sudo installdir/ctlscript.sh start
    

IMPORTANT: When restoring, remember to maintain the original permissions for the files and folders. For example, if you originally installed the stack as the root user, make sure that the restored files are owned by root as well.

Last modification September 6, 2018