UPS shutdown
-
I have a working package. However it needs error handling and features to be added, which I will work on. Heres the package edit screen. And below that the log from clicking change. You can see it stops the old and starts the service back up. Also it starts successfully on reboot.
**I really needs one of the devs help in getting the package manager to work. If I can change the url somehow to run it off my server. I looked into it and it talks to xmlrpc.php. I can't test the install and uninstall functions and have to perform them at the command line.
Also the global booting variable is false when the packages are being synced. Is there a way to know when the system is booting so the sync package command doesn't start the package, that way when the rc.d scripts execute it will start. Otherwise it starts, stops, then starts again.**
Oct 21 03:50:09 upsmon[2160]: UPS sparky@10.10.1.200 battery is low Oct 21 03:50:09 upsmon[2160]: UPS sparky@10.10.1.200 battery is low Oct 21 03:50:09 upsd[2157]: Client monuser@10.10.1.200 logged into UPS [sparky] Oct 21 03:50:09 upsd[2157]: Connection from 10.10.1.200 Oct 21 03:50:09 upsmon[2159]: Startup successful Oct 21 03:50:09 upsd[2157]: Startup successful Oct 21 03:50:07 upsd[2156]: Connected to UPS [sparky]: apcsmart-ttyd0 Oct 21 03:50:07 apcsmart[2155]: Startup successful Oct 21 03:49:57 php: nut: Starting service Oct 21 03:49:57 php: nut: Taking control of port Oct 21 03:49:56 php: nut: Releasing control of port Oct 21 03:49:55 apcsmart[1970]: Signal 15: exiting Oct 21 03:49:55 upsd[1972]: Signal 15: exiting Oct 21 03:49:55 upsmon[1975]: Signal 15: exiting Oct 21 03:49:55 php: nut: Stopping service
-
Wanted to add when the power fails it starts shutdown and halts the box. This is from remote syslog. I need to set the delay as right now it shutsdown immediately on powerfail.
10-21-2006 01:17:08 Daemon.Info 10.10.1.200 Oct 21 05:18:05 upsd[622]: Signal 15: exiting 10-21-2006 01:17:06 Auth.Notice 10.10.1.200 Oct 21 05:18:03 shutdown: halt by root: 10-21-2006 01:17:06 Daemon.Info 10.10.1.200 Oct 21 05:18:03 upsd[622]: Host 10.10.1.200 disconnected (read failure) 10-21-2006 01:17:01 Daemon.Notice 10.10.1.200 Oct 21 05:17:58 upsmon[625]: Auto logout and shutdown proceeding 10-21-2006 01:17:01 Daemon.Critical 10.10.1.200 Oct 21 05:17:58 upsmon[625]: Executing automatic power-fail shutdown 10-21-2006 01:17:01 Daemon.Info 10.10.1.200 Oct 21 05:17:58 upsd[622]: Client monuser@10.10.1.200 set FSD on UPS [sparky] 10-21-2006 01:17:01 Daemon.Notice 10.10.1.200 Oct 21 05:17:58 upsmon[625]: UPS sparky@10.10.1.200 on battery
-
Left to it's own devices NUT would normally trigger a shutdown on LB (low battery). This should be the correct process (otherwise you'll start a shutdown if the power goes out for a fraction of a second, probably not what you want).
I'd also be interested in a client only option - for those of us already running a NUT server.
-
Thats probably what it is as the UPS I was testing with is old and has a low battery condition. I have others but there used for production boxes. The client is easy to implement as well. What I'm trying to figure out is how to change the pacakge url so I can install and uninstall the package to test everything out.
-
Okay I've run into a snag. Can one of the devs tell me how I can change the url for the package manager so I can test this out?
"xmlrpcbaseurl" => "www.pfsense.com",
"xmlrpcpath" => "/pfSense/xmlrpc.php",in /etc/inc/globals.inc
–Bill
-
Okay I've run into a snag. Can one of the devs tell me how I can change the url for the package manager so I can test this out?
"xmlrpcbaseurl" => "www.pfsense.com",
"xmlrpcpath" => "/pfSense/xmlrpc.php",in /etc/inc/globals.inc
–Bill
Thanks I had looked in the globals.inc before but I don't have the xmlrpc.php file. I got a copy of the xmlrpc.php and will try this out.
http://cvstrac.pfsense.com/rlog?f=www/xmlrpc/xmlrpc.php
-
I got the package installer up and running on my local server. I can install the package now and have worked on the gui interface for it. I need to implement this in the backend code. Hopefully in a week I will have it committed and you all can start testing it out.
-
Tomorrow (Friday) it should be committed. I just have to add more models to the list and check a few things.
The interface is shown in the above post. Its plain but gets the job done. Suggestions would be appreciated. However due to the package system generating the page theres not much more I can do unless I want to build my own configuration page, which I might work on later.
Local, local monitoring with remote access, and remote monitoring are all supported.
-
The package is committed. Let me know how it works. I've only gotten to test it on a APC Smart-UPS. If there are cable types, etc you need added let me know. I went through the list and added all the major brands, etc.
-
This is as far as I get when trying to install nut:
Downloading package configuration file… done.
Saving updated package information... done.
Downloading nut and its dependencies...It will hang there at downloading dependencies and will never complete.
-
This is as far as I get when trying to install nut:
Downloading package configuration file… done.
Saving updated package information... done.
Downloading nut and its dependencies...It will hang there at downloading dependencies and will never complete.
The FreeBSD mirror containing the dependencies was up and down all morning. I thought it was back up. I will see if theres another one I can use instead.
-
I've added more cable types and made some changes to get USB UPS's working. You need to specify auto as the port if using USB. I have also built the development tree version of newhidups, which should be tested soon. If it resolves more of the issues I will commit it. If anybody is interested in testing it contact me either by private message or email. Any feedback on this package would be appreciated.
-
How do I add my ups driver to NUT ( powercom ) ?
How to change the shutdown times?
thanks ;)
-
Would be nice to implement a screen showing the status of the UPS… ;D
-
I have done a rewrite of the NUT package which cleaned up the code, and fixed permission errors. I have also added a status tab which displays the model, status, load, battery charge/voltage, input/output voltage. and temperature.
Feedback on if the package works for you, what doesn't work, ideas for improvement would be appreciated.
-
hmmm, does not work for me…
seems not to find my smart-ups via calbe (com1) :'(
I configured every setting that's NOT optional... and I get the following:
Feb 15 22:51:45 php: nut: Service failed to start: check configuration
Feb 15 22:51:45 php: nut: Starting service
Feb 15 22:50:44 php: nut: Service failed to start: check configuration
Feb 15 22:50:43 php: nut: Starting service
Feb 15 22:49:34 php: /pkg_mgr_install.php: Beginning package installation for nut.UPS Monitoring LOCAL
Local UPS Name UPS_IDEN
Local UPS Model SMART-UPS
Local UPS Port COM1 (ttyd0)any idea ?
-
hmmm, does not work for me…
seems not to find my smart-ups via calbe (com1) :'(
I configured every setting that's NOT optional... and I get the following:
Feb 15 22:51:45 php: nut: Service failed to start: check configuration
Feb 15 22:51:45 php: nut: Starting service
Feb 15 22:50:44 php: nut: Service failed to start: check configuration
Feb 15 22:50:43 php: nut: Starting service
Feb 15 22:49:34 php: /pkg_mgr_install.php: Beginning package installation for nut.UPS Monitoring LOCAL
Local UPS Name UPS_IDEN
Local UPS Model SMART-UPS
Local UPS Port COM1 (ttyd0)any idea ?
You need to specify a cable type, that is why is it in () next to Smart-UPS. If that is an APC cable look at both ends. In the plastic it will have the cable number engraved. Specify that cable in the nut cable type selection.
-
Hmmm, did it that way, but it does not work either :-(
And the service is being started, tells me successful, but then does not start at all :-\
-
Hmmm, did it that way, but it does not work either :-(
And the service is being started, tells me successful, but then does not start at all :-\
What color is your serial cable and what number is on it? I will look into it. I have an APC Smart UPS with a gray cable, number 940-0095B. There are about 10 different cables so it is important that you actually look at the cable for the number. If you pick the wrong cable type it will not work. It would be helpful if you could provide more information.
-
Heres a snapshot of my configuration and the status. The cable I have is technically for a Back-UPS Pro UPS, I have a few UPS's and cables have gotten swapped around. I did test with the actual Smart-UPS cable and it works as well. The protocol is the same, but every model cable is wired slightly different. The UPS model Smart-UPS, Back-UPS Pro tells the driver what subset of the protocol the UPS supports, such as temperature, etc