Well...

The /devel/ s/b /usr/ that slipped in from my test version.  You're right.

However, killproc name is equivalent to kill -9, with the function looking
for the pid in /var/run, which I already do in the script.  

And I don't want a -9 I want to send sigint so that ntop can shutdown
cleanly.  I send it to all the ntop pids so that if something is deadlocked,
there will still be one of the threads to process it.

I suppose you could wait 10-15 seconds and check, then do a -9, but I didn't
want to slow up the script any more than it's already slowed down.

Thoughts?

-----Burton

 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf
Of Randy Gordey
Sent: Monday, October 10, 2005 8:26 AM
To: [email protected]
Subject: [Ntop-dev] ntop-3.2rc2_fc4-1.i386.rpm

ntop is working on my Fedora Core 4.

Stopping it was a little bit of a problem.

I needed to make the following changes to the init script:



--- /etc/rc.d/init.d/ntop       2005-10-10 09:17:55.000000000 -0400
+++ /etc/rc.d/init.d/ntop       2005-10-05 16:07:24.000000000 -0400
@@ -561,7 +561,7 @@
     if [ $rc = 0 ]; then
       logger -p ${ntopusesyslog} -t ${name}${instance} -- "INITD - Sending
SIGINT to ${pid}"
       if [ "${debug}" = "y" ]; then echo "Sending SIGINT to ${pid}"; fi
-      kill -s SIGINT ${pid}
+      killproc ntop
       RETVAL=$?
       rm -f ${ntopdbfilepath}/ntop.pid
     else
@@ -578,7 +578,7 @@
   echo 
 
   if [ $RETVAL != 0 ]; then
-    pids=`ps axf | grep '\/devel\/bin\/ntop' | awk '{ printf(" %s", $1) };
END { print "" }'`
+    pids=`ps axf | grep '\/usr\/bin\/ntop' | awk '{ printf(" %s", $1) 
+ };
END { print "" }'`
     if [ "${pids}" != " " ]; then
       logger -p ${ntopusesyslog} -t ${name}${instance} -- "INITD - Sending
SIGINT to ${prog}...${pids}"
       if [ "${debug}" = "y" ]; then echo "Sending SIGINT to
${prog}...${pids}"; fi



Thanks again for your time and efforts!


~R.Gordey


_______________________________________________
Ntop-dev mailing list
[email protected]
http://listgateway.unipi.it/mailman/listinfo/ntop-dev

_______________________________________________
Ntop-dev mailing list
[email protected]
http://listgateway.unipi.it/mailman/listinfo/ntop-dev

Reply via email to