I skipped pwrstatd, as I had already done enough research on NUT to know that it was the direction I wanted to go. In particular, I really like having notifications for power outages. If you haven’t already done so, I previously wrote a guide to add a manual shutdown/reboot switch in OH. It uses pr… Answer from rpwong on community.openhab.org
🌐
Jeff Geerling
jeffgeerling.com › blog › 2025 › nut-on-my-pi-so-my-servers-dont-die
NUT on my Pi, so my servers don't die - Jeff Geerling
February 24, 2025 - CM to Pi 4 adapter board. Before doing anything else, install NUT with sudo apt install -y nut. This will install nut-client, nut-server, and other UPS tools you will use later · Then, assuming you have your UPS plugged into a USB port on your Raspberry Pi, run ...
🌐
Pi My Life Up
pimylifeup.com › home › monitoring a ups with nut on the raspberry pi
Setting up a NUT Server on your Raspberry Pi
February 28, 2026 - I thought I bought a model that had a webcard intreface but alas, my model didn’t. So I went the Raspberry PI 4B route and this made so much sense and made it so easy. My 2 weeks of frustration were eliminated in 2 hours of config and following your guide. Thank you so much! ... Awesome guide. Really clear. Thanks! ... Seems that under the “Installing the Nut-GUI Server” section, steps 1-3 of editing the /etc/nut/hosts.conf file is premature as it is not there yet.
Discussions

Setting up NUT on a Raspberry Pi
Your tutorial gave me post-NUT clarity. More on reddit.com
🌐 r/homelab
6
6
November 22, 2021
Beginner's Guide to Network UPS Tools (NUT) on a Raspberry Pi
UPDATE (February 15, 2022): Updated with instructions for adding a second UPS Since I don’t want my OH installation to be corrupted by a power failure, I purchased a CyberPower UPS, and connected it to my Raspberry Pi using Network UPS Tools (NUT). There are various topics in the community ... More on community.openhab.org
🌐 community.openhab.org
19
17
July 22, 2019
[gelöst] Nut Server auf Raspi installieren
Versuche krampfhaft einen NUT Server zu installieren. Habe schon diverse Anleitungen hier im Forum durchforstet. USV wird an USB erkannt. pi@raspberrypi:~ $ apt upgrade E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied) E: Unable to acquire the dpkg frontend ... More on forum.iobroker.net
🌐 forum.iobroker.net
9
0
March 11, 2023
NUT + RaspberryPi For Free UPS Monitoring: Feedback & Pull Requests Welcome! - Hardware & Infrastructure - Spiceworks Community
Tl;dr: We have a cool little script that can make it easy to configure UPS monitoring on a RaspberryPi in a matter of minutes. Feel free to use it, provide feedback, and make it more gooder via pull requests and bug reports on GitHub. You can check out the script and instructions on this GitHub ... More on community.spiceworks.com
🌐 community.spiceworks.com
10
October 11, 2022
🌐
Raspberry Pi Forums
forums.raspberrypi.com › board index › projects › networking and servers
Install NUT on my Pi? - Raspberry Pi Forums
Have a look at the Raspberry Pi documentation on using SSH https://www.raspberrypi.com/documentati ... s.html#ssh To install run the following on the Raspberry Pi. Code: Select all · sudo apt install -y nut Follow Jeff Geerlings instructions here https://www.jeffgeerling.com/blog/2025/ ... ...
🌐
Reddit
reddit.com › r/homelab › setting up nut on a raspberry pi
r/homelab on Reddit: Setting up NUT on a Raspberry Pi
November 22, 2021 -

EDIT: Got it fixed thanks to some help from their mailing list. The command in upsmon.conf is case sensitive. It should be MONITOR and not monitor. That seems to have fixed the issue.

----------------------------

Any NUT experts out there? I'd really appreciate some help here.

I have two identical APC UPSes, plugged into a Rasberry Pi and I am trying to setup NUT for both of them.

nut-scanner returns:

$ nut-scanner -q
SNMP library not found. SNMP search disabled.
Neon library not found. XML search disabled.
IPMI library not found. IPMI search disabled.
[nutdev1]
        driver = "usbhid-ups"
        port = "auto"
        vendorid = "051D"
        productid = "0002"
        bus = "001"
[nutdev2]
        driver = "usbhid-ups"
        port = "auto"
        vendorid = "051D"
        productid = "0002"
        bus = "001"

As you can see they are absolutely identical, with no way to discern them apart, and I think this is the root of my issue.

When I run:

lsusb -v

I get results that include the serial numbers. So thanks to this post, I was able to create some custom udev rules to create /dev/apc-t and /dev/apc-b and this appears to work.

My ups.conf specifies the devices like this:

