Zibbp / ganymede

Twitch VOD and Live Stream archiving platform. Includes a rendered and real-time chat for each archive.
https://github.com/Zibbp/ganymede
GNU General Public License v3.0
457 stars 24 forks source link

Playback Failure: invalid length of startup packet #246

Closed sc-idevops closed 1 year ago

sc-idevops commented 1 year ago

I'm having trouble trying to play back videos I've had Ganymede download. I checked the database container and every time I try to start playback it prints this over and over: invalid length of startup packet

Attached Docker Compose File: docker-compose.txt

Apologies for being light on info, I'm not sure what's going on still or what could even be causing the problem. Thanks for help in advance!

Zibbp commented 1 year ago

What operating system is docker running on? Is this x86 architecture or arm?

For more troubleshooting info, can you enable debug logging in /home/stev/docker-compose/ganymede/data/config.json and restart the API container. Once restarted, do you see any concerning logs in the API container when attempting to view a video?

Another troubleshooting step would be to change how the API connects to the database container to not use the internal docker network. Make the below change and try again.

-DB_HOST=ganymede-db
-DB_PORT=5432
+DB_HOST=192.168.1.147
+DB_PORT=4803
sc-idevops commented 1 year ago

Oh yes, basic system specs would have helped. I was a little brain dead at that point. This is an x86_64 system running on Kubuntu 22.04. I enabled debug mode for the API container and didn't see anything unusual. I made the change in docker compose for the DB Host and Port, restarted all the containers and still nothing different besides the error.

sc-idevops commented 1 year ago

It might be worth mentioning I have it processing a queue, but I don't see why that would impact it from being able to play back vods that have finished processing according to the queue.

Zibbp commented 1 year ago

Ya that is strange. When navigating to a VOD to watch it, what happens in the frontend? If you could also open the browser's dev tools (ctrl + shift + i) and look at the console/network tab while doing so. Are there any errors in there?

sc-idevops commented 1 year ago

ah ha! something helpful in the dev tools. 500 error console-export-2023-7-7_21-56-50.txt

Zibbp commented 1 year ago

Can you go to the network tab of the dev tool and see what route that 500 error is?

sc-idevops commented 1 year ago

It's trying to connect on http://192.168.1.147:4801

192.168.1.147_Archive [23-07-07 22-02-18].har.txt

Zibbp commented 1 year ago

Any error logs for the frontend container?

sc-idevops commented 1 year ago
> ganymede-frontend-next@0.1.0 start
> next start
- ready started server on 0.0.0.0:3000, url: http://localhost:3000
- warn "next start" does not work with "output: standalone" configuration. Use "node .next/standalone/server.js" instead.
- warn "next start" does not work with "output: standalone" configuration. Use "node .next/standalone/server.js" instead.
[vidstack] dev mode!
Zibbp commented 1 year ago

It appears it's failing on a server side request. Can you ensure the frontend container can talk to the API by following the below steps? The curl request should return "OK".

docker exec -it ganymede-frontend /bin/ash
apk add curl
curl http://192.168.1.147:4800/health

Can you also provide a Twitch link / ID to one of the VODs this is failing with?

Zibbp commented 1 year ago

Oh, I also just noticed that the CDN_URL points to the database port, not the nginx port. Maybe that's it?

sc-idevops commented 1 year ago

BINGO! You got it! thank you so much! It's playing immediately now. I can't believe I messed that up, the ONE part of the docker compose file I had to do myself. I appreciate your quick help though thanks again @Zibbp!