Mopquill
Active member
If you appreciate my work or find this script useful, consider a donation!
You can do so here. I'd really appreciate it!
XenForo Backup Shell Script (version 1.0.8) - Use this script to back your database up by simply pointing it to your config.php
Read more about this resource here.
Most Recent Changelog
1.0.8 - July 31st, 2012

XenForo Backup Shell Script (version 1.0.8) - Use this script to back your database up by simply pointing it to your config.php
This script's intended use is to be run as a cron or called via command line to quickly back up your forum's database, but, I also added a parameter to have it prompt you for your database information. Anyhow, it saves the database in the format database_name_yyyy-mm-dd_hh-mm-ss.sql.gz , because I sometimes have more than one backup from the same day, and having time helps with that.
Read more about this resource here.
Most Recent Changelog
1.0.8 - July 31st, 2012
- Added support for backing up all databases on server with mysql root account, and new mode parameter backup-all-databases
- Optionally backs up data and internal_data directories (suggested by craigiri) with configurable locations -- this is enabled by default, and assumes they are sibling to your library directory
- Added data-only mode parameter to optionally back up just the data directories -- useful for backing up data at different times or in different intervals than your database
- Optionally combines data and internal_data into the same gzipped tar archive -- this avoids a warning from tar regarding parent directories, and is enabled by default
- Optionally creates database backup directory for you if it does not exist -- this is enabled by default
- Now includes --single-transaction in the mysql query (suggested by Coop1979), which should be run much smoother on big boards where you don't want to be locking a bunch of tables
- includes various other stability tweaks to the MySQL commands
- changed inner functioned to be more module-oriented -- this makes the script more efficient