Koozali.org: home of the SME Server

Enabling nut

Offline del

  • *
  • 765
  • +0/-0
Enabling nut
« on: September 24, 2006, 04:00:28 AM »
Hi All,

Can someone confirm that the procedure for enabling nut in v7 is:

/sbin/e-smith/config setprop nut status enabled
/sbin/e-smith/signal-event post-upgrade
/sbin/e-smith/signal-event reboot

or could it be:

sbin/e-smith/db/configuration setprop nut status enabled
/sbin/e-smith/signal-event post-upgrade
/sbin/e-smith/signal-event reboot

I don't remeber since I did it on v6 :cry:

Thanks in advanced
Del
If at first you don't succeed, then sky-diving is not for you!
"Life is like a coin. You can spend it anyway you wish, but you can only spend it once." --Author Unknown

Offline mdo

  • *
  • 355
  • +0/-0
Enabling nut
« Reply #1 on: September 24, 2006, 09:38:02 AM »
Here are a few options that are available on SME version 7:

/sbin/e-smith/config setprop nut status enabled
config setprop nut status enabled
db configuration setprop nut status enabled

and

signal-event xxxxx

Michael
...

Offline raem

  • *
  • 3,972
  • +4/-0
Enabling nut
« Reply #2 on: September 24, 2006, 10:31:28 AM »
mdo

/sbin/e-smith/config setprop nut status enabled
config setprop nut status enabled
db configuration setprop nut status enabled

There is no difference between any of those, they do the same thing, (loosley speaking) they are shortcuts to each other.
...

Offline del

  • *
  • 765
  • +0/-0
Enabling nut
« Reply #3 on: September 24, 2006, 03:33:25 PM »
Thanks guys, just wasn't sure, my SME6 had been running so long that I had forgot exactly what I did :oops:

Regards,
Del
If at first you don't succeed, then sky-diving is not for you!
"Life is like a coin. You can spend it anyway you wish, but you can only spend it once." --Author Unknown

Offline byte

  • *
  • 2,183
  • +2/-0
Enabling nut
« Reply #4 on: September 24, 2006, 04:29:27 PM »
And for completeness...

Setting up device/model and setting enabled.

Code: [Select]

config setprop nut Device /dev/ttyS1
config setprop nut Model apcsmart
config setprop nut status enabled


Show nut is correctly configured with our above settings.

Code: [Select]
config show nut

nut=service
    Device=/dev/ttyS1
    Model=apcsmart
    status=enabled



Then don't forget to expand the relevent templates...

Code: [Select]
expand-template /etc/sysconfig/ups
expand-template /etc/ups/ups.conf
expand-template /etc/ups/upssched.conf
expand-template /etc/ups/upsmon.conf
expand-template /etc/ups/upsd.users
expand-template /etc/ups/upsd.conf


And say hello to the ups  :lol:

Code: [Select]
upsc UPS@localhost
--[byte]--

Have you filled in a Bug Report over @ http://bugs.contribs.org ? Please don't wait to be told this way you help us to help you/others - Thanks!

Offline del

  • *
  • 765
  • +0/-0
Enabling nut
« Reply #5 on: September 24, 2006, 06:33:48 PM »
Hi Byte,

I never did any of those in SME6, I am using a USB UPS and it shutdown my server correctly, so when I come to do this on SME7 (tomorrow) will I need those commands as ttyS1 is a serial port? Thanks or your help.

Regards,
Del
If at first you don't succeed, then sky-diving is not for you!
"Life is like a coin. You can spend it anyway you wish, but you can only spend it once." --Author Unknown

Offline byte

  • *
  • 2,183
  • +2/-0
Enabling nut
« Reply #6 on: September 24, 2006, 07:30:53 PM »
That's right you wont have to do the Device bit as you have a USB UPS.
--[byte]--

Have you filled in a Bug Report over @ http://bugs.contribs.org ? Please don't wait to be told this way you help us to help you/others - Thanks!