SUMMARY: Strange happenings with startup/shutdown scripts

From: Barry Deevey <>
Date: Thu Jan 03 2002 - 07:27:04 EST
Many thanks to everybody that took the time and effort to reply,
particularly Matt Santimore, John Julian, Mark McManus, Darren Dunham & Sal

The problem was that as well as putting the K* scripts in /etc/rc0.d
/etc/rc1.d /etc/rc2.d /etc/rcS.d  I'd also put them into /etc/rc3.d, and
both the Kill and Start scripts do not get ran until the system enters the
relevant run level, so you need to ensure that the kill scripts are in a
different level to the Start scripts.

Another point that is worth mentioning, is that the reboot command does not
work in the same way as shutdown.  Reboot will not run any of the rc scripts
on shutdown - You probably already knew this, but it had me doubting my
sanity for a while!!

Again, many thanks for your help.

Best Regards,


> -----Original Message-----
> To:	''
> Subject:	Strange happenings with startup/shutdown scripts
> Hi all,
> I'm trying to use /etc/rc?.d to start and stop various stuff on shutdown
> and
> startup of our Sun Ultra 10 server.  I used a 'K' prefix for the apps that
> needed to be stopped on shutdown and an 'S' for startup.  As I was playing
> around, it seemed that the 'K' scripts were not being ran until the
> machine
> had booted.  I tested this by creating a noddy script that slept for 2
> minutes and then created a file.  This proved that it definately wasn't
> being ran on shutdown.  I created the script in /etc/init.d and linked my
> 'K' files in directories /etc/rc0.d/, rc1.d, rc2.d & rc3.d - I have only
> used /etc/rc3.d for the startup link files.
> I was under the impression that the 'K' scripts were ran on shutdown, but
> this does not seem to be the case.  Has anybody ever come across this
> before??
> Thanks for any replies, they're very much appreciated.
> Best Regards,
> Barry Deevey
> Applications Developer
> sunmanagers mailing list
sunmanagers mailing list
Received on Thu Jan 3 06:24:14 2002

This archive was generated by hypermail 2.1.8 : Thu Mar 03 2016 - 06:42:31 EST