I’ve successfully monitored a Salicru SPS SOHO+ UPS with NUT following these steps.
In this example I have two Fedora servers, a master where the UPS is connected by USB and a client which is also powered by this UPS but monitors its status by network. With the default configuration the clients will be powered down in an outage when the battery reaches critical levels.
In the server, install the nut and nut-monitor packages
# dnf install -y nut nut-client
First configure the driver used by the UPS in
/etc/ups/ups.conf with this section:
[salicru] driver = blazer_usb port = auto desc = "Salicru"
/etc/ups/upsd.conf file we tell the server to listen on any IP address:
LISTEN 0.0.0.0 3493
Open the port in the firewall
# firewall-cmd --add-port=3493/tcp --permanent # firewall-cmd --reload
Create the users to connect to the server in
[upsmaster] password = password-master allowfrom = localhost upsmon master [upsslave] password = password-slave upsmon slave
/etc/ups/upsmon.conf to monitor the UPS:
MONITOR salicru@localhost 1 upsmaster password-master master
Set the mode of operation to netserver in
Enable and run the services
# systemctl enable nut-server nut-monitor # systemctl start nut-server nut-monitor
The client needs the nut-client package installed and configured in
MONITOR salicru@server 1 upsslave password-slave slave
Set the mode of operation to netclient in
Enable and run the monitor service:
# systemctl enable nut-monitor # systemctl start nut-monitor