Computing.Net > Forums > Linux > auto shutdown linux server

auto shutdown linux server

Reply to Message Icon

Original Message
Name: abdul
Date: September 18, 2002 at 05:48:48 Pacific
Subject: auto shutdown linux server
OS: redhat 7.2
CPU/Ram: pentium 128mb ram
Comment:


we are running 2 linux server in our network
server1 is configured to shutdown automatically at a predefine time
is there any way to shutdown server2 automatically only when server1 is shutting down.
i want to automate the task
thanks in advance


Report Offensive Message For Removal

Response Number 1
Name: 3Dave
Date: September 18, 2002 at 07:00:47 Pacific
Subject: auto shutdown linux server
Reply: (edit)

How about dumping something in /etc/init.d/rc0.d?


Report Offensive Follow Up For Removal

Response Number 2
Name: Def
Date: September 18, 2002 at 07:18:55 Pacific
Subject: auto shutdown linux server
Reply: (edit)

You can make shell script and put them to cron

script.sh
--
if a=`ping -q -c 1 -w 3 server_ip 2>/dev/null`; then printf "";else poweroff;fi
--

If primary server not reply to ping query - secondary server turn off by command poweroff (also you can use command init 0)

-----------
Sincerely,
Andrew A.Romanchenko
AlarIT programmer
http://www.AlarIT.com


Report Offensive Follow Up For Removal

Response Number 3
Name: abdul
Date: September 19, 2002 at 00:16:32 Pacific
Subject: auto shutdown linux server
Reply: (edit)

actually i donot want to ping server1 from server2 continuosly

Any other method ?

thanks


Report Offensive Follow Up For Removal







Use following form to reply to current message:

   Name: From My Computing.Net Settings
 E-Mail: From My Computing.Net Settings

Subject: auto shutdown linux server

Comments:

 


  Homepage URL (*): 
Homepage Title (*): 
         Image URL: 
 
Data Recovery Software