Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues running on dietpi distribution #7

Open
jkiddo opened this issue Dec 27, 2020 · 5 comments
Open

Issues running on dietpi distribution #7

jkiddo opened this issue Dec 27, 2020 · 5 comments
Assignees
Labels

Comments

@jkiddo
Copy link

jkiddo commented Dec 27, 2020

Hi all - I'm experiencing some issues starting up the docker image when running it on the DietPi distribution (https://dietpi.com/): The output of starting the docker image is the following:

$ docker run --name snapserver --net host -e DEVICE_NAME=Snapcast mazzolino/librespot-snapserver
2020-12-27 19-09-48 [Info] (main) Adding stream: librespot:///librespot?name=Spotify&devicename=Snapcast&bitrate=320&volume=100
2020-12-27 19-09-48 [Notice] (init) Settings file: "/root/.config/snapserver/server.json"
2020-12-27 19-09-48 [Error] (init) Error reading config: [json.exception.parse_error.101] parse error at 1: syntax error - unexpected end of input; expected '[', '{', or a literal
2020-12-27 19-09-48 [Error] (Avahi) Failed to create client: Daemon not running
2020-12-27 19-09-48 [Info] (start) Creating TCP acceptor for address: 0.0.0.0, port: 1705
2020-12-27 19-09-48 [Info] (start) Creating HTTP acceptor for address: 0.0.0.0, port: 1780
2020-12-27 19-09-48 [Info] (PcmStream) PcmStream sampleFormat: 44100:16:2
2020-12-27 19-09-48 [Info] (PcmStream) metadata={
2020-12-27 19-09-48 [Info] (PcmStream)     "STREAM": "Spotify"
2020-12-27 19-09-48 [Info] (PcmStream) }
2020-12-27 19-09-48 [Info] (onMetaChanged) onMetaChanged (Spotify)
2020-12-27 19-09-48 [Info] (start) Stream: {"fragment":"","host":"","path":"/librespot","query":{"bitrate":"320","chunk_ms":"20","codec":"flac","devicename":"Snapcast","name":"Spotify","sampleformat":"44100:16:2","volume":"100"},"raw":"librespot:////librespot?bitrate=320&chunk_ms=20&codec=flac&devicename=Snapcast&name=Spotify&sampleformat=44100:16:2&volume=100","scheme":"librespot"}
2020-12-27 19-09-48 [Error] (PosixStream) Connect exception: execve failed: No such file or directory
2020-12-27 19-09-48 [Info] (start) Creating stream acceptor for address: 0.0.0.0, port: 1704
2020-12-27 19-09-48 [Info] (main) number of threads: 4, hw threads: 4
2020-12-27 19-09-48 [Error] (PosixStream) Connect exception: execve failed: No such file or directory
2020-12-27 19-09-48 [Error] (PosixStream) Connect exception: execve failed: No such file or directory
2020-12-27 19-09-48 [Error] (PosixStream) Connect exception: execve failed: No such file or directory

-and it just continues writing: [Error] (PosixStream) Connect exception: execve failed: No such file or directory. It never starts up

@djmaze djmaze self-assigned this Jan 4, 2021
@djmaze djmaze added the bug label Jan 4, 2021
@djmaze
Copy link
Owner

djmaze commented Jan 4, 2021

Well, this is not a problem with the distribution, but the armhf (aka. 32bit arm) image seems to ship a non-working librespot ;-/ Might be happening because I am building the armhf images on an arm64 machine. Will have a closer look..

@djmaze
Copy link
Owner

djmaze commented Jan 5, 2021

Okay, it is complicated. We cannot currently cross-build debian images because all official docker binaries for arm32 seem to be broken currently.

I just built the image manually on a real armhf device. Can you try if mazzolino/librespot-snapserver:arm works for you? I had to change the image so it also contains a newer snapcast version (0.22).

@jvitrifork
Copy link

Seems to work ;)

@jvitrifork
Copy link

FWIW, the console now logs the following:

dietpi@DietPi:~$ docker run --name snapserver --net host -e DEVICE_NAME=Snapcast mazzolino/librespot-snapserver:arm
2021-01-06 08-37-23.407 [Info] (main) Adding source: pipe:///tmp/snapfifo?name=default
2021-01-06 08-37-23.410 [Notice] (init) Settings file: "/root/.config/snapserver/server.json"
2021-01-06 08-37-23.413 [Error] (Avahi) Failed to create client: Daemon not running
2021-01-06 08-37-23.414 [Info] (PcmStream) PcmStream: default, sampleFormat: 48000:16:2
2021-01-06 08-37-23.414 [Info] (PcmStream) Stream: default, metadata={
2021-01-06 08-37-23.414 [Info] (PcmStream)     "STREAM": "default"
2021-01-06 08-37-23.414 [Info] (PcmStream) }
2021-01-06 08-37-23.414 [Info] (Server) onMetaChanged (default)
2021-01-06 08-37-23.415 [Info] (PipeStream) PipeStream mode: create
2021-01-06 08-37-23.416 [Info] (Server) Stream: {"fragment":"","host":"","path":"/tmp/snapfifo","query":{"chunk_ms":"20","codec":"flac","name":"default","sampleformat":"48000:16:2"},"raw":"pipe:////tmp/snapfifo?chunk_ms=20&codec=flac&name=default&sampleformat=48000:16:2","scheme":"pipe"}
2021-01-06 08-37-23.419 [Error] (PosixStream) Exception: end of file
2021-01-06 08-37-23.419 [Info] (ControlServer) Creating TCP acceptor for address: 0.0.0.0, port: 1705
2021-01-06 08-37-23.420 [Info] (ControlServer) Creating HTTP acceptor for address: 0.0.0.0, port: 1780
2021-01-06 08-37-23.420 [Info] (StreamServer) Creating stream acceptor for address: 0.0.0.0, port: 1704
2021-01-06 08-37-23.420 [Info] (main) number of threads: 4, hw threads: 4
2021-01-06 08-37-23.467 [Notice] (StreamServer) StreamServer::NewConnection: 192.168.1.12
2021-01-06 08-37-23.910 [Info] (Server) Hello from b8:27:eb:ed:87:7b, host: DietPi, v0.15.0, ClientName: Snapclient, OS: Raspbian GNU/Linux 10 (buster), Arch: armv7l, Protocol version: 2
2021-01-06 08-37-25.911 [Error] (StreamSessionTCP) Error reading message header of length 0: End of file
2021-01-06 08-37-25.911 [Info] (StreamServer) onDisconnect: b8:27:eb:ed:87:7b
...

I haven't mounted any config files into the container which is probably why the trace looks like the way it does. It would be a nice addition to the readme if it could be documented where the config files are placed inside the container. If I can find the time, I'll do a PR on that part

@jkiddo
Copy link
Author

jkiddo commented Jan 7, 2021

Oops - forgot to switch back to private account: jkiddo==jvitrifork

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants