4
Dec
사이베이스 백업
사이베이스 백업 스크립트
#!/usr/bin/sh
DIR=”[SYBASE_BACKUP_DIR]”
WEEK=`date +%Y%m%d`
tgt_file=”$DIR/[database_name].$WEEK.dmp”
log_file=”$DIR/R/[database_name].$WEEK.log”
isql -Usa -P <<EOF
dump database [database_name] to “$tgt_file”
go
.
EOF
echo “DB DUMP END ==>$tgt_file”
find [SYBASE_BACKUP_DIR]/*.dmp -mtime +2 -exec rm -rf {} \;
find [SYBASE_BACKUP_DIR]/*.log -mtime +2 -exec rm -rf {} \;
Tags: sybasd dump
This entry was posted
on 금요일, 12월 4th, 2009 at 11:51 오전 and is filed under DATABASE.
You can follow any responses to this entry through the RSS 2.0 feed.
You can leave a response, or trackback from your own site.
Leave a reply