pssc / ha-addon-lms

Logitech Media Server Addon for Home Assistant
GNU General Public License v3.0
58 stars 13 forks source link

LMS doesn't start with permissions error #47

Closed fmonday closed 1 year ago

fmonday commented 1 year ago

This is similar to another recent issue but the suggested remedy there didn't work for me. LMS has never started and chown -Rh 1000 /config/lms didn't fix it. Protection mode is turned off. This is in a Debian Bullseye virtual machine in UTM on an M2 Mac Mini. HA 2023.7.1

[23-07-09 08:38:00.5477] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:16:39 AM CET) perl 5.032001 - aarch64-linux-gnu-thread-multi
[23-07-09 08:38:00.5503] Slim::Utils::PluginManager::init (74) Failed to load plugin downloader: Can't locate Slim/Utils/PluginDownloader.pm:   /config/lms/cache/InstalledPlugins/Slim/Utils/PluginDownloader.pm: Permission denied at /usr/share/perl5/Slim/Utils/PluginManager.pm line 69.
[23-07-09 08:38:00.5538] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/PresetsEditor/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
root@m2-ha-vm:~# stat -c '%u' /usr/share/hassio/homeassistant/lms
1000
andreasfromch commented 1 year ago

Same problem here.

pssc commented 1 year ago

Same problem here.

@andreasfromch Same architecture or different?

pssc commented 1 year ago

@fmonday please supply versions and setup of HA and Addons also output of ls /config/lms. @andreasfromch ditto

Has it ever worked?

Have do you have much invested config in lms?

andreasfromch commented 1 year ago

Hi @pssc, thanks for your quick response. What kind of information do you need? Under "Hardware" it shows me "Virtual Machine" "OVA". I let it run on an ESXi server with an image I've found on the internet. It worked quite a long time without any issues. It seems for me that the problem occurs after updating to the newest version of HA.

Home Assistant 2023.7.1 Supervisor 2023.07.1 Operating System 10.3 Frontend 20230705.1 - latest

auto_update: false installed_version: 0.0.53 in_progress: false latest_version: 0.0.53 release_summary: ## [0.0.53] 2023-01-02

Warning

Changes

pssc commented 1 year ago

@andreasfromch @fmonday ls -la /config/lms

@andreasfromch your on x86_64? and @fmonday your on aarch64? so its not arch specific...

andreasfromch commented 1 year ago

@pssc On the ESXi I see "Other 4.x Linux-System or higher (64 Bit)" image

pssc commented 1 year ago

@andreasfromch and ls -la /config/lms/cache /config/lms/cache/InstalledPlugins/Plugins

hmmmm odd permissions

So quick fix you could see if moving /config/lms (stop addon mv /config/lms /config/lms.sav start addon) out the way works and restores service then we know it's something in the config dir...

andreasfromch commented 1 year ago

@pssc First the output of "ls -la /config/lms/cache /config/lms/cache/InstalledPlugins/Plugins" image Then I did "mv /config/lms /config/lms.sav" After restarting the Add-on, Isee the folloeing in the Log: [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] done. [cont-init.d] executing container initialization scripts... [cont-init.d] 00-banner.sh: executing...

Add-on: Logitech Media Server Logitech Media Server, SqueezeBox Server & UPNP Media Server

