[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [K12OSN] Using ltspinfo to shutdown clients

On Wed, 2008-09-24 at 09:43 -0700, Robert Arkiletian wrote:

> >
> > #!/bin/bash
> >
> > # lounge machines
> > /usr/bin/ltspinfo --host=lounge-a --shutdown
> > /usr/bin/ltspinfo --host=lounge-b --shutdown
> > /usr/bin/ltspinfo --host=lounge-c --shutdown
> >
> > # dhcp machines
> > START=101
> > END=249
> >
> > NETWORK="192.168.105."
> >
> > for i in `seq $START $END`; do
> >  IP="$NETWORK$i"
> >  X=`/usr/bin/ltspinfo --host=$IP --shutdown`
> >  echo "$IP: $X"
> > done
> >
> >
> I warn people not to enable this feature as it's a security issue in
> ltsp 4.x. However, george, if you do use it I would put in a time
> interval for each powerdown becuase the  loop to issue powerdown runs
> very quickly. So it's effectively like having 30 people hit power off
> button at the same time. That could cause a power surge (maybe it's
> called spike) for equipment still up and may potentially damage
> something.
> A 1 second interval (sleep 1s) should be sufficient.
A power down can cause a "phased ringing" of the current but that is
unlikely to instigate damage unless the circuit is running at full
The bigger issue is using similar methods to power _on_ the clients.
That can cause a power surge that pops breakers and can also flood the 
DHCP capabilities since UDP is pretty brain dead.

try 'sleep .1s' to spread out the load. A full second is fine, too.
James P. Kinney III          
CEO & Director of Engineering 
Local Net Solutions,LLC                           

GPG ID: 829C6CA7 James P. Kinney III (M.S. Physics)
<jkinney localnetsolutions com>
Fingerprint = 3C9E 6366 54FC A3FE BA4D 0659 6190 ADC3 829C 6CA7

This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]