How to install and configure TrueNAS as a NUT server

aldgate

Cadet
Joined
Jan 12, 2023
Messages
3
First time posting; been using TrueNAS for about a year now and these forums have been a huge help! Thank you.

Question: Is there a guide for installing NUT server (master) on TrueNAS (ideally in a jail)?

Background: I'm trying to setup a UPS battery directly to my TrueNAS, and monitor it to auto-shutdown my TrueNAS. I know I need to setup the NUT client to monitor the NUT server which monitors the USB for the UPS. I want the NUT server to be on the TrueNAS. Per this guide, this is achievable, but it starts after the installation of the tools (or assumes they are already installed). More specifically, it starts by telling the reader to run the command nut-scanner -U but it is not installed (when I run that I get the response zsh: command not found: nut-scanner ). Searching led me to this package which I assume is the right one. But I don't know if installing it in a jail is best (or if that is even possible) or if I need to install it as root (or not), etc. So in summary, I'm wondering if there is a guide that exists (or if someone is willing to craft the guidance here in response) for installing NUT as a server on TrueNAS. Thank you!!
 

artlessknave

Wizard
Joined
Oct 29, 2016
Messages
1,506
why are you not using the built in UPS service?
 
Last edited:

Redcoat

MVP
Joined
Feb 18, 2014
Messages
2,925
why are you not using the built in USP service?
He will be if he follows "this guide"... without installing anything.

@aldgate , just follow the instructions in the TrueNAS docs
 
Last edited:

aldgate

Cadet
Joined
Jan 12, 2023
Messages
3
Are you talking about this TrueNAS doc? If so, I did follow this, but I think the built-in UPS service is just the NUT client, not the NUT server correct?

I can't find anything that indicates that the built-in UPS service hosts the NUT server. Am I wrong? The other forum posts on the subject all host the NUT server/master on another device (raspberry pi, PC, etc). Is there another doc I'm missing? I've been looking and searching Google a ton but nothing is coming up.
 

Redcoat

MVP
Joined
Feb 18, 2014
Messages
2,925
Yes, it hosts the NUT server, nothing is required to be loaded (at the very least I can say it defintely used to - I have not used the built in since 11- something myself). If you read the guide you referenced, nothing is loaded.

Look in the tabulation at https://networkupstools.org/stable-hcl.html, find your ups or one similar by the same manufacturer, use the identified driver name in the input when configuring the ups service.

EDIT: To find the usb port, be on the console menu, and then plug in the USB to the UPS and then unplug it, etc. Immediately, you should see devd throw a notice up on the console that a device has been plugged in, together with this port identifier (e.g., ugen0.4 or whatever). If no notice is thrown up, then, I would say, you have a bum USB cable (Quoted from Dr. KK).
 
Last edited:

artlessknave

Wizard
Joined
Oct 29, 2016
Messages
1,506
UPS service is just the NUT client
the NUT client and server is the same thing. it depends on whether you tell it to act as a client or a server (master).

there is both no way to install NUT and no need to install something that is already present.
 

aldgate

Cadet
Joined
Jan 12, 2023
Messages
3
Thank you for confirming! I guess I had it all set up correctly, and just tested it and it shut down properly when I unplugged the UPS. Funny that I wasted hours searching documentation and reading blogs when I already had it all setup correctly and just needed to test.
 

Redcoat

MVP
Joined
Feb 18, 2014
Messages
2,925
Funny that I wasted hours searching documentation and reading blogs when I already had it all setup correctly and just needed to test.
That'll teach you - come here first in future!:smile:

Could you not see that it was operational from the console window at the bottom of the GUI - for example:

1673924525141.png
 
Top