Backup Pro 1.9.2 Documentation

Configuration

Backup Pro allows for customization and configuration to meet most needs out of the box. While most of the options will be self explanatory below is a rundown of what's possible.

Backup Settings

This section allows you to apply all the details about what you want to backup, what you don't, who can backup and the Auto Prune.

File Backup Location:
Put simply; what do you want to include for the file backup? You can put unlimited directories here so anything that you can backup anything you want on your server. For MSM installations you'll want to put the full system path for each site you want to backup.

Backup Store Location
Where do you want to store your backups? Ideally, this wouldn't be in your site's document root (for security) but if it is it won't be included within the file backup. Remember to make this directory writable by your webserver so chmod it to either 0666 or 0777..

Allowed Access Levels
Backup Pro will initially only allow Super Admins access but if you need to allow other groups select them from the list.

Maximum Database Backups
Enter the maximum amount of database backups you want to store locally. Note that only local backups will be removed. Enter 0 to disable.

Maximum File Backups
Enter the maximum amount of file backups you want to store locally. Note that only local backups will be removed. Enter 0 to disable.

Database Backup Method
Depending on how your system is setup the default mysqldump method may not work. Essentially, if you have a the "system" command disabled on your PHP server you should use the PHP method but if you're having performance issues you should use MySQLDUMP.

Database Restore Method
The Database restore method to use. MySQL requires access to the "system" PHP function and the "mysql" system command. Note that this is dependant on the backup method used. PHP restore can only restore PHP backups but MySQL can restore either backup method. This is handled gracefully for backwards compatibility.

Auto Prune Threshold
Over time the amount of space used by Backup Pro can be quite considerable. To keep things sane Backup Pro can watch the space used and respond accoringly by removing older backups to make space for newer backups. If set to 0 than no threshold is enforced. Note that this setting only applies to backups stored locally and won't affect remote backups. The value should be set in bytes.

Date Format
The date format you want Backup Pro to use when displaying backups. Note that the format should conform to the ExpressionEngine date format.

Exclude Paths
By default Backup Pro will backup everything within your site's document root but for some sites that just won't work. If you want to exclude anything from the backup put the full path to the document or file here, one per line.

Configure Cron

Note that you Backup Pro by itself doesn't provide automation of the backup process; for that you have to use either Automat:ee or the server's system Cron. The below settings only apply when the "cron" method is used to take a backup.

Notification Emails
Put a single email address on each line that you want to be notified on completion of the backup(s). If no email addresses are entered no notification will be sent. Invalid email addresses will be stripped.

Attach Backups To Email
By default Backup Pro will send a link to download the email but if you'd like to have the backup files sent as an attachment with the notification email we can do that too.

Attachment Max Size
Depending on the size of your site the backups can get pretty large. Sometimes, too large for your email provider. If the attachment size is in bytes larger than the value here links the backups aren't attached and links to download are included instead. The value should be set in bytes.

Configure FTP Sync

If you want to sync the backups with a remote FTP server this is where you'll configure that.

FTP Hostname
The address or domain to the remote server. Don't include any prefix like http:// or ftp://

FTP Username
If you don't know what this is there's a good chance you'll have to talk to your host to get FTP sync up and running.

FTP Password
The password is encrypted for security before storage.

FTP Port
The default is 21 but if your host uses a different port for FTP update it here.

Passive Mode
If checked then all transfers will be done using the PASV method.

FTP Store Location
Where on the remote server do you want to store the backups. This directory has to exist in before the settings can be saved.

Configure Amazon S3 Sync

Amazon S3 is an extremely economical and effective offsite storage option and Backup Pro configures seamlessly.

Access Key ID
Your Access Key ID identifies you as the party responsible for your S3 service requests. You can find this by signing into your Amazon Web Services account

Secret Access Key
This key is just a long string of characters (and not a file) that you use to calculate the digital signature that you include in the request. For security, both your Access key and Secret key are encrypted before storage.

Bucket Name
This is basically the master folder name your backups will be stored in. If it doesn't exist it'll be created. If you don't enter a bucket name one will be created for you.

Configure Rackspace Files Sync

Rackspace Cloud Files works for both the US and UK APIs.

Rackspace Username
Use your Rackspace Cloud username as the username for the API. For security, both your Access key and Secret key are encrypted before storage.

API Access key
Obtain your API access key from the Rackspace Cloud Control Panel in the Your Account. For security, both your Access key and Secret key are encrypted before storage.

Bucket Name
This is basically the master folder name your backups will be stored in. If it doesn't exist it'll be created. If you don't enter a bucket name one will be created for you.

Override Configuration

Since Backup Pro 1.8.4 it's now possible to set the configuration within your EE config file. This is helpful for configuring deployments of your ExpressionEngine site while not requiring the settings to be updated.

To setup just use the below PHP within your EE configuration and Backup Pro will disable the settings to page to prevent modifications

//general
$config['m62_backup']['exclude_paths'] = array();
$config['m62_backup']['allowed_access_levels'] = array();
$config['m62_backup']['auto_threshold'] = '0';
$config['m62_backup']['backup_file_location'] = array(realpath($_SERVER['DOCUMENT_ROOT']), "C:\ProjectFiles\mithra62\ee-addon-export"); 
$config['m62_backup']['backup_store_location'] = realpath(dirname(realpath(__FILE__)).DIRECTORY_SEPARATOR.'..'.DIRECTORY_SEPARATOR.'third_party'.DIRECTORY_SEPARATOR.'backup_proish'.DIRECTORY_SEPARATOR.'backups'); //if from within the config directory this should map to the backup_proish/backups directory 
$config['m62_backup']['db_backup_method'] = 'mysqldump';
$config['m62_backup']['db_restore_method'] = 'mysql';
$config['m62_backup']['license_number'] = '';
 
//setup cron
$config['m62_backup']['cron_notify_emails'] = array('eric@mithra62.com', 'eric@ericlamb.net'); //change these <img src="http://www.mithra62.com/images/smileys/smile.gif" width="19" height="19" alt="smile" style="border:0;" />
$config['m62_backup']['cron_attach_backups'] = '0';
$config['m62_backup']['cron_attach_threshold'] = '0';
 
//setup FTP
$config['m62_backup']['ftp_hostname'] = '';
$config['m62_backup']['ftp_username'] = ''; 
$config['m62_backup']['ftp_password'] = '0';
$config['m62_backup']['ftp_port'] = '21';
$config['m62_backup']['ftp_passive'] = '0';
$config['m62_backup']['ftp_store_location'] = '';
 
//setup S3
$config['m62_backup']['s3_access_key'] = '';
$config['m62_backup']['s3_secret_key'] = '';
$config['m62_backup']['s3_bucket'] = '';
 
//setup CF
$config['m62_backup']['cf_username'] = '';
$config['m62_backup']['cf_api'] = '';
$config['m62_backup']['cf_bucket'] = '';
$config['m62_backup']['cf_location'] = 'us';
I am flagging this documentation as:

Need Free Developer Support?

2 Comments

  1. John Morton says:

    Regarding the Auto Prune Threshold value, is that in bytes? megabytes? kilobytes?

  1. Eric Lamb says:

    Oh man, that keeps getting missed when I update the docs. The Auto Prune Threshold is in bytes.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="" highlight="">