Operating System - HP-UX
1753922 Members
7948 Online
108810 Solutions
New Discussion

symclone check function !!!

 
kpatel786
Frequent Advisor

symclone check function !!!

Hi,
We have a script which syncs datas over different server.

There is a part where in the function is to if the pairs are in copied state the same is shown below:

/usr/symcli/bin/symclone -sid $LOCAL_SYM_SID -file /tmp/clone_pair verify -copied -i 60 -c 6
RC=$?
if [ $RC -ne 0 ]
then
echo "symclones are not in a copied state"
exit $RC
fi

The problem is the above command runs for 60 secs for 6 times and comes out with the error message. Though infact the actual process of copying gets completed much after the specified time.

How should I go about inputing a better check mechanism ?

Kindly assist with your inputs. Thanking you in advance
1 REPLY 1
James R. Ferguson
Acclaimed Contributor

Re: symclone check function !!!

Hi:

This sounds as if the return code isn't zero but some value signifying a warning or informational state (if as you say the "actual process of copying gets completed).

I would guess that following the termination of this parent process, another process that gets spawned coes the actual copy.

If that is the case, you might be able to write a simple script that queries the activity of either another process or the state of a file to be present or maybe not inuse.

Regards!

...JRF...