UPS communication via USB

Status
Not open for further replies.

DrBob

Dabbler
Joined
Jan 6, 2015
Messages
46
Could anyone tell me if some additional actions are required to start upsmon working on FreeNAS-9.10.2-U6? The problem is - I tried to start the service via the web interface and it did not work.

Step 1: I connected Ippon Comfo Pro via USB.
Step 2: I got a message GATE ugen7.2: <INNO TECH> at usbus7 i.e. the cable is working and the USB port on the NAS is functioning, right?
Step 3: I set up UPS in Control services via web interface according to the following settings:
UPS mode: master
Identifier: ups
Driver: Ippon ups 2 Back Comfo Pro 600/800 (blazer_usb)
Port: /dev/ugen7.2
ups.conf: empty
upsd.conf: empty
descr: empty
Shutdown mode: low battery
shutdown command: /sbin/shutdown -p now
user: upsmon
pass: *****
Extra users: empty
Remote monitor: yes
Send email status updates: yes
Power off UPS: yes

I push Ok

Step 4 : I start UPS service
I get
Code:
Starting nut_upslog in terminal window. And then I start getting the following log:
Jan 30 18:00:55 GATE blazer_usb[1904]: Permissions problem: Input/output error
Jan 30 18:00:55 GATE upsd[1906]: Can't connect to UPS [ups] (blazer_usb-ups): No such file or directory
Jan 30 18:00:58 GATE upsmon[1914]: Poll UPS [ups] failed - Driver not connected
Jan 30 18:00:58 GATE upsmon[1914]: Communications with UPS ups lost
Jan 30 18:01:03 GATE upsmon[1914]: Poll UPS [ups] failed - Driver not connected


Which as far as I understand means some permission problem, which needs to be fixed. Where and how? Thanks.
 
Last edited by a moderator:

Redcoat

MVP
Joined
Feb 18, 2014
Messages
2,925
Last edited by a moderator:

Nick2253

Wizard
Joined
Apr 21, 2014
Messages
1,633

Redcoat

MVP
Joined
Feb 18, 2014
Messages
2,925
Have you tried a reboot of FreeNAS since connecting the UPS? Apparently this has been effective in soime situations in the past.
 

DrBob

Dabbler
Joined
Jan 6, 2015
Messages
46
Doing some quick research, it looks like a legitimate permissions issue: https://forums.freebsd.org/threads/35205/

Can you try your UPS on a different USB port?

Yes, just tried all the free ports with approximately the same results,

Code:
Jan 30 20:09:32 GATE ugen5.2: <INNO TECH> at usbus5
Jan 30 20:10:06 GATE notifier: nut not running? (check /var/db/nut/upsd.pid).
Jan 30 20:10:06 GATE notifier: nut_upsmon not running? (check /var/db/nut/upsmon.pid).
Jan 30 20:10:06 GATE notifier: nut_upslog not running? (check /var/db/nut/upslog.pid).
Jan 30 20:10:06 GATE notifier: Cannot 'restart' nut. Set nut_enable to YES in /etc/rc.conf or use 'onerestart' instead of 'restart'.
Jan 30 20:10:06 GATE notifier: Cannot 'restart' nut_upsmon. Set nut_upsmon_enable to YES in /etc/rc.conf or use 'onerestart' instead of 'restart'.
Jan 30 20:10:06 GATE notifier: Cannot 'restart' nut_upslog. Set nut_upslog_enable to YES in /etc/rc.conf or use 'onerestart' instead of 'restart'.
Jan 30 20:10:12 GATE notifier: Supported UPS detected with megatec protocol
Jan 30 20:10:12 GATE notifier: Vendor information unavailable
Jan 30 20:10:12 GATE notifier: No values provided for battery high/low voltages in ups.conf
Jan 30 20:10:12 GATE notifier:
Jan 30 20:10:12 GATE notifier: Using 'guestimation' (low: 10.400000, high: 13.000000)!
Jan 30 20:10:12 GATE notifier: Battery runtime will not be calculated (runtimecal not set)
Jan 30 20:10:12 GATE notifier: Network UPS Tools - UPS driver controller 2.7.3
Jan 30 20:10:12 GATE notifier: Starting nut.
Jan 30 20:10:12 GATE notifier: fopen /var/db/nut/upsd.pid: No such file or directory
Jan 30 20:10:12 GATE notifier: listening on 0.0.0.0 port 3493
Jan 30 20:10:12 GATE notifier: Connected to UPS [ups]: blazer_usb-ups
Jan 30 20:10:12 GATE notifier: /usr/local/etc/nut/cmdvartab not found - disabling descriptions
Jan 30 20:10:12 GATE notifier: Starting nut_upsmon.
Jan 30 20:10:12 GATE notifier: kill: No such process
Jan 30 20:10:12 GATE notifier: UPS: ups (master) (power value 1)
Jan 30 20:10:12 GATE notifier: Using power down flag file /etc/killpower
Jan 30 20:10:12 GATE notifier: Starting nut_upslog.


