- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Problem with remsh and start/stop 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
08-01-2007 08:09 AM
08-01-2007 08:09 AM
Problem with remsh and start/stop scripts
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2007 08:19 AM
08-01-2007 08:19 AM
Re: Problem with remsh and start/stop scripts
It is also (barely) possible that your remsh is waiting for input so that using -n may fix you but I think you are seeing the results of a daemonized process.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2007 08:24 AM
08-01-2007 08:24 AM
Re: Problem with remsh and start/stop scripts
FYI: I did try to add an explicit exit 0 statement at the end of the start case, that did not effect the result.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2007 08:37 AM
08-01-2007 08:37 AM
Re: Problem with remsh and start/stop scripts
UNIX95=1
If you see any remsh daemons running then you are seeing an artifact of a daemonized process. You need to make this determination before going any further. If remshd's persist on the remote host after you think the remsh has finished all of its tasks then you need to know that. There may still be a way to outbushwhack this but it ain't pretty.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2007 08:45 AM
08-01-2007 08:45 AM
Re: Problem with remsh and start/stop scripts
# ps -C remshd
PID TTY TIME CMD
19415 ? 00:00 remshd
# ps -fe | grep remsh
root 19415 966 0 15:40:50 ? 00:00 remshd
root 20178 19288 0 15:41:06 ttyp1 00:00 grep remsh
After the script exits on the remote host, here is the output on the remote host:
# ps -fe | grep remsh
root 20590 19288 0 15:42:24 ttyp1 00:00 grep remsh
At this point the local host is still waiting for the exit on the remote host:
Wed Aug 1 15:44:40 CDT 2007
root 7635 24731 0 15:44:40 ttyp8 00:00 grep remsh
root 6990 6989 0 15:40:50 ttyp9 00:00 remsh hosta /sbin/init.d/OraclePTCHapp start
root 6989 29138 0 15:40:50 ttyp9 00:00 remsh hosta /sbin/init.d/OraclePTCHapp start
Any other things to try?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2007 10:28 AM
08-01-2007 10:28 AM
Re: Problem with remsh and start/stop scripts
Add a command at the end of your start script on hosta to remove a lockfile on hostd. This can be done via an NFS mount or a remsh command from hosta to hostd.
Inside your script on hostd.
1) Create a lockfile, e.g. /var/tmp/mylock
2) Invoke your remsh to hosta in the backgound.
remsh hosta xxxx start &
REMSH_PID=${!}
3) Loop until the lockfile is removed or a count is exceeded.
typeset -i MAXCOUNT=100
typeset -i COUNT=1
typeset DELAY=10
typeset LOCKFILE=/var/tmp/mylock
while [[ -f "${LOCKFILE}" && ${COUNT} -le ${MAXCOUNT} ]]
do
sleep ${DELAY}
((COUNT += 1))
done
if [[ -f "${LOCKFILE}" ]]
then
echo "Timed out." >&2
fi
# Now kill the remsh if it's still around
kill -0 ${REMSH_PID}
STAT=${?}
if [[ ${STAT} -eq 0 ]]
then
kill -15 ${REMSH_PID}
fi
rm -f "${LOCKFILE}" # just making sure
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2007 01:27 AM
08-02-2007 01:27 AM
Re: Problem with remsh and start/stop scripts
When the DBA returns next week, I will work with him to see if we can find some other cause along the lines of a daemon issue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2007 02:54 AM
08-02-2007 02:54 AM
Re: Problem with remsh and start/stop scripts
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2007 03:59 AM
08-02-2007 03:59 AM
Re: Problem with remsh and start/stop scripts
The purpose is to start/stop Oracle Applications 11.5.10.2.
I have been disecting the scripts that are called by the scripts, etc. I have gone through the first script and commented out all but one step at a time. That process allowed me to pin-point the problem. The problem occurs when the underlying script calls the script to start the Oradcle Application listner. I am going to further disect that to see if I can determine a fix.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2007 05:04 AM
08-02-2007 05:04 AM
Re: Problem with remsh and start/stop scripts
# remsh hosta -n "/sbin/init.d/OraclePTCHapp start"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2007 07:52 AM
08-02-2007 07:52 AM
Re: Problem with remsh and start/stop scripts
I will work with the DBA to see if there is another way to get the listener started with out calling it from the script I am trying to run.
I will update when I have more news,
-Dave
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-02-2007 08:56 PM
08-02-2007 08:56 PM
Re: Problem with remsh and start/stop scripts
Except Clay mentioned it above in his first reply. (That was my first thought too.)