欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

oracle bakup.sh

程序员文章站 2024-01-09 16:30:46
...
关于crontab,我们就是认真!crontab从入门到出坑

CentOS Oracle数据库每天自动备份
#set backup fileformat
#set delete file
backuptime=`date +"%Y%m%d%H"`
deletetime=`date -d "3 day ago" +"%Y%m%d%H"`
#
#rm -f /dataBak/dmp/crm_$deletetime.dmp
#rm -f /dataBak/log/crm_$deletetime.log
#
#rm -f /dataBak/dmp/usr_$deletetime.dmp
#rm -f /dataBak/log/usr_$deletetime.log

#
crm/crm@1.57.1.144:1521/qoococrm file=/dataBak/dmp/crm_$backuptime.dmp
log=/dataBak/log/crm_$backuptime.log full=y
usr/usr@1.57.1.144:1521/qoococrm file=/dataBak/dmp/usr_$backuptime.dmp
log=/dataBak/log/usr_$backuptime.log full=y
~                                                                               
~   





crontab -e
50 12 * * * source /$HOME/.bash_profile&& sh /mnt/CRMbakscript.sh
:wq
crontab -l
相关标签: baksh Oracle