jellyfin / jellyfin-androidtv

Android TV Client for Jellyfin
https://jellyfin.org
GNU General Public License v2.0
2.43k stars 411 forks source link

Client incorrectly thinks that it is outside of the local network when routing through locally hosted reverse proxy #3662

Open nathansmeal opened 2 weeks ago

nathansmeal commented 2 weeks ago

Describe the bug

  1. Setup a reverse proxy server to point to jellyfin server
  2. Set a static DNS A record for your reverse proxy's LAN ip in your local DNS server
  3. Configure an internet streaming bitrate in the Jellyfin server settings; an example would be 5mbps
  4. Connect to your server using the reverse proxy's DNS name
  5. Find that transcoding is forced on when using the jellyfin android TV client only, other clients do not transcode in this scenario

Internet transcoding should not turn on in this scenario because all traffic is still routing locally

Logs

No response

Application version

0.16.11

Where did you install the app from?

Amazon Appstore

Device information

Fire TV Stick 4K

Android version

Fire OS 6.7

Jellyfin server version

10.9.2

pascalwei commented 2 weeks ago

Are you 100% sure the TV respects your local DNS? I am unable to reproduce this. Google pushes their own DNS servers quite a bit on Android TV, so most likely it's set to 8.8.8.8 by default instead of your local DNS. Set the DNS manually to your local DNS resolver with a static IP configuration in Settings > Network & Internet > IP settings or sideload something like Lilly DNS changer as an APK and setup the local DNS that way.

The only way to work around this is to do our own DNS resolution instead of the provided one by Android, but I don't know if that's something we want to do. Maybe we could add this problem to the documentation though.

nathansmeal commented 2 weeks ago

Hi,

I just checked to make sure, and the Fire TV stick does obey the local DNS settings. From the TV's perspective it should only be routing locally.

Edit: I've noticed that it only happens with 4K HEVC HDR content. Could this just be an incorrect transcoding reason message? Attached is related media info for affected content.

image

image

pascalwei commented 2 weeks ago

No, the transcoding message should be correct. There have been reports of problems with the max streaming bitrate if it is set to auto in the client. You can find it in Preferences > Playback > Max streaming bitrate. Does the problem still occur if it is set to 120 Mbps?

nathansmeal commented 2 weeks ago

No, the transcoding message should be correct. There have been reports of problems with the max streaming bitrate if it is set to auto in the client. You can find it in Preferences > Playback > Max streaming bitrate. Does the problem still occur if it is set to 120 Mbps?

Yep that fixed it. Thank you!