[APC-t]
        driver = usbhid-ups
        port = /dev/apc-t
        desc = "APC UPS - Top"
        vendorid = 051D
        productid = 0002
        bus = 001
        serial = "xxxxxxx855"

[APC-b]
        driver = usbhid-ups
        port = /dev/apc-b
        desc = "APC UPS - Bottom"
        vendorid = 051D
        productid = 0002
        bus = 001
        serial = "xxxxxxx867"

However, when I try to restart the nut-client service they error out and I get:

Starting Network UPS Tools - power device monitor and shutdown controller...
fopen /run/nut/upsmon.pid: No such file or directory
/etc/nut/upsmon.conf line 86: invalid directive monitor APC-t@localhost 1 admin <8 random letters> master
/etc/nut/upsmon.conf line 87: invalid directive monitor APC-b@localhost 1 admin <8 random letters> master
Using power down flag file /etc/killpower
Network UPS Tools upsmon 2.7.4
Fatal error: insufficient power configured!
Sum of power values........: 0
Minimum value (MINSUPPLIES): 1
Edit your upsmon.conf and change the values.
nut-monitor.service: Control process exited, code=exited, status=1/FAILURE
nut-monitor.service: Failed with result 'exit-code'.
Failed to start Network UPS Tools - power device monitor and shutdown controller.

Restarting the nut-server service seems to work fine

Connected to UPS [APC-b]: usbhid-ups-APC-b
Connected to UPS [APC-t]: usbhid-ups-APC-t
Connected to UPS [APC-b]: usbhid-ups-APC-b
Connected to UPS [APC-t]: usbhid-ups-APC-t
Startup successful
Started Network UPS Tools - power devices information server.
Data for UPS [APC-t] is stale - check driver
Data for UPS [APC-b] is stale - check driver
UPS [APC-t] data is no longer stale
UPS [APC-b] data is no longer stale

At this point I have no idea what to do to get this work.

Here are all the config files.

nut.conf

MODE=netserver

ups.conf

maxretry = 3

pollinterval = 1

[APC-t]
        driver = usbhid-ups
        port = /dev/apc-t
        desc = "APC UPS - Top"
        vendorid = 051D
        productid = 0002
        bus = 001
        serial = "xxxxxxx855"

[APC-b]
        driver = usbhid-ups
        port = /dev/apc-b
        desc = "APC UPS - Bottom"
        vendorid = 051D
        productid = 0002
        bus = 001
        serial = "xxxxxxx867"

upsd.conf

LISTEN 0.0.0.0 3493

upsd.users

           [admin]
               password = <8 random letters>
               upsmon master

upsmon.conf

RUN_AS_USER root

monitor APC-t@localhost 1 admin <8 random letters> master
monitor APC-b@localhost 1 admin <8 random letters> master
MINSUPPLIES 1
SHUTDOWNCMD "/sbin/shutdown -h +0"
POLLFREQ 5
POLLFREQALERT 5
HOSTSYNC 15
DEADTIME 15
POWERDOWNFLAG /etc/killpower
RBWARNTIME 43200
NOCOMMWARNTIME 300
FINALDELAY 5

ls /dev/a*

/dev/apc-b  /dev/apc-t  /dev/autofs

Oddly, I can get info from the UPSes

upsc APC-t@localhost

Init SSL without certificate database
battery.charge: 100
battery.charge.low: 10
battery.charge.warning: 50
battery.mfr.date: 2020/01/29
battery.runtime: 1320
battery.runtime.low: 120
battery.temperature: 27.4
battery.type: PbAc
battery.voltage: 27.5
battery.voltage.nominal: 24.0
device.mfr: American Power Conversion
device.model: Smart-UPS 1500 RM
device.serial: xxxxxxxx855
device.type: ups
driver.name: usbhid-ups
driver.parameter.bus: 001
driver.parameter.pollfreq: 30
driver.parameter.pollinterval: 1
driver.parameter.port: /dev/apc-t
driver.parameter.productid: 0002
driver.parameter.serial: xxxxxxxx855
driver.parameter.synchronous: no
driver.parameter.vendorid: 051D
driver.version: 2.7.4
driver.version.data: APC HID 0.96
driver.version.internal: 0.41
input.sensitivity: high
input.transfer.high: 127
input.transfer.low: 106
input.voltage: 121.6
output.frequency: 60.0
output.voltage: 121.6
output.voltage.nominal: 120.0
ups.beeper.status: enabled
ups.delay.shutdown: 20
ups.delay.start: 30
ups.firmware: 617.3.D
ups.firmware.aux: 8.1
ups.load: 28.6
ups.mfr: American Power Conversion
ups.mfr.date: 2007/08/29
ups.model: Smart-UPS 1500 RM
ups.productid: 0002
ups.serial: AS0735130855
ups.status: OL
ups.test.result: No test initiated
ups.timer.reboot: -1
ups.timer.shutdown: -1
ups.timer.start: -1
ups.vendorid: 051d

