- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- remsh issue in the failover scripts
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-08-2003 08:12 AM
07-08-2003 08:12 AM
remsh issue in the failover scripts
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-08-2003 08:23 AM
07-08-2003 08:23 AM
Re: remsh issue in the failover scripts
i had similar issue with SG/SAP integration.
They were due to the way the remsh handles the stdin/stdout.
Try redirecting to /dev/null every non needed output, and to a file every needed output.
Also pay attention to the use of demon, like command started with nohup, because these file retain an open connection to the output file.
It may take you a little to work this out.
A trick i used was to start the remsh in background, and then wait and check if jobs were finished (using "jobs -l").
I used a timeout, and if job didn't finished in a timely manner, i killed them.
loops=0
again="1"
while [ $again != "0" ]
do
pids=$(jobs -l | cut -c 7- | awk '{ print $1 }')
print "$(date '+%b %e %X') - Node \"$(hostname)\": Waiting for remsh ["$pids"] to exit"
sleep 8
let loops=loops+1
if [ $loops -ge 450 ]
then
print "$(date '+%b %e %X') - Node \"$(hostname)\": Timeout exceeded. Killing all remsh still alive"
for idle in $(jobs -l | cut -c 7- | awk '{ print $1 }')
do
print "$(date '+%b %e %X') - Node \"$(hostname)\": kill -9 $idle"
kill -9 $idle
done
sleep 8
jobs >/dev/null 2>/dev/null # elimina il mes. "Terminated..."
fi
if [ $loops -ge 500 ]
then
print "$(date '+%b %e %X') - Node \"$(hostname)\": WARNING - Unable to kill all remsh. Continuing Oracle startup sequence anyway."
break
fi
again=$(jobs|wc -l)
done
If it is a issue with the oracle lsnrctl, i use the "at" command to start it and detach from every possible issue.
HTH,
Massimo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-08-2003 08:31 AM
07-08-2003 08:31 AM
Re: remsh issue in the failover scripts
forgot the part with the remsh :)
It is before all the previous code.
for i in $NODES
do
print "$(date '+%b %e %X') - Node \"$(hostname)\": Killing Baan processes on $i with remsh; PID = \c"
remsh $i -n "/etc/cmcluster/MP1/baanIVc.sh stop" &
pid=$(jobs -l | cut -c 7- | awk '{ print $1 }'| head -1)
print $pid
done
Massimo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-08-2003 10:39 AM
07-08-2003 10:39 AM
Re: remsh issue in the failover scripts
Tried the suggestions but to no prevail. I think you are on the right track with the stdin/stdout but the redirection still produced same results - remsh hanging. Unfortunately I cannot terminate the remsh, since the returned value is anticipated in the script, which causes the packages to switch.
Thanks though. If you have any other ideas, let me know.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-08-2003 10:54 PM
07-08-2003 10:54 PM
Re: remsh issue in the failover scripts
1) did this EVER work?
2) If so, what has changed? patches installed etc?
3) What OS version?
4) is remshd patched?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-08-2003 10:57 PM
07-08-2003 10:57 PM
Re: remsh issue in the failover scripts
in another case is solved piping the output:
let say the command was
remsh HOST -l sidadm "startsap"
this hanged, i never understood why, but this error come after a patch that affected r-commands, but i don't remember which. you could check in the patch description...
was solved with this sintax:
remsh HOST -l sidadm "startsap 2>&1 | cat -tve >/dev/null"
also pay attention to use redirection local to the remote host, and not to the local host.
HTH,
Massimo