HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- /sbin/init.d/sysedge stop flakey
Operating System - HP-UX
1836120
Members
2848
Online
110089
Solutions
Forums
Categories
Company
Local Language
back
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
back
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
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- 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
03-30-2004 06:59 AM
03-30-2004 06:59 AM
I have trying to stop and start sysedge on my hp 11.00 server, this could have been going on for a while, but i only now really noticed it.
It is flaky at best, sometimes it works sometimes no.
I run it as root
and all I get back is...
# /sbin/init.d/sysedge stop
Killed
# ps -ef |grep sysedge
root 7469 1 0 11:54:57 ? 0:00 /opt/EMPsysedge/bin/sysedge -b -p 161 -l /etc/sysedge.l
From looking at the /sbin/init.d/sysedge file it should say...
SystemEDGE stopped
Is there something I am missing?
I really don't understand the...
if kill -9
Is it killing the process? Where does it get Killed from?
...taken from /sbin/init.d/sysedge...
'stop')
#
# Determine PID of process(es) to stop
#
MYPID=`ps -ef | grep sysedge | grep -v grep | awk '{print $2}'`
if [ "X$MYPID" != "X" ]; then
if kill -9 $MYPID; then
echo "SystemEDGE stopped"
else
set_return
echo "Unable to stop SystemEDGE"
fi
fi
;;
It is flaky at best, sometimes it works sometimes no.
I run it as root
and all I get back is...
# /sbin/init.d/sysedge stop
Killed
# ps -ef |grep sysedge
root 7469 1 0 11:54:57 ? 0:00 /opt/EMPsysedge/bin/sysedge -b -p 161 -l /etc/sysedge.l
From looking at the /sbin/init.d/sysedge file it should say...
SystemEDGE stopped
Is there something I am missing?
I really don't understand the...
if kill -9
Is it killing the process? Where does it get Killed from?
...taken from /sbin/init.d/sysedge...
'stop')
#
# Determine PID of process(es) to stop
#
MYPID=`ps -ef | grep sysedge | grep -v grep | awk '{print $2}'`
if [ "X$MYPID" != "X" ]; then
if kill -9 $MYPID; then
echo "SystemEDGE stopped"
else
set_return
echo "Unable to stop SystemEDGE"
fi
fi
;;
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-30-2004 07:37 AM
03-30-2004 07:37 AM
Solution
First of all, there is a big hole in your logic. If the pid is not found then you exit in an indeterminate state. Secondly, kill -9 should only be used as a weapon of last resort because it does not allow the process to do any cleanup (e.g. remove temp files, clean up shared memory and/or semaphores). You should first try a kill -15 then a -1, -2, -3, then probably -11, and finally -9. Do this between each of the kill's
kill -0 ${PID}
STAT=${?}
if [[ ${STAT} -eq 0 ]]
then
echo "Still a valid PID; kill some more"
else
echo "Process gone"
fi
kill -0 ${PID}
STAT=${?}
if [[ ${STAT} -eq 0 ]]
then
echo "Still a valid PID; kill some more"
else
echo "Process gone"
fi
If it ain't broke, I can fix that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-30-2004 07:40 AM
03-30-2004 07:40 AM
Re: /sbin/init.d/sysedge stop flakey
The funny thing is that I did not create this script, this what sysedge sent.
I was wondering if I need to modify it?
I was wondering if I need to modify it?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-30-2004 07:45 AM
03-30-2004 07:45 AM
Re: /sbin/init.d/sysedge stop flakey
I really don't care who wrote it; I stand by my original comments. You might try manually killing the process by sending various signals. That would let you send a smaller set of escalating kills. Kill -9 is almost always a bad idea.
You at least need to set a sensible return code when the pid is not found.
You at least need to set a sensible return code when the pid is not found.
If it ain't broke, I can fix that.
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP