backup

rdiff-backup strategy

To backup windows using rdiff-backup to another computer, four sub-systems need to be configured:

  1. Install cygwin (including rdiff-backup) on the windows machine
  2. Configure and test rdiff-backup across ssh using manual passwords
  3. Configure public key authentication for passwords
  4. Configure scheduled tasks to run the process automatically

MySQL backup

-create a user (such as backup) with select and lock priviledges for all databases from any host
-set MySQL server configuration to listen on external ports
pw=mybackuppassword
hst=MySQLhost
nice mysqldump -h $hst -u backup -p$pw --compress --add-drop-table --extended-insert -A | gzip -9 >/backups/$hst-$(date +"%Y%m%d").gz

MySQL misc tips

phpMyBackupPro: No simpler backup for MySQL: http://www.linux.com/feature/127811
Tunnel to locally running mysql server using ssh:
http://www.nerdlogger.com/2008/06/tunnel-to-locally-running-mysql-server...
create and setup remote administrator:
first make sure that there are not multiple name@addresses where the user can log in, else every one will have to get permissions separately.
CREATE USER 'andrewfoo'@'192.168.1.%' IDENTIFIED BY 'foomatic';
GRANT ALL ON *.* to 'andrewfoo'@'192.168.1.%' WITH GRANT OPTION;

SSH/SCP without a password

Here are some links:

Zimbra backup using LVM and rsync

rsync backup

-can use alternate ports, e.g.:
rsync -avz --stats --progress -e "ssh -p 1234 -o CheckHostIP=no" root@sv.cfaw.info:/backups/cfa.net .

Here are some rsync links:
-Fairly recent tutorial: http://www.fredshack.com/docs/rsync.html
-Snapshot-type backups using hard links: http://www.mikerubel.org/computers/rsync_snapshots/

Syndicate content