software:truenas:ups
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| software:truenas:ups [2023/11/23 00:28] – created rodolico | software:truenas:ups [2023/11/23 00:57] (current) – rodolico | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== Setting up a UPS with TrueNAS ====== | ====== Setting up a UPS with TrueNAS ====== | ||
| - | Find UPS plugged into a USB port | + | TrueNAS supports monitoring |
| + | ===== Find UPS plugged into a USB port ===== | ||
| - | usbconfig | + | The command <code bash>usbconfig</ |
| + | < | ||
| ugen0.4: < | ugen0.4: < | ||
| + | </ | ||
| - | 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 | + | 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* | + | <code bash>ls -ablph /dev/ugen* ; ls -ablph /dev/uhid*</ |
| + | This shows all entries named ugen* or uhid*, with the link that it actually points to. | ||
| + | |||
| + | < | ||
| lrwxr-xr-x | lrwxr-xr-x | ||
| + | </ | ||
| - | Services, then Actions for UPS | + | So, the device |
| - | | + | |
| - | UPS Mode: Master | + | |
| - | | + | |
| - | Port: auto | + | |
| - | | + | |
| - | | + | |
| - | + | ||
| - | Start and see if it works. Then, you can view the UPS with | + | |
| - | upsc ups | + | ===== Setting up the UPS ===== |
| + | |||
| + | Open the TrueNAS WebUI and go to Services, then Actions for UPS | ||
| + | - Identifier: ups (or anything you want) | ||
| + | - UPS Mode: Master | ||
| + | - Driver: find something close. For my PR1500, I used PR6000 | ||
| + | - Port: auto (or choose ugen0.4 that you found above) | ||
| + | - Shutdown: UPS goes on battery | ||
| + | - Shutdown Timer: 600 (seconds, or 10 minutes) | ||
| + | - Save | ||
| + | |||
| + | ===== Testing ===== | ||
| + | Start the UPS service. You can now drop to the shell and run the command: | ||
| + | |||
| + | <code bash>upsc ups</ | ||
| where ' | where ' | ||
| Line 30: | Line 42: | ||
| If it all appears to be working, put a check for Automatically start. NOTE: you can view some stats on the UPS under Reporting. | If it all appears to be working, put a check for Automatically start. NOTE: you can view some stats on the UPS under Reporting. | ||
| + | ===== ipmi shows a difference ===== | ||
| + | |||
| + | If you use ipmitool to display the amount of power the server is using | ||
| + | |||
| + | <code bash> | ||
| + | |||
| + | You might see a different number than the power your UPS is showing with <code bash> | ||
| + | |||
| + | First, ipmitool is probably showing //Watts// while the UPS may be showing // | ||
| + | |||
| + | Second, your UPS uses additional power to keep the batteries topped off, and also just for some internal circuitry, so it should show a different power (higher) than what your server actually uses. | ||
| + | |||
| + | On my setup, with a Cyberpower UPS powering an older Dell server, I used the command: | ||
| - | Track CPU Temperature (by core) | + | <code bash> |
| - | sysctl -a | grep temperature | + | ipmitool sensor |
| + | upsc ups | egrep ' | ||
| + | </ | ||
| - | Power | ||
| - | ipmitool sensor | grep 'Power Meter' | cut -d' | ||
software/truenas/ups.1700720898.txt.gz · Last modified: 2023/11/23 00:28 by rodolico