Add-on version: 0.0.53 You are running the latest version of this add-on. System: Home Assistant OS 10.3 (amd64 / qemux86-64) Home Assistant Core: 2023.7.1 Home Assistant Supervisor: 2023.07.1

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] 02-timezone.sh: executing... Setting the timezone to : Europe/Zurich Current default time zone: 'Europe/Zurich' Local time is now: Tue Jul 11 07:26:42 CEST 2023. Universal Time is now: Tue Jul 11 05:26:42 UTC 2023. Date: Tue Jul 11 07:26:42 CEST 2023 [cont-init.d] 02-timezone.sh: exited 0. [cont-init.d] 05-ha-options-json.sh: executing... [cont-init.d] 05-ha-options-json.sh: exited 0. [cont-init.d] 07-ha-addon_name.sh: executing... [cont-init.d] 07-ha-addon_name.sh: exited 0. [cont-init.d] 09-ha-config-to-env.sh: executing... [07:26:42] INFO: Option MOUNT to MOUNT=null [07:26:43] INFO: Option TMPFS to TMPFS=null [07:26:43] INFO: Option OPTIONS to LMS_OPTIONS=null [07:26:43] INFO: Option LOGFILE to LMS_LOGFILE=null [07:26:43] INFO: Option LOGDIR to LMS_LOGDIR=null [07:26:43] INFO: Option NX to LMS_NX=null [07:26:43] INFO: Option set_permissions to LMS_set_permissions=null [07:26:43] INFO: Option autoupdate_notify to LMS_autoupdate_notify=null [cont-init.d] 09-ha-config-to-env.sh: exited 0. [cont-init.d] 11-ha-dirs.sh: executing... [cont-init.d] 11-ha-dirs.sh: exited 0. [cont-init.d] 15-ha-mounts.sh: executing... [cont-init.d] 15-ha-mounts.sh: exited 0. [cont-init.d] 17-ha-links.sh: executing... [cont-init.d] 17-ha-links.sh: exited 0. [cont-init.d] 17-packages.sh: executing... [cont-init.d] 17-packages.sh: exited 0. [cont-init.d] 21-pulse.sh: executing... [07:26:43] INFO: Fix pulse perms [cont-init.d] 21-pulse.sh: exited 0. [cont-init.d] 90-lms_paths_perms.sh: executing... [cont-init.d] 90-lms_paths_perms.sh: exited 0. [cont-init.d] 95-nxgix.sh: executing... [cont-init.d] 95-nxgix.sh: exited 0. [cont-init.d] 95-scripts.sh: executing... [cont-init.d] 95-scripts.sh: exited 0. [cont-init.d] 99-print-env.sh: executing... [cont-init.d] 99-print-env.sh: exited 0. [cont-init.d] done. [services.d] starting services [services.d] done. [07:26:44] INFO: Waiting for lms before starting NGinx... Start Logitech Media Server... dirsFor: Didn't find a match request: [scprefs] [23-07-11 07:26:45.6148] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:46.4844] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:46.4846] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:47.0933] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:47.2015] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:47.2019] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:48.0867] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:48.1881] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:48.1883] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:49.0972] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:49.2023] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:49.2026] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:50.1042] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:50.2065] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:50.2068] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:51.0808] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:51.1809] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:51.1811] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900

fmonday commented 1 year ago

and @fmonday your on aarch64?

Correct, but HA is running in a UTM virtual machine running Bullseye. Edit: I did this so I could run Supervised rather than core because the former only runs on Debian.

Screenshot 2023-07-11 at 7 09 33 AM
pssc commented 1 year ago

@pssc

First the output of "ls -la /config/lms/cache /config/lms/cache/InstalledPlugins/Plugins" image Then I did "mv /config/lms /config/lms.sav" After restarting the Add-on, Isee the folloeing in the Log: [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] done. [cont-init.d] executing container initialization scripts... [cont-init.d] 00-banner.sh: executing...

Add-on: Logitech Media Server

Logitech Media Server, SqueezeBox Server & UPNP Media Server

Add-on version: 0.0.53

