Back to vBulletin 3.0 Add-Ons

Vbulletin Database Backup Pro (Cron Support)
Mod Version: 1.9, by Trigunflame

This modification is in the archives.
vB Version: 3.0.7 Rating: (6 votes - 5.00 average) Installs: 338
Released: 21 Mar 2005 Last Update: 30 Mar 2005 Downloads: 297
Not Supported  

VBulletin Database Backup Pro


NOTICE: 02/03/2006
This system is being "ReBorn" into a new product "Vbulletin Backup Pro" working from a New Codebase and hopefully implementing all the features and fixing all the bugs that were present in the previous releases.
This will be developed specifically for the vbulletin 3.5 system but will probably maintain compatabilty with the pre-existing 3.0 versions.

Summary:

Vbulletin Database Backup Pro is just what it says; a professional tool for your Vbulletin installation. This script will handle the automated backup of your forums in a secure, data-conscious and optimized way.

Introduction:

I want to interest all of you in the ultimate solution for automated database backup from within Vbulletin crontab system.
And potentially more so than a standard crontab.

It's been said, backing up without direct shell access is futile. Wrong. This script is optimized to work just fine with even the largest of databases. (Note: If you have an extremely large database, make sure to use the mysqldump binary option that is selected by default.)

The reason for the creation of this script was due to needing a better system of automated backup. I think me and a lot of people have used either a standard cron system, or brad.loo's small database cron; while they can be somewhat effective, they do not provide the functionality or a total solution without having to extensively mod it.

This system has automatic failovers for MySQLdump, as well as the compression programs used where applicable. All in all, this script is a one stop shop for handling your backup needs on a automatic basis or from the control panel without having to use shell and do a dump manually.

Features:
  • Absolutely NO Vbulletin File Modifications
  • Fully automized backup using the Vbulletin Cron system.
  • Remotely store backups on another srever via builtin FTP libraries.
  • Keep Remote FTP Server directory SYNC'd with Local Filesystem.
  • Dump using shell based, MySQLdump
  • Dump using an optimized PHP based Dump
  • System will Failover from MySQLDump binary straight Into a PHP Dump
  • Various other Failovers for file/dir creations & deletion.
  • Automatic pruning & control of a Specified max backups at any one time.
  • Do a Full database dump OR just the tables you want. Such as post, forums, threads & users.
  • Combine individual tables from a dump into 1 SQL File.
  • Some optimizations for InnoDb tables AND MySQL 4
  • System LOCKS tables while dumping, to prevent database corruption.
  • Can Shutdown forum while backup is in progress. And then REOPEN it automatically.
  • Customized Errors are Logged back into the Vbulletin Cron Log
  • Log path for MySQLDump Errors are customizable as well as Dump Path
  • Customize the Full Paths to binarys that will be used if needed.
  • Customize which execution command to use from PHP if using MySQLdump & certain compressors.
  • Specifiy the Dump Switches MySQLDump will use if selected.
  • Choose the option to Compress your Backups or not.
  • Choose from gzip, bzip2, tar, tar gz, tar bz2, zip for compressions.
  • And Many Many More...

Change log:
  • 3/30/2005 - Patch v1.9
  • Added configuration directives to control the PHP Dump optimizations for MySQL4, InnoDB, and Locking Tables. Some people were having some reported problems with restoring dumps; I believe this may have been the cause, I was using optimizations hardcoded directly for MySQL 4+ support, they are now MySQL 3/4+.
  • 3/25/2005 - Patch v1.8
  • Lots of bug fixes regarding directory paths. If dump path was null, the script would translate the path as starting at / root.
  • Incorporated Full Remote FTP Support.
    This includes remote offloading of dumps, keeping them rotated in sync with local backups, as well as removing Local backups after transfer to Remote Server.
  • 3/23/2005 - Patch v1.7
  • Added ability to Repair & Optimize tables before backup.
  • 3/23/2005 - Patch v1.6
  • A few configuration changes, I didn't save in the mysqlbackupconfig.php
  • 3/22/2005 - Patch v1.5
  • Made the LOCK Tables mechanism optional.
    Note: Use the shutdown Forums option, if you disable the LOCK Tables.
  • Made some adjustments to the cronbackup.php might help with the array_merge errors, and it may not..
  • Took the eval out for the parsing the configuration, they are referenced in hardcode now.
  • Modified the date feature for backups. Remember just use 'mdy' or 'm_d_y'.
  • 3/22/2005 - Patch v1.4
  • Added Backup Rotating (Pruning) support to limit max backups at any one time.
  • Make sure to replace all files, even the mysqlbackupconfig.php as it contains 3 new configuration options.
  • 3/21/2005 - Patch v1.3
  • Added some optimization code for InnoDB. Will help when you reload the database.
  • Reason: Thought about Erwin, I believe he mentioned he used InnoDB.
  • 3/21/2005 - Patch v1.2
  • Modified previous sql/directory cleanup. Better code.
  • 3/21/2005 - Patch v1.1
  • Fix for table prefixes, updated config with info about it.
  • Bug located by: Nexialys
  • 3/21/2005 - Initial Patch v1.0
  • Forgot to add unbuffered streams for fwrite(), this will speed up the compression of the database backup.
  • 3/21/2005 - Initial release. v1.0
  • Script was just released today, waiting on bug reports or any features that may need added to the script that I have missed.

To-Do:
  • AdminCP Based Dump Control Panel to Test & Run Customized Configurations
  • Create a Database Restore Tool, that works through Shell or PHP.
  • Redesign the error system for better debugging, with severity levels.
  • Finish implementing shell based support of Secure SSH SCP File Transfer Support
  • Full Backup of Directory Tree for all of your Files
  • Fix the bug regarding serializing/unserializing on some PHP Setups

Known Issues:
  • Need to work on some of the Raw Windows Commands.
  • Some of the stuff isn't reporting the errors as correctly as they should.

Instructions:
  1. Download the zip file.
  2. Place mysqlbackupconfig.php, mysqlbackup.php, ftp.lib.php, pclzip.lib.php in the forums 'includes' folder.
  3. Place cronbackup.php in your 'includes/cron' folder.
  4. Add a New Cron Task in your Scheduled Task Section. Refer to the screenshot if you need help.
  5. Read and Modify the configuration data in the mysqlbackupconfig.php
  6. Go back to the Scheduled Task section, and run the task. See what messages you get.
  7. Note: pclzip.lib.php is an Modified Version of this open source GPL Php Zip Library.http://www.phpconcept.net
  8. CHMOD 0777 the Directory you will be saving Dumps/Logs to !!!
  9. IF POSSIBLE. YOU OR YOUR HOST SHOULD TURN OFF SAFEMODE/OPENBASEDIR


Help Debugging:

This may come as a surprise to some people.. but I do all my code in notepad, thus it may not look formatted right for people that use editors. If you want to view the code in "my" style, how its supposed to look.
Open my files in Notepad, with Font size 10-Regular-Lucida Console.

As for An errors you may get, when you post;
Post your PHP Version, MySQL Version, and the Error as is Shown Please.

Further Info:

I would like a lot of people to try this script and give me feedback on what you would like changed, what Needs changed and so on and so forth. With the size of this script, it more than likely not gonna work perfect on every system.. so just tell me whats wrong and I will try to get it fixed.

Download

This modification is archived and cannot be downloaded.

Addons

Screenshots

 


vblts.ru supports vBulletin®, 2022-2024