UnicornTranscoder / UnicornLoadBalancer

MIT License
128 stars 16 forks source link

Server not available at Tizen app (samsung smart-tv) #61

Open babatonga opened 1 year ago

babatonga commented 1 year ago

Tizen Plex version: 5.56.1 plexmediaserver build: 1.31.2.6810-a607d384f UnicornLoadBalancer: 2.4.3

Server appears as offline on tv's plex app. On andoid app and app.plex.tv everything is working fine from inside and outside local network. If I add the ip & balancer port manually, it will show all libraries, but fails on playing/transcoding ( maybe refers to #37 ). Nginx acces.log of UnicornTranscoder is logging requests from samsung-agent, but is responding 400.

Maxou44 commented 1 year ago

Is it working on other platforms like Web / Android / PC ?

Is the Plex Relay feature disabled? Is 32400 port blocked ?

Are you sure the incoming traffic pass throught the load balancer ?

babatonga commented 1 year ago

Its working on Web, Android & PC from inside and outside local network. The loadbalancer and all transcoders have public domains with nginx(transcoders) / apache (load balancer) as reverse proxy:

Other configurations:

When inspecting network-traffic while watching videos: All streaming-related requests are send to transcoder-urls (eg. https://tc1.mysite.tv/video/:/transcode/universal/session/...)

On TV I only could set a manual IP (local ip with port 3001, not reverse proxy), not a domain. Without setting it, the server appears as "not available", with setting it, the request is arriving at transcoding-servers when starting a video, but TV shows an error immediately.

babatonga commented 1 year ago

Update: after setting (server->settings->network) secure-connections from preffered to required, the server is available again at tizen app. But videos could still not be played, app shows "an unexpected error occurred" immediately after starting playback.

Transcoding is starting on UnicornTranscoder, here are some nginx logs:

[21/Mar/2023:23:27:32 +0100] "GET /music/:/transcode/universal/session/<samsungtv_session>/base/index.m3u8 HTTP/1.1" 200 215 "-" "samsung-agent/1.1"
[21/Mar/2023:23:27:32 +0100] "GET /music/:/transcode/universal/session/<samsungtv_session>/base/00000.ts HTTP/1.1" 200 27072 "-" "samsung-agent/1.1"
[21/Mar/2023:23:27:32 +0100] "GET /music/:/transcode/universal/session/<samsungtv_session>/base/00001.ts HTTP/1.1" 200 28012 "-" "samsung-agent/1.1"
... until it suddenly stops after ~/base/0030.ts

but not everytime, sometimes the only log I get is the initializing via GET /api/resolve?session=... with 200 as response and no further requests.

Maxou44 commented 1 year ago

Do you have a debug mode on the Tizen app to enable app logs ?

babatonga commented 1 year ago

I'll try to enable debug logs and post/attatch them here in the next days.

Now I purchased an Android-TV-Box (LEAP-S1) and everything is working fine with it... much better than pretty slow samsung-tizen did :-) The Tizen plex app did often freeze in the movie selection or while fast forwarding and I read lots of posts about people struggling with it. Now everything is super fast and I don't even need transcoding on it anymore, almost everything is playing directly (video + digital sound).