Squeezelite doesn't work

Creating a bug report/issue

I have searched the existing open and closed issues

Required Information

  • DietPi version | 8:25

  • SBC model | Allo sparky usbridge

  • Power supply used | (EG: 5V 3A )

  • SD card used | (Goodram

LMS server 8.31

  • ------------ the problem ---------
    Squeezelite. doesn’t work - log file below
● squeezelite.service - Squeezelite (DietPi) │

│ Loaded: loaded (/lib/systemd/system/squeezelite.service; enabled; vendor preset: enabled) │
│ Drop-In: /etc/systemd/system/squeezelite.service.d │
│ └─dietpi-services_edit.conf │
│ Active: failed (Result: exit-code) since Thu 2023-12-21 21:23:02 GMT; 1min 46s ago │
│ Docs: man:squeezelite(1) │
│ https://ralph-irving.github.io/squeezelite.html │
│ Process: 322 ExecStart=/usr/bin/squeezelite -a 4096:8096:32:0 -C 5 -n DietPi-Squeezelite (code=exited, │
│ status=1/FAILURE) │
│ Main PID: 322 (code=exited, status=1/FAILURE) │
│ │
│ Dec 21 21:23:00 DietPi systemd[1]: Started Squeezelite (DietPi). │
│ Dec 21 21:23:02 DietPi squeezelite[322]: [21:23:02.108063] test_open:281 playback open error: No such file or │
│ directory │
│ Dec 21 21:23:02 DietPi squeezelite[322]: [21:23:02.108387] output_init_common:401 unable to open output device: │
│ default │
│ Dec 21 21:23:02 DietPi systemd[1]: squeezelite.service: Main process exited, code=exited, status=1/FAILURE │
│ Dec 21 21:23:02 DietPi systemd[1]: squeezelite.service: Failed with result 'exit-code'.

but when I manually in shh root@… put the

/usr/bin/squeezelite -a 4096:8096:32:0 -C 5 -n DietPi-Squeezelite

or restart service, everything works fine - I see squeezelite (DietPi-Squeezelite) and music play

this is the same string

I tried to change config file for Squeezelite.service

see below

**[Unit]**

#Description=Squeezelite (DietPi)

#Documentation=man:squeezelite(1) https://ralph-irving.github.io/squeezelite.html

After=dietpi-cloudshell.service

**[Service]**

#User=squeezelite

#EnvironmentFile=/etc/default/squeezelite

#ExecStart=/usr/bin/squeezelite -a 4096:8096:32:0 -C 5 -n 'DietPi-Squeezelite'

Type=idle

**[Install]**

#WantedBy=multi-user.target

I add string Type=idle and sometime works sometime not

modified line — After=dietpi-cloudshell.service. - Think that is last service to boot - maybe wrong ( originally was #After=aftersoundtarget.service )

no differences

I tried on 3 USB DACs - the same situation

Any idea ?

soo if you simply restart the service it is working? But not after a reboot?

It looks like, that your DAC is taking longer to become available compared to squeezelite.service to start.

Exactly

I tried to boot squeezelite as the last of services but I don’t know much about linux and It doesn’t work

you could try adding a sleep into service file. Can you share current configuration?

systemctl cat squeezelite
**# /lib/systemd/system/squeezelite.service**

[Unit]

Description=Squeezelite (DietPi)

Documentation=man:squeezelite(1) https://ralph-irving.github.io/squeezelite.html

After=sound.target

[Service]

User=squeezelite

EnvironmentFile=/etc/default/squeezelite

ExecStart=/usr/bin/squeezelite -a 4096:8096:32:0 -C 5 -n 'DietPi-Squeezelite'

[Install]

WantedBy=multi-user.target

**# /etc/systemd/system/squeezelite.service.d/dietpi-services_edit.conf**

[Unit]

#Description=Squeezelite (DietPi)

#Documentation=man:squeezelite(1) https://ralph-irving.github.io/squeezelite.html

After=dietpi-cloudshell.service

[Service]

#User=squeezelite

#EnvironmentFile=/etc/default/squeezelite

#ExecStart=/usr/bin/squeezelite $ARGS

Type=idle

[Install]

#WantedBy=multi-user.target

you can try to adjust /etc/systemd/system/squeezelite.service.d/dietpi-services_edit.conf and add a ExecStartPre command into [Service]section. Like this.

[Service]
ExecStartPre=/bin/sleep 30
1 Like

Thank You very much
I made it and now it’s time to test .
Maybe this is it
Sparky is in the car audio system and I need a few days to be sure

Everything works fine - thank you for help - problem solved