Page tree
Skip to end of metadata
Go to start of metadata

Introduction

In FreePBX 15 our backup module was redesigned for simplicity, flexibility and maintainability.  Storage options are now handled in the Filestore module which offers more options to keep your data safe. You can now backup per module. This allows you to create custom backups of just the data you need. You can also divide your modules in to different backups for data that may change more often. With each module handling the data it owns we can now do cross-version backup and restore (15+).

Creating backup jobs

Storage

If you are migrating from a previous version, your backup jobs will migrate on install including creating Filestore locations.

If this is a new install, your first step is to create a Filestore location. For information on doing this please see the Filestore documentation Here.

Backup Job Creation

Step 1: Click on the "Add Backup" button

Step 2: Give your backup a name and description. The name will be used for the storage location

Backups for "My Backup" will store in their respective locations as "My_Backup"

Step 3: Click the "Modules" button

Step 4a: Choose the modules to backup. You can click the box in the header to select all.

Some modules will have their own settings which will be available by clicking the plus symbol.

Step 4b: Click "Save Changes"

Step 5: Select your notification preferences. If there is no email address notifications will be disabled. Note notifications emails may be filtered as spam by your ISP. If this happens you can typically whitelist the sender email address.

Step 6: Choose where to store the backup. You can select as many locations as desired.

Step 7: Decide if you want to run this backup automatically. To do so, set enabled to "Yes" and select the schedule. Only the options available to the selection type will be enabled. By default these are all set randomly.

Step 8: Decide if you want the module to do housekeeping. Backups can be limited by number of runs only keeping the last X backups. They can also be kept until they reach a certain age.  For "Delete After Runs" 0 is unlimited.

Step 9: Decide if this backup is a warm spare. See documentation HERE for warm spare setup.

Step 10: Save your backup.

The grid

aSelect where you want to be from the tabs
bButton to create a new backup
cThe name of your backup.
dA description of the backup
eBackup actions. Edit, Run, Show CLI command and Delete
fSearch for your backup job in cases where you have many backups to filter through.

Backup CLI:

You can copy the command from the ">_" icon and run the backup from an ssh session. A list is also available in the CLI

To run a backup use the "Backup ID"

Restore

On a new install you can run the restore by uploading a backup file, or restore a previously saved backup on an existing install.

From this window you can also download and delete stored backups.

After running or uploading a backup you will go to a confirmation screen.

Here you will see the description of the backup job to be run including the modules backed up, and decide to run the restore or go back to the restore page.

Restore CLI

You can restore the backup from the command line

Note the same warnings from the UI apply but there is no confirmation on the cli.


 removed/breaking change

To see what is in the backup you can check the manifest. The manifest is returned in json and can be processed through automated methods.  Note backups are PHAR files and can be natively accessed through php's PharData class.





  • No labels