Home Diary Blog Photo Community Open Source
backup all

!/bin/bash

time=date +%Y-%m-%d

/usr/local/mysql/bin/mysqldump -ujxva -pxxx --default-character-set=utf8 cheyi_wx > /data/backup/cheyi_wx_$time.sql

tar -zcvf /data/backup/wwwroot_$time.tar.gz /data/wwwroot