This is an old revision of the document!
Setting up a UPS with TrueNAS
Find UPS plugged into a USB port
usbconfig
ugen0.4: <CyberPower Systems PR1500LCDRTXL2U> at usbus0, cfg=0 md=HOST spd=LOW (1.5Mbps) pwr=ON (50mA)
You found it. In my case, it is on bus 0, port 4, so look for the direct link to that. It will either be called ugen* or uhid* in /dev
ls -ablph /dev/ugen* ; ls -ablph /dev/uhid*
lrwxr-xr-x 1 root wheel 9B Nov 18 17:55 /dev/ugen0.4 → usb/0.4.0
Services, then Actions for UPS
Identifier: anything you want UPS Mode: Master Driver: find something close. Fro my PR1500, I used s PR6000 Port: auto Shutdow: UPS goes on battery Shutdown Timer: 600 (seconds, or 10 minutes)
Start and see if it works. Then, you can view the UPS with
upsc ups
where 'ups' is the name you chose as Identifier.
If it all appears to be working, put a check for Automatically start. NOTE: you can view some stats on the UPS under Reporting.
Track CPU Temperature (by core) sysctl -a | grep temperature | grep cpu
Power
ipmitool sensor | grep 'Power Meter' | cut -d'|' -f2 ; upsc ups | egrep 'ups.load|ups.realpower.nominal'