After this, I guess, I'll be getting Poll UPS [ups] failed - Driver not connected as it happened before

Update:

Code:
Jan 30 20:24:23 GATE blazer_usb[6033]: Permissions problem: Input/output error
Jan 30 20:24:23 GATE upsd[6035]: Can't connect to UPS [ups] (blazer_usb-ups): No such file or directory
Jan 30 20:24:26 GATE upsmon[6050]: Poll UPS [ups] failed - Driver not connected
Jan 30 20:24:26 GATE upsmon[6050]: Communications with UPS ups lost
Jan 30 20:24:31 GATE upsmon[6050]: Poll UPS [ups] failed - Driver not connected
Jan 30 20:24:36 GATE upsmon[6050]: Poll UPS [ups] failed - Driver not connected
Jan 30 20:24:41 GATE upsmon[6050]: Poll UPS [ups] failed - Driver not connected

 

DrBob

Dabbler
Joined
Jan 6, 2015
Messages
46
Have you tried a reboot of FreeNAS since connecting the UPS? Apparently this has been effective in soime situations in the past.

Certainly, I've tried rebooting several times, connecting the UPS to different ports
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,421
Disable the remote monitoring box if you don't actually need another nut service other than freenas to monitor the UPS. I don't think that will make a difference with your problem but don't turn extra things on that you don't use.

I would also file a bug for this on bugs.freenas.org and maybe try a different driver?
 

Redcoat

MVP
Joined
Feb 18, 2014
Messages
2,925
pass: *****

Did you change the (default) password "fixmepass"? The manual states that the default cannot be changed (but I don't know if doing so will cause the issues you are experiencing).
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,421
Did you change the (default) password "fixmepass"? The manual states that the default cannot be changed (but I don't know if doing so will cause the issues you are experiencing).
Has nothing to do with the problem. This is only for report monitoring.
 

DrBob

Dabbler
Joined
Jan 6, 2015
Messages
46
Disable the remote monitoring box if you don't actually need another nut service other than freenas to monitor the UPS. I don't think that will make a difference with your problem but don't turn extra things on that you don't use.

I would also file a bug for this on bugs.freenas.org and maybe try a different driver?

Yes, sure, parameters, the meaning of which is not obvious, should be handled with care :smile:

I didn't have much spare time in the last days, but just now tried to change the driver to usbhid_ups, generic_ups, nutdrv_qx - the ones that had USB in the UPS model list - all the same - COMMBAD sooner or later and different restart stuff in the sever log window, which I dont have enough qualification to enterpret.

Yes, I guess, I'll male a bug post as well.
 

Redcoat

MVP
Joined
Feb 18, 2014
Messages
2,925
Did you try a different UPS EDIT "USB"! cable?

There's always the possibility that the UPS is in some way "bad". Did it come with any windows software that you could use to test it, for instance?
 
Last edited:

DrBob

Dabbler
Joined
Jan 6, 2015
Messages
46
Did you try a different UPS cable?

There's always the possibility that the UPS is in some way "bad". Did it come with any windows software that you could use to test it, for instance?

Not yet, I just started experimenting. This could also be a possible reason, maybe I'll try experimenting, though it looks to me a little bit challenging since AFAIK this UPS requires 3d-party software to be operated under Windows. But maybe I'll try it with a notebook on this weekend, if my boss won't supply me with a pumping station drawing to be automated by monday :smile:
 

Redcoat

MVP
Joined
Feb 18, 2014
Messages
2,925
Good luck with this. BTW I edited my post to read "USB cable" (not "UPS").
 

DrBob

Dabbler
Joined
Jan 6, 2015
Messages
46
Well, my adventure ended in a most unexpected way. The Ippon Back Comfo Pro 800 UPS started showing "Service required" sign after another blackout that the energy service provider has offered me and I had to purchase another UPS this Saturday. Though not withought suprises from FreeNAS.
Before making a decision, what to buy, I looked through the list of devices in the drop-box on the UPS setup page and decided to buy Powerman Back Pro Plus, which was on the list with genericups driver (I wanted to try something different from blazer_usb this time). I broght it home and connected it to the server using genericups upstype=4. And SURPRISE: NOTHING WORKED ;-) I got connection error, similar to those I got with the previous UPS. Which is more interesting, connection didin't work in the variant of Various UPS UPSilon 2000 software blazer_usb, which is the software for communicating with this UPS under Windows and worked quite well, when I connected it to a notebook by the same cable

Though I at last managed to connect the device as Various UPS/Megatec protocol blazer_usb and it really shutdowns the server if you set shutdon mode to "UPS goes on battery" and set shutdown timer in seconds. I did not manage to make the UPS shut down as well. I didn't manage to make the sever get battery states from the UPS and shutdown the server based on the state of the battery. I did not manage to turn of the UPS automatically.
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,421
Well, my adventure ended in a most unexpected way. The Ippon Back Comfo Pro 800 UPS started showing "Service required" sign after another blackout that the energy service provider has offered me and I had to purchase another UPS this Saturday. Though not withought suprises from FreeNAS.
Before making a decision, what to buy, I looked through the list of devices in the drop-box on the UPS setup page and decided to buy Powerman Back Pro Plus, which was on the list with genericups driver (I wanted to try something different from blazer_usb this time). I broght it home and connected it to the server using genericups upstype=4. And SURPRISE: NOTHING WORKED ;-) I got connection error, similar to those I got with the previous UPS. Which is more interesting, connection didin't work in the variant of Various UPS UPSilon 2000 software blazer_usb, which is the software for communicating with this UPS under Windows and worked quite well, when I connected it to a notebook by the same cable

