Ver 0.9.6 for most unix/linux flavors
By Marc Swanson, released under permission from Sonitrol Communications, Hartford CT. Modify it to your hearts content.If you make a usefull addition, feel free to distribute it as long as this help message remains intact. This software comes with NO WARRANTY and if it blows up your system, it's not my fault!!! :-)

mybackup is used to backup all the tables in one or all databases on a MySql server. Usage: mybackup [OPTIONS]

-h, --host= Host to connect to. Default=localhost
-d, --database= Database(s) to backup. Default=*==All
-u, --user= User to conect as. Default=root
-p, --pass= Password to connect with. Default is ''
-r, --read_lock Issue a read lock.
-o, --overwrite Write over files in the directory with the same name before Dumping. Note that this actually removes EVERYTHING In each 'table' subdirectory with extension .sql or .txt
-b, --backup_dir= Path to the base backup directory. Sub directories for each database will be created if they don't already exist. Default='/var/lib/mysql_backup'
-s, --split_large Split files > 2 gigabytes into smaller pieces. This feature was added by request as it appears some commercial backup software products do not propperly deal with files over 2 Gig in size even if the OS supports LFS. The resulting files will be broken up into tablename_aa.txt, tablename_ab.txt, etc..
-g, --gzip Run gzip.
-l, --level=(0-9) Level 0 indicates no special options to pass to gzip. Default=9
-f, --logfile= Logfile to write to. '-' will use STDOUT. Default='/var/log/mybackup.log'
-c, --config Backup /etc/my.cnf
--mysqluser The user MySQL is running as: only for root. Default=mysql
-x, --exclude Exclude tables with this pattern.
--exclude_db Exclude databases with this pattern. Default='information_schema' (which is MySql's metainformation table)
--fast Only update the backup if the table has been changed. Compare the txt/sql file with the update stamp from 'SHOW TABLE STATUS <DATABASE>'
-v, --verbose Print lots of output. Combine with "-f -" if you want to see output on STDOUT