Oracle/Linux:RSYNC:Transfer archives from one server to another through rsync utility
RSYNC for Copy files
This is one of the finest method to copy archives from primary server to backup/standby server.
For this, rsync daemon running on primary server.
For Primary Server.
1.Configure rsync.conf
[oracle@Bhavu etc]$ cat /etc/rsyncd.conf
[archlog]
path = /oracle/archive/bhavudb
comment = For bhavu database archive log backup
uid = root
gid = root
[archlog]
path = /oracle/archive/bhavudb
comment = For bhavu database archive log backup
uid = root
gid = root
2.Check rsync daemon running.
[oracle@Bhavu etc]$ ps -ef|grep rsync
oracle 13287 3699 0 14:44 pts/1 00:00:00 grep rsync
root 29022 1 0 Aug28 ? 00:00:00 /usr/bin/rsync --daemon
For Backup/Standby Server.
1.Create sh file for rsync commands.filename is rsync.sh
#!/bin/bash
pro_check=`ps -ef | grep rsync | grep -v grep | grep -v rsync-port`
if [[ -n $pro_check ]] ; then
echo "Rsync Already Running...."
else
echo "Starting Rsync...."
rsync -avzpt primarydatabase_ip::archlog Bachkp_server_location
fi
pro_check=`ps -ef | grep rsync | grep -v grep | grep -v rsync-port`
if [[ -n $pro_check ]] ; then
echo "Rsync Already Running...."
else
echo "Starting Rsync...."
rsync -avzpt primarydatabase_ip::archlog Bachkp_server_location
fi
2.For more info read man rsync.
Comments
Post a Comment
Dear User,
Thank you very much for your kind response