This post is more than 5 years old
1 Rookie
•
88 Posts
0
1322
May 17th, 2007 12:00
Cloning Scheduling?
If I want to schedule a clone job after the regular jobs have finished and I don't want to use the Automatic cloning option in the GROUP? Is the only way to do it by manually right clicking on volume / save set and run clone / or by a cron job in the operating system?
What I need to do is clone several groups, I was told the Automatic cloning feature for a lot of clients is not a good idea you can run into drive contention while the clone is running but I dont know if this is the case? What is best practice for this scenario? Thanks in advance.
What I need to do is clone several groups, I was told the Automatic cloning feature for a lot of clients is not a good idea you can run into drive contention while the clone is running but I dont know if this is the case? What is best practice for this scenario? Thanks in advance.
No Events found!


ajw2
1 Rookie
•
88 Posts
0
May 30th, 2007 11:00
ajw2
1 Rookie
•
88 Posts
0
May 30th, 2007 11:00
#!/bin/sh
OK_FLAG=`/usr/ucb/ps -auxw | grep -i savegrp | grep -i NDMP_DataMover2 | grep -v grep | wc -l`
if (( $OK_FLAG < 1 ))
then
nsrndmp_clone -S -e `date +%m/%d/%y` -s server.com -b "NDMP DataMovers Clone" -g "NDMP_DataMover2"
else #Reschedule clone
echo "$GROUP cloning has been delayed 10 minutes" | mailx -s "$GROUP cloning has been delayed 10 minutes" legato_info
at now + 10 minutes <
fi
-------------
ERROR MESSAGE
-------------
./datamover2_clone: syntax error at line 12: `end of file' unexpected
elocsin
12 Posts
0
May 30th, 2007 11:00
elocsin
12 Posts
0
May 30th, 2007 11:00
and move EOF to a new line:
/var/adm/etc/datamover2_clone > /dev/null 2>&1
EOF
Hopefully this will get displayed correctly.
elocsin
12 Posts
0
May 30th, 2007 11:00
ajw2
1 Rookie
•
88 Posts
0
May 30th, 2007 11:00
#!/bin/sh
OK_FLAG=`/usr/ucb/ps -auxw | grep -i savegrp | grep -i NDMP_DataMover2 | grep -v grep | wc -l`
if (( $OK_FLAG < 1 ))
then
nsrndmp_clone -S -e `date +%m/%d/%y` -s server.com -b "NDMP DataMovers Clone" -g "NDMP_DataMover2"
else #Reschedule clone
echo "$GROUP cloning has been delayed 10 minutes" | mailx -s "$GROUP cloning has been delayed 10 minutes" legato_info
at now + 10 minutes < /dev/null 2>&1
EOF
fi
bash-2.03# ./datamover2_clone
./datamover2_clone: 0: not found <--- ERROR
bash-2.03#
ajw2
1 Rookie
•
88 Posts
0
May 30th, 2007 12:00
#!/bin/sh
OK_FLAG=`/usr/ucb/ps -auxw | grep -i savegrp | grep -i NDMP_DataMover2 | grep -v grep | wc -l`
if [ $OK_FLAG -lt 1 ] "<---FIX FOR PROBLEM"
then
/nsr/sbin/nsrndmp_clone -S -e `date +%m/%d/%y` -s server.com -b "NDMP DataMovers Clone" -g "NDMP_DataMover2"
else #Reschedule clone
echo "$GROUP cloning has been delayed 10 minutes" | mailx -s "$GROUP cloning has been delayed 10 minutes" legato_info
at now + 10 minutes <
/var/adm/etc/datamover2_clone > /dev/null 2>&1
EOF
fi
You compare numeric values using "lt" not the less than or greater than signs. This was on Solaris... Thanks for your help!! = )
elocsin
12 Posts
0
May 30th, 2007 12:00