upsc APC-b@localhost

Init SSL without certificate database
battery.charge: 100
battery.charge.low: 10
battery.charge.warning: 50
battery.mfr.date: 2020/01/29
battery.runtime: 1020
battery.runtime.low: 120
battery.temperature: 27.9
battery.type: PbAc
battery.voltage: 27.5
battery.voltage.nominal: 24.0
device.mfr: American Power Conversion
device.model: Smart-UPS 1500 RM
device.serial: xxxxxxxx867
device.type: ups
driver.name: usbhid-ups
driver.parameter.bus: 001
driver.parameter.pollfreq: 30
driver.parameter.pollinterval: 1
driver.parameter.port: /dev/apc-b
driver.parameter.productid: 0002
driver.parameter.serial: xxxxxxxx867
driver.parameter.synchronous: no
driver.parameter.vendorid: 051D
driver.version: 2.7.4
driver.version.data: APC HID 0.96
driver.version.internal: 0.41
input.sensitivity: high
input.transfer.high: 127
input.transfer.low: 106
input.voltage: 122.4
output.frequency: 60.0
output.voltage: 122.4
output.voltage.nominal: 120.0
ups.beeper.status: enabled
ups.delay.shutdown: 20
ups.delay.start: 30
ups.firmware: 617.3.D
ups.firmware.aux: 8.1
ups.load: 48.7
ups.mfr: American Power Conversion
ups.mfr.date: 2007/08/29
ups.model: Smart-UPS 1500 RM
ups.productid: 0002
ups.serial: AS0735130867
ups.status: OL
ups.test.result: No test initiated
ups.timer.reboot: -1
ups.timer.shutdown: -1
ups.timer.start: -1
ups.vendorid: 051d

