hassio-addons / addon-nut

Network UPS Tools - Home Assistant Community Add-ons
https://addons.community
MIT License
179 stars 35 forks source link

No matching HID UPS found #21

Closed AlexVVVx closed 4 years ago

AlexVVVx commented 4 years ago

Problem/Motivation

No matching HID UPS found USB Driver failed to start

Expected behavior

My UPS worked properly with NUT server on another RP without Home assistant I wpould like to have NUT running as addon on hassio.

Actual behavior

[s6-init] making user provided files available at /var/run/s6/etc...exited 0. [s6-init] ensuring user provided files have correct perms...exited 0. [fix-attrs.d] applying ownership & permissions fixes... [fix-attrs.d] nut: applying... [fix-attrs.d] nut: exited 0. [fix-attrs.d] done. [cont-init.d] executing container initialization scripts... [cont-init.d] 00-banner.sh: executing...

Hass.io Add-on: Network UPS Tools Manage battery backup (UPS) devices

Add-on version: 4213c06 You are running the latest version of this add-on. System: HassOS 3.9 (armv7 / raspberrypi3) Home Assistant version: 0.105.2 Supervisor version: 199

Please, share the above information when looking for help or support in, e.g., GitHub, forums or the Discord chat.

[cont-init.d] 00-banner.sh: exited 0. [cont-init.d] 01-log-level.sh: executing... [cont-init.d] 01-log-level.sh: exited 0. [cont-init.d] nut.sh: executing... [19:28:25] INFO: Setting mode to netserver... [19:28:26] INFO: Connected USB devices: Bus 001 Device 040: ID 0d9f:0004 Powercom Co., Ltd Bus 001 Device 003: ID 0424:ec00 Microchip Technology, Inc. (formerly SMSC) SMSC9512/9514 Fast Ethernet Adapter Bus 001 Device 103: ID 0658:0200 Sigma Designs, Inc. Aeotec Z-Stick Gen5 (ZW090) - UZB Bus 001 Device 002: ID 0424:9514 Microchip Technology, Inc. (formerly SMSC) SMC9514 Hub Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub [19:28:26] INFO: Generating /etc/nut/upsd.users... [19:28:27] INFO: Configuring user: upsmon [19:28:30] INFO: Password is NOT in the Have I Been Pwned database! Nice! [19:28:34] INFO: Configuring Device named myups... [19:28:34] INFO: Starting the UPS drivers... Network UPS Tools - UPS driver controller 3.8.0-3396-gcdc7c4b5b1 Network UPS Tools - Generic HID driver 0.41 (3.8.0-3396-gcdc7c4b5b1) USB communication driver 0.33 No matching HID UPS found Driver failed to start (exit status=1) [cont-init.d] nut.sh: exited 1. [cont-finish.d] executing container finish scripts... [cont-finish.d] 99-message.sh: executing...

            Oops! Something went wrong.

We are so sorry, but something went terribly wrong when starting or running this add-on.

Be sure to check the log above, line by line, for hints.

[cont-finish.d] 99-message.sh: exited 0. [cont-finish.d] done. [s6-finish] waiting for services. [s6-finish] sending all processes the TERM signal.

Steps to reproduce

UPS - Powercom WOW500 Raspberry Pi 3

My config: users:

Sensor:

Proposed changes

I have no idea how to get it working My UPS is listed as USB device in the log

addons-assistant[bot] commented 4 years ago

:wave: Thanks for opening your first issue here! If you're reporting a :bug: bug, please make sure you include steps to reproduce it. Also, logs, error messages and information about your hardware might be useful.

sinclairpaul commented 4 years ago

You can try setting the vendor id as per the documentation examples, maybe it is conflicting with your other USB devices. You may also want to test with only the UPS connected.

Please do note the addon is not yet released.

AlexVVVx commented 4 years ago

Thank you for quick response. I am not sure if this id is correct https://networkupstools.org/stable-hcl.html - Powercom WOW USB (2009 models, product id: 00a4)

Updated my config but it didn't help. I have already tested the only UPS inserted - no any difference.

users:

Network UPS Tools - Hardware compatibility list
Power Devices support
sinclairpaul commented 4 years ago

Bus 001 Device 040: ID 0d9f:0004 Powercom Co., Ltd

I believe the vendorid in your example is likely 0d9f

0004 looks to be the productid

Can you post your config in backticks, to avoid the markdown formating.

it should be something like { "name": "myups", "driver": "usbhid-ups", "port": "auto", "config": [ "vendorid = 0d9f" ] }, It is stated that the support is experimental, and the key difference is likely that the addon runs in Alpine. If you cannot get it to recognise the UPS there is always the option to run in Netclient mode, in which the addon can still receive notifications from a remote NUT install.

AlexVVVx commented 4 years ago

Thank you for your time. I updated the vendorid but still no luck... Looks like I have to switch back to my previous configuration with separate NUT server. In this case I don't need this addon at all - just sensor. I'll try this addon some later when it is released. Thank you anyway!

Here is my config: { "users": [ { "username": "upsmon", "password": "****", "instcmds": [ "all" ], "actions": [] } ], "devices": [ { "name": "myups", "driver": "usbhid-ups", "port": "auto", "config": ["vendorid = 0d9f"] } ], "mode": "netserver", "shutdown_hassio": "false" "list_usb_devices": "true" }

sinclairpaul commented 4 years ago

We made some changes around USB ports within the addon, please feel free to retest, but will close this out for now.

addons-assistant[bot] commented 4 years ago

This thread has been automatically locked because it has not had recent activity. Please open a new issue for related bugs and link to relevant comments in this thread.