->Date: Thu, 14 Mar 2002 05:30:07 +0200
->From: " Petrov M.I." <[EMAIL PROTECTED]>
->Subject: LPRng: Strange thing.
->X-Originating-IP: 194.44.216.19 via proxy mao-lan195.gluk.org 
[194.183.183.195]
->To: [EMAIL PROTECTED]
->MIME-version: 1.0
->Content-transfer-encoding: 8bit
->
->Hi All.
->I have problem with may start-stop lpd script. When I start  lpd daemon - 
./lpd start - this work correctly. 
->When I stop it - ./lpd stop - this don't work, lpd daemon still work. When I 
copy lpd to file with other
->name ( for instance qqq) and do ./qqq stop - it works! What is this? My lpd 
file:

Call your script something else. 

the `ps ${PSHOWALL} | awk '/lpd/{ print $1;}'` finds two lpd programs - the 
daemon and the start/stop script then kills the script BEFORE the daemon.
I've been burnt by this before.

->....
-># See how we were called.                                               
->case "$1" in                                                            
->  start)                                                                
->        # Start daemons.                                                
->        echo -n "Starting lpd: "                                        
->        ${LPD_PATH}                                                     
->        RETVAL=$?                                                       
->        echo                                                            
->        ;;                                                              
->  stop)                                                                 
->        # Stop daemons.                                                 
->        echo -n "Shutting down lprng: "                                 
->        kill -INT `ps ${PSHOWALL} | awk '/lpd/{ print $1;}'` >/dev/null 
->        RETVAL=0                                                        
->        echo                                                            
->        ;;                                                              

Cheers

Allen

Allen Witt                      email:  [EMAIL PROTECTED]


-----------------------------------------------------------------------------
YOU MUST BE A LIST MEMBER IN ORDER TO POST TO THE LPRNG MAILING LIST
The address you post from MUST be your subscription address

If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body.  For the impatient,
to subscribe to a list with name LIST,  send mail to [EMAIL PROTECTED]
with:                           | example:
subscribe LIST <mailaddr>       |  subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST <mailaddr>     |  unsubscribe lprng [EMAIL PROTECTED]

If you have major problems,  send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-----------------------------------------------------------------------------

Reply via email to