You are running the latest version of this add-on. System: Home Assistant OS 10.3 (amd64 / qemux86-64) Home Assistant Core: 2023.7.1 Home Assistant Supervisor: 2023.07.1

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] 02-timezone.sh: executing... Setting the timezone to : Europe/Zurich Current default time zone: 'Europe/Zurich' Local time is now: Tue Jul 11 07:26:42 CEST 2023. Universal Time is now: Tue Jul 11 05:26:42 UTC 2023. Date: Tue Jul 11 07:26:42 CEST 2023 [cont-init.d] 02-timezone.sh: exited 0. [cont-init.d] 05-ha-options-json.sh: executing... [cont-init.d] 05-ha-options-json.sh: exited 0. [cont-init.d] 07-ha-addon_name.sh: executing... [cont-init.d] 07-ha-addon_name.sh: exited 0. [cont-init.d] 09-ha-config-to-env.sh: executing... [07:26:42] INFO: Option MOUNT to MOUNT=null [07:26:43] INFO: Option TMPFS to TMPFS=null [07:26:43] INFO: Option OPTIONS to LMS_OPTIONS=null [07:26:43] INFO: Option LOGFILE to LMS_LOGFILE=null [07:26:43] INFO: Option LOGDIR to LMS_LOGDIR=null [07:26:43] INFO: Option NX to LMS_NX=null [07:26:43] INFO: Option set_permissions to LMS_set_permissions=null [07:26:43] INFO: Option autoupdate_notify to LMS_autoupdate_notify=null [cont-init.d] 09-ha-config-to-env.sh: exited 0. [cont-init.d] 11-ha-dirs.sh: executing... [cont-init.d] 11-ha-dirs.sh: exited 0. [cont-init.d] 15-ha-mounts.sh: executing... [cont-init.d] 15-ha-mounts.sh: exited 0. [cont-init.d] 17-ha-links.sh: executing... [cont-init.d] 17-ha-links.sh: exited 0. [cont-init.d] 17-packages.sh: executing... [cont-init.d] 17-packages.sh: exited 0. [cont-init.d] 21-pulse.sh: executing... [07:26:43] INFO: Fix pulse perms [cont-init.d] 21-pulse.sh: exited 0. [cont-init.d] 90-lms_paths_perms.sh: executing... [cont-init.d] 90-lms_paths_perms.sh: exited 0. [cont-init.d] 95-nxgix.sh: executing... [cont-init.d] 95-nxgix.sh: exited 0. [cont-init.d] 95-scripts.sh: executing... [cont-init.d] 95-scripts.sh: exited 0. [cont-init.d] 99-print-env.sh: executing... [cont-init.d] 99-print-env.sh: exited 0. [cont-init.d] done. [services.d] starting services [services.d] done. [07:26:44] INFO: Waiting for lms before starting NGinx... Start Logitech Media Server... dirsFor: Didn't find a match request: [scprefs] [23-07-11 07:26:45.6148] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:46.4844] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:46.4846] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:47.0933] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:47.2015] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:47.2019] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:48.0867] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:48.1881] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:48.1883] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:49.0972] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:49.2023] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:49.2026] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:50.1042] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:50.2065] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:50.2068] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900 Start Logitech Media Server... [23-07-11 07:26:51.0808] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:14:25 AM CET) perl 5.032001 - x86_64-linux-gnu-thread-multi [23-07-11 07:26:51.1809] Slim::Networking::UDP::init (40) FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) [23-07-11 07:26:51.1811] Log::Log4perl::Logger::and_die (868) Warning: FATAL: There is already another copy of the Logitech Media Server running on this machine. (Address already in use) at /usr/share/squeezeboxserver/lib/Log/Log4perl/Logger.pm line 900

So Looks like you have a host networking conflict with something else running on your machine, it could be a stale socket so a full reboot to check...

fmonday commented 1 year ago

I'm not seeing that same error in the logs- mine still looks like a permissions problem- which is very confusing because I thought HA runs as root in Supervised. Does the LMS container run with reduced privileges even with "protection mode" turned off?

[23-07-11 07:57:20.8727] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Favorites/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-11 07:57:20.8728] YAML::XS::DumpFile (34) Warning: Can't open '/config/lms/cache/plugin-data.yaml' for output:
Permission denied at /usr/share/squeezeboxserver/CPAN/arch/5.32/aarch64-linux-gnu-thread-multi/YAML/XS.pm line 34.
[23-07-11 07:57:20.8729] Slim::Utils::Prefs::Namespace::savenow (337) Error: can't save /config/lms/prefs/server.prefs: Permission denied at /usr/share/perl5/Slim/Utils/Prefs/Namespace.pm line 326.
[23-07-11 07:57:20.8729] Slim::Utils::Prefs::Namespace::savenow (337) Error: can't save /config/lms/prefs/plugin/state.prefs: Permission denied at /usr/share/perl5/Slim/Utils/Prefs/Namespace.pm line 326.
Start Logitech Media Server...
dirsFor: Didn't find a match request: [scprefs]
fmonday commented 1 year ago
hauser@m2-ha-vm:/usr/share/hassio/homeassistant$ sudo docker exec -it addon_fc57b866_lms  bash
root@fc57b866-lms:/# cd /usr/share/squeezeboxserver/CPAN/arch/5.32/aarch64-linux-gnu-thread-multi/YAML
root@fc57b866-lms:/usr/share/squeezeboxserver/CPAN/arch/5.32/aarch64-linux-gnu-thread-multi/YAML# ls -la
total 20
drwxr-xr-x  3 root root 4096 Dec 30  2022 .
drwxr-xr-x 23 root root 4096 Dec 30  2022 ..
-r--r--r--  1 root root  176 Dec 30  2022 LibYAML.pm
drwxr-xr-x  2 root root 4096 Dec 30  2022 XS
-r--r--r--  1 root root 3258 Dec 30  2022 XS.pm
andreasfromch commented 1 year ago

@pssc After rebooting the VM on the ESXi server everything is running fine again 😎. Thanks, a lot for your great Support 👍!

pssc commented 1 year ago

@andreasfromch from your listing I can see the ownership in the /config/lms/ sub dirs was still trashed. So stopping addon and issuing chown -Rh 1000 /config/lms/ should fix . It cloud be you had a rouge container running still running that was nuking the perms, and had the socket bound. which was fixed by the reboot.

pssc commented 1 year ago

