Sunos 5.9

Hello

how do I properly shutdown the sunos5.9 that is housing my mailserver. We are going to be upgrading our power to the server room and all the machines need to be off.

Please help.

Thanks <img src="images/smiley_icons/icon_smile.gif" border=0 alt="Smile">

[325 byte] By [thecrozz] at [2007-11-25 22:38:46]
# 1

For Solaris you can use two commands:

# shutdown -y -i5 -g0

This command tells the server to go to run level 5 which is shutdown plus power off. Here you can substitute the 0 from -g0 for the number of seconds you want to give users to save work and log out ( eg -g60 ). I would only use this command for shutting down workstations or servers that are not currently providing services ( testbed servers for example ).

# shutdown -y -i0 -g0

This command will tell the system to go to run level 0 which will bring the system to the boot prom, from there you can issue power off command. Again you can add a <i>g</i> number for the time in seconds before the system goes down. Generally hosts providing networking services like smtp have a limited number of accounts with access to the shell ( probably just a group of administrators ) and a mail system should be configured to have any incoming email back up in a queue on a remote host while the system or data center is going through maintenance.

mlennon at 2007-7-5 14:09:49 > top of Java-index,Sun Hardware,Other Sun Hardware...
# 2

Thanks, the reason I asked is that we are upgrading the power to our server. We are currently using PMDF 6.2 for our mail so hopefully the shutdown command will work and hopefully no problems. I may have to shut down the mail software first then excute the command you gave me. So this command is universal or Sunos 5.9?

thecrozz at 2007-7-5 14:09:49 > top of Java-index,Sun Hardware,Other Sun Hardware...
# 3

Should work on all SVR4 versions of Solaris ( 7,8,9 and 10, for BSD version, Solaris 4 etc. should be something like /usr/ucb/shutdown -h now, this command is carried over to SVR4 Solaris as well ), you should read the man pages for these programs before you proceed. I don't have experience with your mail application, only qmail and sendmail. In a scenario like yours, I would make sure to have a remote queue for your site with a big queue life to keep email from being returned " undeliverable " to sending hosts.

mlennon at 2007-7-5 14:09:49 > top of Java-index,Sun Hardware,Other Sun Hardware...
# 4
So after I power on the Machine tomorrow morning. Is there anything I should startup or will it do so automatically?
thecrozz at 2007-7-5 14:09:49 > top of Java-index,Sun Hardware,Other Sun Hardware...
# 5

The correct procedure here is for you, the administrator, to record the status of the system prior to undertaking any maintenance work. This way when the system is brought back on line, if any service has not initialized you will have to attempt to start the service manually. Here is a rough guide:

1/ Record all services currently running on the server.

2/ Check that these services have startup scripts in /etc/init.d/

or are configured in /etc/inetd.conf

3/ Once you are happy the status of the system has been recorded then bring the server down to level 0 and power off.

4/ Perform your power upgrade.

5/ Boot the system to the default runlevel.

6/ Check that all the services are available according to the list you made prior to shutdown.

If you don't have a protocol ( SOP ) for these systems I would suggest that you call up representitives from all the various support departments responsible for this data centre and develop some, this will make your life a hell of allot better next time you've gotta upgrade the system/centre!!

mlennon at 2007-7-5 14:09:49 > top of Java-index,Sun Hardware,Other Sun Hardware...