Using a shell script to shut down a Sun

STELLABO at CSHLAB.BITNET STELLABO at CSHLAB.BITNET
Sat Dec 17 04:34:34 AEST 1988


Many thanks to the many People who responded to my question about using a
shell script to shutdown a Sun, to do a level dump from crontab in the
middle of the night. I will summarize the responses for those of you who
are interested:

1) The vast majority of the responses suggest that the .profile or
/etc/profile file contain the commands to the level dump and bring up the
Sun multi-user. These files are sourced by the 'sh' process that is
started when the system is shutdown to single user mode. This method
answers my original question exactly, but there are some other ideas that
should not be overlooked.

2) Some suggested that the dump commands should be placed in rc.local.
Crontab would then reboot the computer, and the dump would be performed
when the computer is on it's way up. I like this idea because I think the
reboot re-sets the memory manager.  I can't be sure of this because it
does not say so in the SunOS 3.5 manuals.

3) Two responses said that I should not worry about going to single user
mode for level dump, as long as my Zero dump was done in single user mode.
One person claimed that they do a zero dump over several days with active
file systems.

4) Finally, there exists a package of shell scripts called "The System
Manager's Toolkit. It is available from: Claire Ledonne
(ledonne at violet.berkley.edu). This package includes many of the scripts to
do the above tasks.

I will probably write a shell script that will check for any user
processes, if there are none a reboot with a dump will be performed,
otherwise it will do an level dump with the active file system. I still
plan to my zero dumps in single user mode.

Fred J. Stellabotte
Computer Systems Manager
Cold Spring Harbor Laboratory
stellabo at cshlab.BITNET



More information about the Comp.sys.sun mailing list