@fmonday can I see the listing from ls -la /config/lms/cache/

Then try stopping the addon and issuing chown -Rh 1000 /config/lms/

Then can I see the listing from ls -la /config/lms/cache/

You can try starting the addon

andreasfromch commented 1 year ago

@pssc Ok, thanks again. I stopped the addon and did "chown -Rh 1000 /config/lms/". Everything seems to be fine 😊!

fmonday commented 1 year ago

To be clear, you want me to do this is the HA container, not the LMS add on container, right? The container isn't accessible when the add-on is stopped anyway

hauser@m2-ha-vm:~$ ls -la /usr/share/hassio/homeassistant/lms/cache/
total 12
drwxr-xr-x 3 hauser homeassistant 4096 Jul  8 18:54 .
drwxr-xr-x 7 hauser homeassistant 4096 Jul  8 18:54 ..
drwxr-xr-x 2 hauser homeassistant 4096 Jul  8 18:54 tmp
hauser@m2-ha-vm:~$ chown -Rh 1000 /usr/share/hassio/homeassistant/lms/
hauser@m2-ha-vm:~$ ls -la /usr/share/hassio/homeassistant/lms/cache/
total 12
drwxr-xr-x 3 hauser homeassistant 4096 Jul  8 18:54 .
drwxr-xr-x 7 hauser homeassistant 4096 Jul  8 18:54 ..
drwxr-xr-x 2 hauser homeassistant 4096 Jul  8 18:54 tmp
pssc commented 1 year ago

To be clear, you want me to do this is the HA container, not the LMS add on container, right? The container isn't accessible when the add-on is stopped anyway

hauser@m2-ha-vm:~$ ls -la /usr/share/hassio/homeassistant/lms/cache/
total 12
drwxr-xr-x 3 hauser homeassistant 4096 Jul  8 18:54 .
drwxr-xr-x 7 hauser homeassistant 4096 Jul  8 18:54 ..
drwxr-xr-x 2 hauser homeassistant 4096 Jul  8 18:54 tmp
hauser@m2-ha-vm:~$ chown -Rh 1000 /usr/share/hassio/homeassistant/lms/
hauser@m2-ha-vm:~$ ls -la /usr/share/hassio/homeassistant/lms/cache/
total 12
drwxr-xr-x 3 hauser homeassistant 4096 Jul  8 18:54 .
drwxr-xr-x 7 hauser homeassistant 4096 Jul  8 18:54 ..
drwxr-xr-x 2 hauser homeassistant 4096 Jul  8 18:54 tmp

Hmm that doesn't look right at all, has this ever worked @fmonday ?

fmonday commented 1 year ago

No, it has never worked. Other add-ons (Terminal, Glances, Grafana, AGH, nginx, ddns etc.) are working fine so I don't think it's an issue with the overall context of running Supervised in UTM. I did also install the Squeezelite player but that was after LMS was already not working; its log has a lot of "sending discovery" in it that I suppose is from LMS not running. I just uninstalled both of them, restarted HA, reinstalled and am getting exactly the same results. I'm over here getting a crash course in docker- tell me if the following is helpful. It looks like the LMS container isn't getting an IP address

hauser@m2-ha-vm:/$ sudo docker network ls
NETWORK ID     NAME      DRIVER    SCOPE
e6f0d13e4825   bridge    bridge    local
7a5f2a4f20c8   hassio    bridge    local
63061f024978   host      host      local
f22cc63cca6c   none      null      local
hauser@m2-ha-vm:/$ sudo docker inspect addon_fc57b866_lms | grep IPAddress
            "SecondaryIPAddresses": null,
            "IPAddress": "",
                    "IPAddress": "
pssc commented 1 year ago

No, it has never worked. Other add-ons (Terminal, Glances, Grafana, AGH, nginx, ddns etc.) are working fine so I don't think it's an issue with the overall context of running Supervised in UTM. I did also install the Squeezelite player but that was after LMS was already not working; its log has a lot of "sending discovery" in it that I suppose is from LMS not running. I just uninstalled both of them, restarted HA, reinstalled and am getting exactly the same results. I'm over here getting a crash course in docker- tell me if the following is helpful. It looks like the LMS container isn't getting an IP address

hauser@m2-ha-vm:/$ sudo docker network ls
NETWORK ID     NAME      DRIVER    SCOPE
e6f0d13e4825   bridge    bridge    local
7a5f2a4f20c8   hassio    bridge    local
63061f024978   host      host      local
f22cc63cca6c   none      null      local
hauser@m2-ha-vm:/$ sudo docker inspect addon_fc57b866_lms | grep IPAddress
            "SecondaryIPAddresses": null,
            "IPAddress": "",
                    "IPAddress": "