🌐
openHAB Community
community.openhab.org › tutorials & examples
Beginner's Guide to Network UPS Tools (NUT) on a Raspberry Pi - Tutorials & Examples - openHAB Community
July 22, 2019 - UPDATE (February 15, 2022): Updated with instructions for adding a second UPS Since I don’t want my OH installation to be corrupted by a power failure, I purchased a CyberPower UPS, and connected it to my Raspberry Pi using Network UPS Tools (NUT). There are various topics in the community ...
🌐
Major Hayden
major.io › posts › monitor a ups with a raspberry pi zero w
Monitor a UPS with a Raspberry Pi Zero W | Major Hayden
March 15, 2021 - You may need to disconnect and reconnect it after installing nut to pick up udev changes. Next, it’s time to update some configuration files. Start by opening /etc/nut/nut.conf and setting the server mode to netserver so that nut can listen ...
🌐
MelGrubb.ToBlog()
melgrubb.com › 2016 › 12 › 11 › rphs-v2-ups
Raspberry Pi Home Server v2: Network UPS Tools | MelGrubb.ToBlog()
December 11, 2016 - The utility can be found here. https://www.lestat.st/en/informatique/projets/nut-monitor#download ... This is a great guide, and still relevant and accurate as of Nov 2018. I used these procedures to setup a server that is connected to the UPS’s, and 3 raspberry pi clients and one pfsense client.
Find elsewhere
🌐
The Homelabber
thehomelabber.com › guides › network-ups-monitoring
The Homelabber | Network UPS monitoring with NUT server
I have also pointed my Synology NAS and Unraid server at the NUT server so they can safely shutdown in the event of a power outage. While I configured this on a Raspberry Pi with Docker, you can also install NUT locally or even install the Unraid app for a quick and simple setup.
🌐
RaspiBolt
raspibolt.org › guide › bonus › raspberry-pi › ups-nut.html
Configure UPS NUT | RaspiBolt
NUT is nice in that it allows for a single device to communicate to other devices to safely shut them down (client-server relationship). For this scenario, ensure your UPS data port is plugged into the Raspberry Pi. ... Install NUT.
🌐
Ledhed
wiki.ledhed.net › index.php
Raspberry Pi NUT Server - LedHed's Wiki
October 19, 2023 - Note: You'll likely have more than one line if you have remote clients connecting to this NUT server (which is really the whole point). This file defines the type of role this installation of NUT will be performing.
🌐
Tanmay
tanmay.me › posts › nut-tools
NUT (Network UPS Tools) Installation Tutorial
A guide to installing NUT with Raspberry Pi as Server and Proxmox/Synology NAS as Clients
🌐
Elektrifiziert
elektrifiziert.net › oles techblog & suses shop
Forum - Oles Techblog & Suses Shop
May 9, 2024 - Forum · Mark All as Read · RSS Feed · Allgemein · Fragen, Anregungen, Announcements und Sonstiges zu dieser Seite · Threads · Posts · Last Posts · Webseiten & Server maintenance & Verbesserungen · Olaf Krause
🌐
iobroker
forum.iobroker.net › iobroker community home › deutsch › einsteigerfragen › einbindung von geräten › [gelöst] nut server auf raspi installieren
[gelöst] Nut Server auf Raspi installieren
March 11, 2023 - pi@raspberrypi:~ $ sudo apt install nut usbutils Reading package lists... Done Building dependency tree Reading state information... Done usbutils is already the newest version (1:010-3). The following additional packages will be installed: ...
🌐
GitHub
github.com › 33masterman33 › nut-start-server
GitHub - 33masterman33/nut-start-server: Using NUT installed on a raspberry pi to shutdown a server once ups reaches a certain battery level and then automattically power on the server once power is restored · GitHub
Now we have to tell NUT to act as a server sudo nano /etc/nut/nut.conf We need the MDOE set to netserver ... If using iDRAC or another LOM for power control attach your PIs ssh key to an account that has access to power control.
Author   33masterman33
🌐
Spiceworks Community
community.spiceworks.com › hardware & infrastructure
NUT + RaspberryPi For Free UPS Monitoring: Feedback & Pull Requests Welcome! - Hardware & Infrastructure - Spiceworks Community
October 11, 2022 - Tl;dr: We have a cool little script that can make it easy to configure UPS monitoring on a RaspberryPi in a matter of minutes. Feel free to use it, provide feedback, and make it more gooder via pull requests and bug reports on GitHub. You can check out the script and instructions on this GitHub Repo: GitHub - dzomaya/NUTandRpi: A repo for Network UPS Tools and Eaton Tripp Lite UPS demo scripts Let me know what you think!
🌐
GitHub
github.com › dzomaya › NUTandRpi
GitHub - dzomaya/NUTandRpi: A repo for Network UPS Tools and Eaton Tripp Lite UPS demo scripts · GitHub
Our script won't work for everyone and you learn more doing it manually anyway, so let's walk through how you can manually install and configure NUT. ⚠️ Enterprise-grade security not included We're assuming you're on a home or test network and we're not doing any production-grade security stuff. The HTTP and SNMP v2c protocols both transmit data in plaintext. You can — and I encourage you to — modify the installation script to meet specific security requirements but we're leaving that up to you, brave Internet Stranger. A supported UPS. A Linux computer running Raspberry Pi OS, Ubuntu, or a similar operating system
Starred by 166 users
Forked by 12 users
Languages   Shell
🌐
Techtronic
techtronic.us › home › network ups tools (nut server) ultimate guide
Network UPS Tools (NUT Server) Ultimate Guide | Techtronic
September 25, 2021 - It’ perfect for your Pi, server, or desktop. It works with hundreds of UPS devices, PDUs, and many other power management systems. This is the ultimate guide to configuring Network UPS Tools (NUT). We cover everything from installing and configuring the server on as Raspberry Pi, configuring the client on Windows and Linux, configure a charting and graphing website to visualize NUT data, spin up an additional web site use Docker, and finally set up monitoring and alerting to automate shutdowns of your machine.
🌐
SYSADMIN
sysadmin.info.pl › blog › configure the nut to manage a ups through the home assistant as a docker container on a raspberry pi
Configure the NUT to manage a UPS through the Home Assistant as a Docker container on a Raspberry Pi | SYSADMIN
July 29, 2022 - Additionally I present how to turn off the Mikrotik router from the Raspberry Pi if the battery level state is low. I decided to „promote” this video that is just an excellent example that explains step by step how to install and configure NUT on a Raspberry Pi.
🌐
How to Raspberry
howtoraspberry.com › 2020 › 11 › how-to-monitor-ups-with-raspberry-pi
How to Monitor UPS with Raspberry Pi – How to Raspberry
May 8, 2022 - Now install the monitoring software: apt-get update && apt-get install nut nut-client nut-server · This is the Network UPS Tools package or “NUT” for short. Nice to have real-world tools in the Raspberry repositories for easy installs!
🌐
openHAB Community
community.openhab.org › tutorials & examples
Guide to Network UPS Tools (NUT) on multiple Raspberry PI’s (Openhab 2.5 and other systems) - Tutorials & Examples - openHAB Community
November 29, 2021 - This tutorial will cover the installation of NUT on a Pi running Openhab (OH) 2.5 with other systems powered by the same UPS. First off I would like to thank everyone in the OH community who has written tutorials, comme…