Arjen de Korte ha scritto:
That is where the problem lies. Currently, the upsd server connects to
drivers in a one driver (instance), one UPS mode:
UPS-1 --- driver-A ----+ +---- upsmon client
| |
UPS-2 --- driver-B --- upsd server --- upsmon client
| |
UPS-3 --- driver-C ----+ +---- upsmon client
So each UPS (or outlet, for the clone driver) is exactly one connection
and that's what the socket protocol we use is built on (and for this
reason, we need to use the clone driver if we want to use the load
segment switching).
Ok, I clearly see your point now, the NSM would not follow this design
rule, however it could be an acceptable solution, requiring not much
code and no modification at all to the current structure.
So this will require 'some' work. And what becomes immediate clear in
the above picture, it probably doesn't make much sense to change the
socket protocol between drivers and server, but instead integrating the
NSM functionality in the server would be much easier.
Sure, but a single driver could contain all the (vendor) specific logic
without tainting the upsd code (starting from a netxml-ups clone and my
patch). On the other side I think that, discarding the separated driver
solution, it could still sound reasonable to provide a NSM in the
mge-xml subdriver for the moment, even though currently it is useful on
small setups only. Isn't it?
Then the question remains, why would we want this in the first place?
The NMCs are already servers themselves so adding a upsd server will
only complicate matters. Instead, you could do away with NUT entirely,
by using an appropriate NSM client that directly talks to the NMC and
not have to bother setting NUT up at all. I haven't seen a compelling
argument that adding NUT here is a good idea.
Because the NSM, for some reason I haven't figured out yet, it's cpu
hungry on some machines, because I don't need all that useless logging
and other things for such a simple task, because I already need NUT for
collecting stats with collectd, because I do not want an annoying http
server running for just a simple UPS client on a production machine,
because a "dpkg --set-selection < package_list" && "apt-get upgrade"
it's much easier and so on. I'm much more satisfied with the patched
NUT, I just wanted to make it useful for other people adding redundancy
and maybe asking for inclusion if possible.
Regards,
Marco
_______________________________________________
Nut-upsdev mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/nut-upsdev