Since several weeks I’m working with backups.
I created a script that dumps databases. It currently only supports mysql, ldap and postgresql. The script is not difficult, it just uses the dump program of the database and writes that to a file.
I created an other script that does the real backup. It uses rsync to copy the data to the other host, together with ssh. With some simple commands over ssh it will keep a history. It also will create a daily incremental backup linked to the weekly full backup.
http://www.raskas.be/blog/scripts/database-backup/ will bring you to the information about the database script.
http://www.raskas.be/blog/scripts/full-backup/ will bring you to the information about the backup script.
I made those script available online so everybody can use and improve those scripts. If you improved the script, please let me know, maybe I will update my scripts with your modifications.