首先要了解 linux里crontab计划任务
注:databackup 是 shell 脚本 创建 mkdir databackup 然后得改变权限
# cd /home/zhaojiangfeng/saonek/demomysql/
# lsdatabackup readgoal.sql
# vi databackup
mysqldump library > /home/zhaojiangfeng/saonek/demomysql/readgoal.sql -uroot -p123456
# cd var/spool/cron/
]# ls
root
# vi root
35 11 * * * sh /home/zhaojiangfeng/saonek/demomysql/databackup
*号 中间的是 tab 键