That cache dir should have loads in whats in ls -la /config/lms/prefs/ I would nuke /config/lms uninstall the addon and reinstall...

fmonday commented 1 year ago

@pssc I really appreciate your help. Unfortunately I did what you said, reinstalled and I'm getting the exact same errors.

pssc commented 1 year ago

@fmonday its consistent and still broken it tells me things lets have a good look at the log from the container start up.

fmonday commented 1 year ago

I tried removing LMS, deleting /config/lms, rebooting everything including the host, and reinstalling. Still no love...

[23-07-12 18:32:32.1156] main::init (377) Starting Logitech Media Server (v8.3.0, 1667251155, Fri 04 Nov 2022 09:16:39 AM CET) perl 5.032001 - aarch64-linux-gnu-thread-multi
[23-07-12 18:32:32.1182] Slim::Utils::PluginManager::init (74) Failed to load plugin downloader: Can't locate Slim/Utils/PluginDownloader.pm:   /config/lms/cache/InstalledPlugins/Slim/Utils/PluginDownloader.pm: Permission denied at /usr/share/perl5/Slim/Utils/PluginManager.pm line 69.
[23-07-12 18:32:32.1218] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/PresetsEditor/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1219] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Podcast/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1220] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Sounds/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1221] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/DateTime/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1222] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/MyApps/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1223] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/SongScanner/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1223] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/FullTextSearch/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1224] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/AppGallery/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1225] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Snow/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1226] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/DigitalInput/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1226] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/SlimTris/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1227] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Deezer/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1228] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/WiMP/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1228] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/InfoBrowser/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1229] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Pandora/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1230] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/AudioScrobbler/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1231] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/DnDPlay/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1231] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Extensions/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1232] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/ACLFiletest/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1233] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/RemoteLibrary/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1233] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/LibraryDemo/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1234] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/OnlineLibrary/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1235] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Classical/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1236] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/DontStopTheMusic/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1236] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Visualizer/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1237] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/InternetRadio/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1238] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/RSSNews/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1239] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/CLI/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1240] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/iTunes/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1241] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/MusicMagic/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1241] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/RandomPlay/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1242] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/NetTest/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1243] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/JiveExtras/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1244] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/OPMLGeneric/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1245] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/SavePlaylist/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1246] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/xPL/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1247] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/LineOut/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1248] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Slacker/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1249] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/UPnP/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1250] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/ExtendedBrowseModes/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1251] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/LMA/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1251] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/RS232/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1252] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/LineIn/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1253] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Rescan/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1254] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/RhapsodyDirect/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1254] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/SN/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1255] Slim::Utils::PluginManager::_parseInstallManifest (675) Warning: Unable to parse XML in file [/usr/share/perl5/Slim/Plugin/Favorites/install.xml]: [Can't use string ("1") as an ARRAY ref while "strict refs" in use at /usr/share/squeezeboxserver/CPAN/XML/Simple.pm line 231.
]
[23-07-12 18:32:32.1255] YAML::XS::DumpFile (34) Warning: Can't open '/config/lms/cache/plugin-data.yaml' for output:
Permission denied at /usr/share/squeezeboxserver/CPAN/arch/5.32/aarch64-linux-gnu-thread-multi/YAML/XS.pm line 34.
[23-07-12 18:32:32.1256] Slim::Utils::Prefs::Namespace::savenow (337) Error: can't save /config/lms/prefs/plugin/state.prefs: Permission denied at /usr/share/perl5/Slim/Utils/Prefs/Namespace.pm line 326.
[23-07-12 18:32:32.1257] Slim::Utils::Prefs::Namespace::savenow (337) Error: can't save /config/lms/prefs/server.prefs: Permission denied at /usr/share/perl5/Slim/Utils/Prefs/Namespace.pm line 326.
pssc commented 1 year ago

let look at ls -la /config/lms/ /config/lms/cache /config/lms/cache/plugin-data.yaml

Whats your yaml config for the addon

pssc commented 1 year ago

Get yourself into the lms container run id -u squeezeboxserver and ls -la /config/lms/ /config/lms/cache /config/lms/cache/plugin-data.yaml

fmonday commented 1 year ago

Ok so in the container- which isn't where I was working before:

