Comments (11)
I have pushed a fix which should be available on the Edge repo to run as root. I have tested with a USB device which appears to be fine. It would be great if anyone with the issue could validate and test?
from addon-nut.
Has there been any progress on this issue? I am running on a NUC and get this permission issue.
[17:55:54] INFO: Starting the UPS drivers...
Network UPS Tools - UPS driver controller 3.8.0-3220-g866b921892
Network UPS Tools - Megatec/Q1 protocol serial driver 1.57 (3.8.0-3220-g866b921892)
Fatal error: unusable configuration
Driver failed to start (exit status=1)
Unable to open /dev/ttyS0: Permission denied
Current user id: nut (100)
Serial port owner: root (0)
Serial port group: audio (18)
Mode of port: 0660
Things to try:
- Use another port (with the right permissions)
- Fix the port owner/group or permissions on this port
- Run this driver as another user (upsdrvctl -u or 'user=...' in ups.conf).
See upsdrvctl(8) and ups.conf(5).
[cont-init.d] nut.sh: exited 1.
from addon-nut.
Has there been any progress on this issue? I am running on a NUC and get this permission issue.
[17:55:54] INFO: Starting the UPS drivers...
Network UPS Tools - UPS driver controller 3.8.0-3220-g866b921892
Network UPS Tools - Megatec/Q1 protocol serial driver 1.57 (3.8.0-3220-g866b921892)
Fatal error: unusable configuration
Driver failed to start (exit status=1)
Unable to open /dev/ttyS0: Permission denied
Current user id: nut (100)
Serial port owner: root (0)
Serial port group: audio (18)
Mode of port: 0660
Things to try:
- Use another port (with the right permissions)
- Fix the port owner/group or permissions on this port
- Run this driver as another user (upsdrvctl -u or 'user=...' in ups.conf).
See upsdrvctl(8) and ups.conf(5).
[cont-init.d] nut.sh: exited 1.
Nope, nothing new here :(
from addon-nut.
Has there been any progress on this issue? I am running on a NUC and get this permission issue.
[17:55:54] INFO: Starting the UPS drivers...
Network UPS Tools - UPS driver controller 3.8.0-3220-g866b921892
Network UPS Tools - Megatec/Q1 protocol serial driver 1.57 (3.8.0-3220-g866b921892)
Fatal error: unusable configuration
Driver failed to start (exit status=1)
Unable to open /dev/ttyS0: Permission denied
Current user id: nut (100)
Serial port owner: root (0)
Serial port group: audio (18)
Mode of port: 0660
Things to try:
- Use another port (with the right permissions)
- Fix the port owner/group or permissions on this port
- Run this driver as another user (upsdrvctl -u or 'user=...' in ups.conf).
See upsdrvctl(8) and ups.conf(5).
[cont-init.d] nut.sh: exited 1.
sudo chmod 666 /dev/ttyS0
from addon-nut.
Im happy tip test this suggested chmod change but where do i do it? Inside the nut container? How? Sorry im not a noob but docker is new for me.
sudo chmod 666 /dev/ttyS0
from addon-nut.
To link to related issues:
#32 (same issue, but was closed as a supervisor issue)
#33 (pull to manually fix permission, closed as a supervisor issue)
home-assistant/supervisor#1614 (supervisor issue, closed saying nothing can be done on the supervisor end to fix using non-root with existing files)
The potential fixes are to add permissions fixes as I did in #33 (works but is improper) or to run NUT as root. But @sinclairpaul said on Discord that getting it to run as root doesn't work. I will try this soon too.
from addon-nut.
@ben-digitalhive applying the permissions fix from #33 on your machine locally would probably be best accomplished by downloading the addon from my fork with the fix and installing it as a local addon. That way the fix will be sustained across restarts/rebuilds/reinstalls.
However, I would honestly recommend that waiting for a proper fix would be best.
from addon-nut.
@ben-digitalhive applying the permissions fix from #33 on your machine locally would probably be best accomplished by downloading the addon from my fork with the fix and installing it as a local addon. That way the fix will be sustained across restarts/rebuilds/reinstalls.
However, I would honestly recommend that waiting for a proper fix would be best.
I think i will wait. While it would be nice to have visbility of the UPS state its not critical.
from addon-nut.
Mine shows latest commit, and I gave it a try and it seems to work!
13:19:32] INFO: Starting the UPS drivers...
Network UPS Tools - UPS driver controller 3.8.0-3220-g866b921892
Network UPS Tools - Generic contact-closure UPS driver 1.36 (3.8.0-3220-g866b921892)
UPS type: CyberPower Power99
[cont-init.d] nut.sh: exited 0.
[cont-init.d] nutclient.sh: executing...
[cont-init.d] nutclient.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[13:19:34] INFO: Starting the UPS information server...
Network UPS Tools upsd 3.8.0-3220-g866b921892
0.000000 fopen /var/run/nut/upsd.pid: No such file or directory
0.001689 listening on 0.0.0.0 port 3493
0.004721 Connected to UPS [ups1]: genericups-ups1
[13:19:34] INFO: Starting the UPS monitor and shutdown controller...
Network UPS Tools upsmon 3.8.0-3220-g866b921892
0.000000 fopen /var/run/upsmon.pid: No such file or directory
0.000929 Using power down flag file /etc/killpower
0.001637 UPS: ups1@localhost (master) (power value 1)
0.003860 debug level is '1'
0.003906 Warning: running as one big root process by request (upsmon -p)
0.027174 Trying to connect to UPS [ups1@localhost]
0.072858 User [email protected] logged into UPS [ups1]
0.028130 Logged into UPS ups1@localhost
This is with a hardware serial port /dev/ttyS0
. I restarted the host before trying because the modified version of the addon I was using modified permissions on /dev/tty*
, so this should be clean test.
from addon-nut.
I have pushed a fix which should be available on the Edge repo to run as root. I have tested with a USB device which appears to be fine. It would be great if anyone with the issue could validate and test?
This seems to fix the issue! Working flawlessly! :) Thank you.
from addon-nut.
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.
from addon-nut.
Related Issues (20)
- Server not listening on port 3943 HOT 1
- Two identical Cyberpower UPS's HOT 3
- Data stale error HOT 2
- Unstable experience with APC UPs HOT 9
- driver: snmp-ups - 2 devices - no data for second device HOT 2
- Wrong Output Voltage value HOT 4
- Addon Fails to Start: /etc/cont-init.d/nut.sh exited 1 HOT 6
- No password prompt on password change in integration / password logged in plaintext "log_mode: trace"? HOT 1
- UPS load information not available with NUT addon HOT 1
- Could not find PID file '/run/nut/upsd.pid' to see if previous upsd instance is already running! HOT 1
- Addon fails to start when connected to CP1500AVRLCD3 HOT 3
- No temperature entity for APC SMT1500i HOT 2
- No NUT web interface when TCP port is exposed HOT 1
- Add support for apc_modbus HOT 1
- Disable FSD and auto-shutdown of host and/or add-on HOT 7
- Add addon button doesn't work HOT 1
- Timezone issue after upgrade? HOT 1
- Cannot connect from HomeAssistant nor from LAN HOT 7
- apc_modbus over TCP not supported HOT 3
- Addon doesn't exist HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from addon-nut.