Network UPS Connect (NOT HOST)

greenhornet

New Member
Jan 31, 2025
13
0
1
I've been searching and most of what I've found suggests installing NUT, connecting the UPS to the Proxmox server by USB and using that as the UPS host. This is not what I want to do.

I have an existing UPS (APC) with a network card and have several other servers running off it (it's big) that all connect by network. I would like to add Proxmox as a connected server, so network shutdown will work on all devices without a USB connection. Can anyone make a suggestion on how to accomplish this or provide a link to something that shows how it was successfully done?

PS - I know how to do this on the individual VM clients. It's the actual Proxmox server host that I'm not sure of.
 
Well I just set my UPS up on a new cluster. FWIW I used the nut client, and just pointed it to the nut server, which just involved installing the nut client onto the pve hosts, and setting up the /etc/nut/upsmon.conf file with the server info and testing the shutdown process.

Now I can't remember what the APC's use as a client, years ago I seem to remember an APC specific client, not sure if this would work: https://wiki.debian.org/apcupsd



For grins you could run the upsc tool to see if it at least see's the UPS:
Code:
upsc ups@<ups_ip>

Sorry I don't have more APC specific info to share, but curious what client they use today.
 
I've been searching and most of what I've found suggests installing NUT, connecting the UPS to the Proxmox server by USB and using that as the UPS host. This is not what I want to do.

I have an existing UPS (APC) with a network card and have several other servers running off it (it's big) that all connect by network. I would like to add Proxmox as a connected server, so network shutdown will work on all devices without a USB connection. Can anyone make a suggestion on how to accomplish this or provide a link to something that shows how it was successfully done?

PS - I know how to do this on the individual VM clients. It's the actual Proxmox server host that I'm not sure of.
Proxmox Virtual Environment will be responsible of the VMs shutdown sequence.
Now the host can indeed be asked to shutdown by nut client on it.
Your UPS has a network card. The driver should be : snmp-ups
look at and test : https://networkupstools.org/docs/man/snmp-ups.html
BR
 
Proxmox Virtual Environment will be responsible of the VMs shutdown sequence.
Now the host can indeed be asked to shutdown by nut client on it.
Your UPS has a network card. The driver should be : snmp-ups
look at and test : https://networkupstools.org/docs/man/snmp-ups.html
BR
This is talking about "building a driver." I wish I was good enough to know how to do that.

Is it seriously that involved? Can I not just install a couple packages and run a config?

If Proxmox doesn't easily work with network APC UPS cards, it may be a non-stater for me. I find that hard to believe though.
 
I fail to understand what problems/difficulties you are facing - but maybe I need to better understand your requirements/setup.

If I understand you correctly - you would like to setup a host ups server connected to the UPS via NW, that can serve any clients monitoring that server - to enable them to shutdown correctly.

AFAICT this should absolutely be possible through the NUT server/client setup.

Let me start off by saying, I do not have a NW connected UPS, but rather a USB one (probably more common, as most web searches will show, & you have already alluded to that in your OP). I connected mine to the Proxmox host via USB, setup a NUT server on the host & other clients can easily monitor that, & take the appropriate actions on their side should they need to. I see no reason why you can't do the same with your NW attached UPS.

From your OP:
PS - I know how to do this on the individual VM clients. It's the actual Proxmox server host that I'm not sure of.
we can assume your UPS is already connected (hopefully SNMP) on your NW.

Since it is always best not to make major changes/adjustments to a Proxmox host node, it would be better to create a VM/LXC to do this job. I know as I've already written, that I personally actually did this on the host node itself, but that was because mine is connected via USB, & I didn't want to mess with USB-passthrough. But in your case where it is actually NW connected, you should/may as well do it in a VM/LXC.

I cannot specifically guide you for your UPS model & NW, but as a brief guide, this is what I would do in your case:

1. Create a Debian VM/LXC, I'd actually use a small LXC for this - as this server will actually have a very limited workload.

2. Make sure this VM/LXC is 'on the same/has access to' NW as that of the UPS.

3. Start the above VM/LXC & after updating, run: [sudo] apt install nut nut-client nut-server (you may also add nut-snmp but I'm pretty sure its not necessary & will be available on its own).

4. You can now follow any of the online guides (see below) on how-to-configure the server. But in your case you will start the SNMP discovery stage of your UPS with:
[sudo] nut-scanner -S -s 192.168.1.xxx -e 192.168.1.xxx (replace start address & end address as applicable).

(instead of the commonly USB-search used [sudo] nut-scanner -U) . As detailed here for an SNMP search.

5. If your APC NW-attached UPS is found with the above (4.), you are good-to-go.

6. You will need to adjust the correct driver & config in /etc/nut/ups.conf for your UPS using the snmp-ups as shown here in the examples.
See here a user who has it configured this way.

7. Setup all the rest as usual - using the online guides. I personally used this one & it worked flawlessly. Adjust as necessary.

You can then setup any nut clients on other hosts, VMs etc. as above.

I can't really help much more - as I don't have your HW/setup, but I believe it is perfectly doable.


Good luck.
 
If I understand you correctly - you would like to setup a host ups server connected to the UPS via NW, that can serve any clients monitoring that server - to enable them to shutdown correctly.
No. I have a UPS with a network card that already does that. I just need to join the Proxmox server to that UPS card over network. not USB. You would think it's simple but 90% of what I've found are people either 1. creating a host server (as you mentioned) or 2. using a USB cable.
 
Sorry for trying - but I must tell you, your description of the advice you seek (both in the OP & the latest), is not completely clear.

I just need to join the Proxmox server to that UPS card over network. not USB.
What do you mean by join? If both the Proxmox node & the UPS are on the same NW, are they not already "joined"?

If by "join" you mean - take action/serve to others based on UPS monitoring - advice is already given.

Please note - with the Nut application on the Proxmox node, you can easily shutdown that node & all of its VM's & LXCs gracefully.
 
Sorry for trying - but I must tell you, your description of the advice you seek (both in the OP & the latest), is not completely clear.


What do you mean by join? If both the Proxmox node & the UPS are on the same NW, are they not already "joined"?

If by "join" you mean - take action/serve to others based on UPS monitoring - advice is already given.

Please note - with the Nut application on the Proxmox node, you can easily shutdown that node & all of its VM's & LXCs gracefully.
I need the Proxmox server to accept remote shutdown commands from the UPS, via the UPS's built in network card.

As simple as I can state it: When the power goes out, I need the Proxmox server to know that and start shutting down. I can't use a USB cable to accomplish this, it must be by APC's network card communications.
 
I need the Proxmox server to accept remote shutdown commands from the UPS, via the UPS's built in network card.

As simple as I can state it: When the power goes out, I need the Proxmox server to know that and start shutting down. I can't use a USB cable to accomplish this, it must be by APC's network card communications.
Just curious, how do your other nodes communicate with the UPS? Using SNMP?
 
As I said above - follow my instructions & it will do exactly that.

Not needed - see my instructions above.
Hello.
I think the SNMP NUT driver is in this separated package and that it is needed.
Personally, I let Proxmox host shutdown the CT/VMs in accordance with the priority I defined in Proxmox VM/CT settings.
thus I configure NUT only on proxmox hosts, not in VM/CTs.
 
  • Like
Reactions: waltar
I think the SNMP NUT driver is in this separated package and that it is needed.
I don't think so. I did a nut-scanner -S on my system that only has the main nut package installed & it completed successfully.

Also here is output, from the same node:
Code:
# dpkg -l nut*
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version      Architecture Description
+++-==============-============-============-=================================
ii  nut            2.8.0-7      all          network UPS tools - metapackage
un  nut-cgi        <none>       <none>       (no description available)
ii  nut-client     2.8.0-7      amd64        network UPS tools - clients
un  nut-i2c        <none>       <none>       (no description available)
un  nut-ipmi       <none>       <none>       (no description available)
un  nut-modbus     <none>       <none>       (no description available)
un  nut-monitor    <none>       <none>       (no description available)
ii  nut-server     2.8.0-7      amd64        network UPS tools - core system
un  nut-snmp       <none>       <none>       (no description available)
un  nut-xml        <none>       <none>       (no description available)
 
  • Like
Reactions: waltar
I don't think so. I did a nut-scanner -S on my system that only has the main nut package installed & it completed successfully.

Also here is output, from the same node:
Code:
# dpkg -l nut*
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version      Architecture Description
+++-==============-============-============-=================================
ii  nut            2.8.0-7      all          network UPS tools - metapackage
un  nut-cgi        <none>       <none>       (no description available)
ii  nut-client     2.8.0-7      amd64        network UPS tools - clients
un  nut-i2c        <none>       <none>       (no description available)
un  nut-ipmi       <none>       <none>       (no description available)
un  nut-modbus     <none>       <none>       (no description available)
un  nut-monitor    <none>       <none>       (no description available)
ii  nut-server     2.8.0-7      amd64        network UPS tools - core system
un  nut-snmp       <none>       <none>       (no description available)
un  nut-xml        <none>       <none>       (no description available)
Indeed, nut-scanner does not need nut-snmp.
 
  • Like
Reactions: dj423 and waltar
I think the SNMP NUT driver is in this separated package and that it is needed.
Personally, I let Proxmox host shutdown the CT/VMs in accordance with the priority I defined in Proxmox VM/CT settings.
thus I configure NUT only on proxmox hosts, not in VM/CTs.
I understand that - thanks - but we're not even to that point yet. I've got to get the Proxmox server talking to the UPS network card first. I'm still struggling. It sounds like I don't need the nut-snmp package from the comments above but I'm still not clear on what exactly I should be installing and configuring.
 
but I'm still not clear on what exactly I should be installing and configuring.
I gave you all the instructions above - plus link to an easy-to-use tutorial above. Just follow all of them using your host node. I personally would first test them in a VM. So spin up a Debian VM & test from there. Once you got it working. Just delete that VM & do it on the host itself. It really is not that difficult. I've got it running on my host.
 
I gave you all the instructions above - plus link to an easy-to-use tutorial above. Just follow all of them using your host node. I personally would first test them in a VM. So spin up a Debian VM & test from there. Once you got it working. Just delete that VM & do it on the host itself. It really is not that difficult. I've got it running on my host.
Where?

You made a longer post above which started with the assumption that I wanted to set up a host UPS server (which I don't need) and
"we can assume your UPS is already connected (hopefully SNMP) on your NW." - this is true but the Proxmox SNMP connection is not working. This is the challenge.

Can you link to exactly which post above has guidance on how to connect the Proxmox server to the UPS network card please? I've got people telling me to do something and then either coming back and saying never mind, it's not needed or going down a path of how to shut down the individual guests, which is WAY past the point of where I need to be.

I mean, just objectively this thread has kind of made my point. Connecting Proxmox to a UPS NETWORK card is not straightforward nor simple. I appreciate everyone trying to help. I just don't know which posts I should and should not be following.
 
Last edited: