Tutorial

How to Automatically Backup Your phpBB Forum

I think we all know the importance of keeping backups, but it’s also very easy to forget! It’s pretty funny how such an important task can so easily be forgotten about. Luckily for us, there’s a phpBB modification that can automate the task and make backups by itself. Here’s how to automatically backup your phpBB forum:

Note: This tutorial is working for version 3.0.11. Make sure to make a backup of your forum before installing any new modifications.


Step 1) Download “Auto Backup” for phpBB.

Step 2) Extract “Auto Backup.”

Step 3) Open (or install) Filezilla and connect to your forum.

Host = Your forum URL.
Username = Your control panel username (usually).
Password = Your control panel password (usually).

Step 4) Open extracted “Auto Backup” folder then open the “root” folder inside.

Step 4b) Drag & Drop the contents inside of the “root” folder into the main directory of your phpBB forum.

Step 5) Open cron.php and find:

}
// Unloading cache and closing db after having done the dirty work.
unlock_cron();
garbage_collection();

Then add this before:

case 'auto_backup':
if ((time() - $config['auto_backup_gc'] * 86400) <= $config['auto_backup_last_gc'])
{
break;
}
include($phpbb_root_path . 'includes/auto_backup.' . $phpEx);
auto_backup();
break;

 

Step 6) Open includes/functions.php and find:

$cron_type = 'tidy_sessions';
}

Then add this after:

else if (isset($config['auto_backup_enable']) && $config['auto_backup_enable'] && (($time_now - $config['auto_backup_gc'] * 86400) > $config['auto_backup_last_gc']))
{
$cron_type = 'auto_backup';
}

 

Step 7) Go to yourdomain.tld/install_auto_backup.php and you should see:

autobackup

Click “Submit”

You will then see this:

installautobackup

Click “Yes”

You should then see:

autobackupsuccess

Step 8) Purge Cache and delete install_auto_backup.php

Step 9) Edit Settings and Enable “Auto Backup” by going to ACP > Maintenance -> Auto Backup

For Weekly Backups your settings will look similar to this:

autobackupsettings

Step 10) Enjoy your automatic backups!


Yay, now your phpBB forum will be backed up automatically for you. Even though your forum will be automatically backed up, you still need to make sure to download the backups to your computer. The backups will be of no use if they are on your server when/if it gets compromised. Anyway, I hope you enjoyed this small tutorial!

About Me: I am a 23 year old male living near Nashville, TN. I graduated from Trevecca Nazarene University with a Bachelor's Degree in Business Manag...
Q
  • Q
    Quacker Jack
  • July 6, 2014
Great tutorial Nerdie! I am sure that this will come in handy.
Q

This site uses Akismet to reduce spam. Learn how your comment data is processed.