[Nut-upsuser] New NUT user with HP R3000XR problem

Arjen de Korte nut+users at de-korte.org
Wed May 27 21:51:44 UTC 2009


Citeren Brother Railgun of Reason <alaric op caerllewys.net>:

>>> babylon4:root:/opt/nut:25 # sbin/upsd
>>> Network UPS Tools upsd 2.4.1
>>> listening on 127.0.0.1 port 3493
>>> listening on ::1 port 3493
>>> /opt/nut/var is world readable
>>> Connected to UPS [tokamak]: bcmxcp-tokamak
>>> Maximum number of connections limited to 256 [requested 1024]
>> Weird, apparently your system has a limited number of file descriptors
>> available. I have a feeling that this is not a standard operating system.
> I was a little puzzled by that myself.  It's Solaris 10 x86 running on a
> pretty substantial box, it shouldn't be an OS limitation.

Oops, looking at the code I saw this isn't a warning, but a (fatal)  
error instead (this was not one of the most descriptive error messages  
I ever wrote). I now recall that this value is OS dependent, so you  
probably want/need to limit this in upsd.conf through the MAXCONN  
parameter (which in your case seems to be mandatory).

I'm not quite sure what would be the better thing to do in case the  
(default) MAXCONN value is too high:

1) Bail out with a more descriptive error message
2) Adjust the number of connections to the maximum allowed (with  
message to syslog)

I think it would be much more user friendly to do the latter, but  
opinions on this are welcomed.

>> For whatever reason, you can't connect to localhost. I've never seen this
>> before. The only thing I can imagine now is that some kind of policy exists
>> that doesn't allow you connect through localhost because this is OS is
>> running as a guest on top of another system.
> Nope, this is not a client OS or vhost.  This is the global zone of a
> Solaris 10 machine, and as you can see, the above was running as root.

This all makes sense now. The server is not running.

> BTW, upsd.conf is default with everything commented out, which should
> result in listening on everything:
>
> # This defaults to the global IPv4 listening address and port 3493. You
> # may specify each interface you want upsd to listen on for connections,
> # optionally with a port number.

We need to change this. This used to be the case in older versions,  
but we now default to a (safer) localhost only.

[...]

> Could this be because something is limiting it to 256 connections?
> (Not that I'm ever going to need even a tenth of that....  16
> connections would be more than I'm ever going to need to use.)
>
> I'm wondering whether I should go tweak the source to request only 256
> connections (or even 128) and see if upsd still dies on startup.

Yes, see a couple of lines down in upsd.conf (no need to tweak the  
sources for that).

Best regards, Arjen
-- 
Please keep list traffic on the list




More information about the Nut-upsuser mailing list