Though I at last managed to connect the device as Various UPS/Megatec protocol blazer_usb and it really shutdowns the server if you set shutdon mode to "UPS goes on battery" and set shutdown timer in seconds. I did not manage to make the UPS shut down as well. I didn't manage to make the sever get battery states from the UPS and shutdown the server based on the state of the battery. I did not manage to turn of the UPS automatically.
You could always go with a ups people have proven work. Cyber power and apc smart ups are probably the best bet. Random ups that people don't use are not great unless you want to blaze your own trail.
 

DrBob

Dabbler
Joined
Jan 6, 2015
Messages
46
You could always go with a ups people have proven work. Cyber power and apc smart ups are probably the best bet. Random ups that people don't use are not great unless you want to blaze your own trail.

The problem such systems is always one - price ;-) The UPSs that support intellectual functions always cost a lot.

What is more interesting - why the free software for the UPS works fine showing voltages and shutdowning everything in a plug-n-play mode under MS OSes, while Unix drivers require experimenting - that's much more a problem to me. Since due to my job I have to deal with NASes in CCTV systems this makes me mad. Not in this discussed case, but in general.
 

tvsjr

Guru
Joined
Aug 29, 2015
Messages
959
It's very simple... because the vendor spends money developing their software to work with Windows, and probably doesn't care much about the various flavors of *nix. They might care about Linux, but FreeBSD is pretty esoteric for most "normal" people.

If it makes you mad, may I suggest learning how to write drivers and making a driver for it, which you would then contribute back to the community?
 

DrBob

Dabbler
Joined
Jan 6, 2015
Messages
46
If it makes you mad, may I suggest learning how to write drivers and making a driver for it, which you would then contribute back to the community?
Hm. The most funny thing is that for the previous UPS and for the new one there ARE listed drivers and configs in the system inteface, but they do not work right out of the box at all or require some shaman dancing with a tambourine and nevertheless they don't work correctly to the full measure. So no driver writing is needed. What is needed is either normal documentation for each driver available somewhere on F1 button, not in a 1000 page manual in a шnternet file , or a up to date compatible device list with working options and configs.

All this is is absolutely not a surprise and is typical for any *nix-based system, regardless server, or end-user, I just got one more confirmation.
 

Nick2253

Wizard
Joined
Apr 21, 2014
Messages
1,633
I think the issue here is that you're treating the dropdown as a list of confirmed working devices. This is just a dropdown based on the list of NUT devices. NUT has a very clear list of supported devices, and the current state of support: http://networkupstools.org/stable-hcl.html. Just because it's listed by NUT does not mean that it's working at all (much less 100%). The only PowerMan UPS with successful community reports is the RealSmart 1000: http://networkupstools.org/ddl/PowerMan/

If you refer to the FreeNAS documentation on the UPS, it specifically points to the NUT driver support list (https://doc.freenas.org/9.3/freenas_services.html#ups).

All this is is absolutely not a surprise and is typical for any *nix-based system, regardless server, or end-user, I just got one more confirmation.
I'm sorry that this is your takeaway.
 
Status
Not open for further replies.
Top