root@fc57b866-lms:/# id -u squeezeboxserver
1000
root@fc57b866-lms:/# ls -la /config/lms/ /config/lms/cache /config/lms/cache/plugin-data.yaml
ls: cannot access '/config/lms/cache/plugin-data.yaml': No such file or directory
/config/lms/:
total 28
drwxr-xr-x  7 squeezeboxserver root 4096 Jul 12 18:32 .
drwxrwx--- 26 root             1001 4096 Jul 13 08:38 ..
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 addon
drwxr-xr-x  3 squeezeboxserver root 4096 Jul 12 18:32 cache
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 logs
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 plugins
drwxr-xr-x  3 squeezeboxserver root 4096 Jul 12 18:32 prefs

/config/lms/cache:
total 12
drwxr-xr-x 3 squeezeboxserver root 4096 Jul 12 18:32 .
drwxr-xr-x 7 squeezeboxserver root 4096 Jul 12 18:32 ..
drwxr-xr-x 2 squeezeboxserver root 4096 Jul 12 18:32 tmp

Apologies if I missed something basic previously. Edit: FWIW, the Terminal add-on (so I guess the core HA container) didn't know the docker command so the above is through my emulator.

pssc commented 1 year ago

@fmonday ls -la /config please and m2-ha-vm ``ls -la /usr/share/hassio/homeassistant```

pssc commented 1 year ago

Ok so in the container- which isn't where I was working before:

root@fc57b866-lms:/# id -u squeezeboxserver
1000
root@fc57b866-lms:/# ls -la /config/lms/ /config/lms/cache /config/lms/cache/plugin-data.yaml
ls: cannot access '/config/lms/cache/plugin-data.yaml': No such file or directory
/config/lms/:
total 28
drwxr-xr-x  7 squeezeboxserver root 4096 Jul 12 18:32 .
drwxrwx--- 26 root             1001 4096 Jul 13 08:38 ..
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 addon
drwxr-xr-x  3 squeezeboxserver root 4096 Jul 12 18:32 cache
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 logs
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 plugins
drwxr-xr-x  3 squeezeboxserver root 4096 Jul 12 18:32 prefs

/config/lms/cache:
total 12
drwxr-xr-x 3 squeezeboxserver root 4096 Jul 12 18:32 .
drwxr-xr-x 7 squeezeboxserver root 4096 Jul 12 18:32 ..
drwxr-xr-x 2 squeezeboxserver root 4096 Jul 12 18:32 tmp

Apologies if I missed something basic previously. Edit: FWIW, the Terminal add-on (so I guess the core HA container) didn't know the docker command so the above is through my emulator.

Web Terminal is best and for docker commands to work it needs to be running with protection mode disabled

pssc commented 1 year ago

In the container can you apt-get update ;apt-get install sudo ;cd / ; sudo -u squeezeboxserver touch /config/lms/a; ls -la /config/lms

fmonday commented 1 year ago
root@fc57b866-lms:/# sudo -u squeezeboxserver touch /config/lms/a; ls -la /confg/lms
bash: sudo: command not found
ls: cannot access '/confg/lms': No such file or directory
root@fc57b866-lms:/# su squeezeboxserver
This account is currently not available.
root@fc57b866-lms:/# cat /etc/passwd | grep squeezeboxserver
squeezeboxserver:x:1000:65534:Logitech Media Server,,,:/usr/share/squeezeboxserver:/usr/sbin/nologin

Edit: /config/lms does exist.

pssc commented 1 year ago
root@fc57b866-lms:/# sudo -u squeezeboxserver touch /config/lms/a; ls -la /confg/lms
bash: sudo: command not found
ls: cannot access '/confg/lms': No such file or directory
root@fc57b866-lms:/# su squeezeboxserver
This account is currently not available.
root@fc57b866-lms:/# cat /etc/passwd | grep squeezeboxserver
squeezeboxserver:x:1000:65534:Logitech Media Server,,,:/usr/share/squeezeboxserver:/usr/sbin/nologin

su -s /bin/bash -c "touch /config/lms/a" squeezeboxserver ; ls -la /config/lms

fmonday commented 1 year ago
root@fc57b866-lms:/config/lms# su -s /bin/bash -c "touch /config/lms/a" squeezeboxserver ; ls -la /config/lms
touch: cannot touch '/config/lms/a': Permission denied
total 28
drwxr-xr-x  7 squeezeboxserver root 4096 Jul 12 18:32 .
drwxrwx--- 26 root             1001 4096 Jul 13 18:35 ..
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 addon
drwxr-xr-x  3 squeezeboxserver root 4096 Jul 12 18:32 cache
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 logs
drwxr-xr-x  2 squeezeboxserver root 4096 Jul 12 18:32 plugins
drwxr-xr-x  3 squeezeboxserver root 4096 Jul 12 18:32 prefs
pssc commented 1 year ago

@fmonday this is a permission issue the squeezebox user cant write to its config dir try in the container chmod +x / then su -s /bin/bash -c "touch /config/lms/a" squeezeboxserver ; ls -la /config/lms , so is this a managed install on debian or HassOS, if it something more exotic i suspect it may be related, probaby to do with the container files systems.

fmonday commented 1 year ago

@pssc It's running now though I have no sound output for some reason (Edit: working now, I needed to restart the container). THANK YOU you got me 99% there and I crawled the rest of the way.

The problem wasn't / which already had permissions 755 but rather /config which had 770 and was assigned to GID 1001, which I'm guessing is meant to be squeezeboxserver but instead, when I getent group does not exist. There is also no GID 1000. Thus the non-root user had no access to that entire folder. Also possibly of interest is that the squeezeboxserver user has no group assigned at all; it doesn't seem to matter though because it's running just fine!

Do you have any idea how this happened? Do you think I need to manually add the missing groups?

fmonday commented 1 year ago

I guess I won't close this until you decide it's not a broader issue.

LaneaLucy commented 1 year ago

new install cant get it to work...

root@fc57b866-lms:/# ls -la /config/lms/ /config/lms/cache
/config/lms/:
total 28
drwxr-xr-x  7 squeezeboxserver root 4096 Aug 24 20:01 .
drwx------ 10 root             root 4096 Aug 24 20:01 ..
drwxr-xr-x  2 squeezeboxserver root 4096 Aug 24 20:01 addon
drwxr-xr-x  3 squeezeboxserver root 4096 Aug 24 20:01 cache
drwxr-xr-x  2 squeezeboxserver root 4096 Aug 24 20:01 logs
drwxr-xr-x  2 squeezeboxserver root 4096 Aug 24 20:01 plugins
drwxr-xr-x  3 squeezeboxserver root 4096 Aug 24 20:01 prefs

/config/lms/cache:
total 12
drwxr-xr-x 3 squeezeboxserver root 4096 Aug 24 20:01 .
drwxr-xr-x 7 squeezeboxserver root 4096 Aug 24 20:01 ..
drwxr-xr-x 2 squeezeboxserver root 4096 Aug 24 20:01 tmp
touch: cannot touch '/config/lms/a': Permission denied
total 28
drwxr-xr-x  7 squeezeboxserver root 4096 Aug 24 20:13 .
drwx------ 10 root             root 4096 Aug 24 20:01 ..
drwxr-xr-x  2 squeezeboxserver root 4096 Aug 24 20:01 addon
drwxr-xr-x  3 squeezeboxserver root 4096 Aug 24 20:01 cache
drwxr-xr-x  2 squeezeboxserver root 4096 Aug 24 20:01 logs
drwxr-xr-x  2 squeezeboxserver root 4096 Aug 24 20:01 plugins
drwxr-xr-x  3 squeezeboxserver root 4096 Aug 24 20:01 prefs
boardlord1 commented 1 year ago

Tried using the LMS addon, and I also got permission errors and the server restarted again and again. This happened on an up-to-date install of HAOS on a pi4. Logs attached below server.log

Output of ls -la /config/lms/ /config/lms/cache /config/lms/

total 28 drwxr-xr-x 7 root root 4096 Sep 23 18:49 . drwx------ 30 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 addon drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 cache drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 logs drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 plugins drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 prefs

/config/lms/: total 28 drwxr-xr-x 7 root root 4096 Sep 23 18:49 . drwx------ 30 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 addon drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 cache drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 logs drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 plugins drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 prefs

/config/lms/cache: total 12 drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 . drwxr-xr-x 7 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 tmp

Edit: Also did this in the container: root@fc57b866-lms:/# chmod +x / root@fc57b866-lms:/# su -s /bin/bash -c "touch /config/lms/a" squeezeboxserver ; ls -la /config/lms touch: cannot touch '/config/lms/a': Permission denied total 28 drwxr-xr-x 7 root root 4096 Sep 23 18:49 . drwx------ 30 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 squeezeboxserver root 4096 Sep 23 18:49 addon drwxr-xr-x 3 squeezeboxserver root 4096 Sep 23 18:49 cache drwxr-xr-x 2 squeezeboxserver root 4096 Sep 23 18:49 logs drwxr-xr-x 2 squeezeboxserver root 4096 Sep 23 18:49 plugins drwxr-xr-x 3 squeezeboxserver root 4096 Sep 23 18:49 prefs

pssc commented 1 year ago

Hi

yes like HA trashed the perms in the upgrade, try toggling the set_perms option in the addon.

Phill.

On Sat, 23 Sept 2023 at 17:52, boardlord1 @.***> wrote:

Tried using the LMS addon, and I also got permission errors and the server restarted again and again. This happened on an up-to-date install of HAOS on a pi4. Logs attached below server.log https://github.com/pssc/ha-addon-lms/files/12706919/server.log

Output of ls -la /config/lms/ /config/lms/cache /config/lms/

total 28 drwxr-xr-x 7 root root 4096 Sep 23 18:49 . drwx------ 30 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 addon drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 cache drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 logs drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 plugins drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 prefs

/config/lms/: total 28 drwxr-xr-x 7 root root 4096 Sep 23 18:49 . drwx------ 30 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 addon drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 cache drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 logs drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 plugins drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 prefs

/config/lms/cache: total 12 drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 . drwxr-xr-x 7 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 tmp

— Reply to this email directly, view it on GitHub https://github.com/pssc/ha-addon-lms/issues/47#issuecomment-1732363436, or unsubscribe https://github.com/notifications/unsubscribe-auth/AANORYLUWRCCERTKXURPXQTX34HWPANCNFSM6AAAAAA2DPSEVU . You are receiving this because you were mentioned.Message ID: @.***>

-- I Can Resist Everything Except Temptation -- Oscar Wilde

boardlord1 commented 1 year ago

Gihub lost 2 edits of mine...

Anyway I docker exec'd in to the lms container and ran chown 1000 /config, after which it worked. I've now also set the set_perms option in the addon, we'll see :) I'll have to try how everything functions as I'm waiting for my ESP32-WROVER boards which I intend to use to stream to BT speakers.

LaneaLucy commented 1 year ago

Hi yes like HA trashed the perms in the upgrade, try toggling the set_perms option in the addon. Phill. On Sat, 23 Sept 2023 at 17:52, boardlord1 @.> wrote: Tried using the LMS addon, and I also got permission errors and the server restarted again and again. This happened on an up-to-date install of HAOS on a pi4. Logs attached below server.log https://github.com/pssc/ha-addon-lms/files/12706919/server.log Output of ls -la /config/lms/ /config/lms/cache /config/lms/ total 28 drwxr-xr-x 7 root root 4096 Sep 23 18:49 . drwx------ 30 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 addon drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 cache drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 logs drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 plugins drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 prefs /config/lms/: total 28 drwxr-xr-x 7 root root 4096 Sep 23 18:49 . drwx------ 30 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 addon drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 cache drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 logs drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 plugins drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 prefs /config/lms/cache: total 12 drwxr-xr-x 3 1000 root 4096 Sep 23 18:49 . drwxr-xr-x 7 root root 4096 Sep 23 18:49 .. drwxr-xr-x 2 1000 root 4096 Sep 23 18:49 tmp — Reply to this email directly, view it on GitHub <#47 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AANORYLUWRCCERTKXURPXQTX34HWPANCNFSM6AAAAAA2DPSEVU . You are receiving this because you were mentioned.Message ID: @.> -- I Can Resist Everything Except Temptation -- Oscar Wilde

Still lot's of permission denied errors...

[23-10-24 08:26:31.3538] YAML::XS::DumpFile (34) Warning: Can't open '/config/lms/cache/plugin-data.yaml' for output: Permission denied at /usr/share/squeezeboxserver/CPAN/arch/5.36/x86_64-linux-gnu-thread-multi/YAML/XS.pm line 34. [23-10-24 08:26:31.3540] Slim::Utils::Prefs::Namespace::savenow (337) Error: can't save /config/lms/prefs/plugin/state.prefs: Permission denied at /usr/share/perl5/Slim/Utils/Prefs/Namespace.pm line 326. [23-10-24 08:26:31.3541] Slim::Utils::Prefs::Namespace::savenow (337) Error: can't save /config/lms/prefs/server.prefs: Permission denied at /usr/share/perl5/Slim/Utils/Prefs/Namespace.pm line 326. [08:26:31] INFO: Service restart after closing

makanimike commented 1 year ago

I am facing this issue as well.
bare metal install of HAOSS on an intel NUC.

pssc commented 1 year ago

I am facing this issue as well. bare metal install of HAOSS on an intel NUC.

have you tried set_permissions if you have, list the perms that haven't been fixed from te above logs though do look at your own up the tree with ls -la in the terminal eg

ls -la /config/lms/prefs/server.prefs /config/lms/prefs /config/lms/cache/plugin-data.yaml /config/lms/cache/