Plex Server Becomes Partially Unavailable

I was noticing my Plex server was no longer available on two different ONN Google boxes internally. Then I noticed it disappeared on some internal and external WebUI clients. Essentially the Plex home screen showed no content and my Plex server was no longer available in the list. Even after re-logging in to Plex and reinstalled the Plex app on those devices, it did not resolve the issue…

However, my Samsung TV Plex app, Android Plex app, and my remote friends still able to access/see my Plex libraries w/o an issue…

When I restart my Plex docker, it momentarily resolved the issue for a 15min, but the issue would then return…

====

My Plex server was on version 1.42.2.10156 using repository `lscr.io/linuxserver/plex:version-1.42.2.10156-f737b826c`

While troubleshooting, I changed my Plex docker repo back to `linuxserver/plex:latest` and it pulled down version 1.42.1.10060.

For context, my Plex server is using a custom URL for remote-access (no relay) and its behind nginx over port 443.

The same issue occurs after downgrading my Plex server ver., When I restart my Plex docker, it momentarily resolved the issue for a 15min, but the issue would then return…

My Reddit post: Reddit - The heart of the internet


Here’s an update but no resolution yet:

So far I ruled OUT the following to NOT be the cause of the issue:

:white_check_mark: DNS rebind protection (added plex.direct my fqdn to unbound DNS private domains)

:white_check_mark: NAT reflection (tested enabled and disabled)

:white_check_mark: Nginx plex.subdomain.conf configuration (verified header requirements)

:white_check_mark: Fail2ban (tested while disabling all jails)

:white_check_mark: Reinstall of Plex app on Google TV box (onn)

The issue for me is only affecting my account when accessing the Plex webUI from multiple devices on internal and external connections, and also Plex app on my Google TV streaming box (onn).

HOWEVER, it is not affecting my Samsung TV Plex app,my Android phone Plex app, or remote friends I’ve shared libraries to using the Plex app on various devices. (Head banging against the wall)

I restarted the Plex docker again and refreshed my Plex webUI, now I see my server again and shared libraries as expected. But as I stated above, this does not retain and my server disappears after a few minutes. The only difference this time since restarting Plex is, the added plex.direct to my private domain list in unbound DNS…

AFTER EXACTLY 15 MIN THE ISSUE RETURNS :sad_but_relieved_face::face_with_steam_from_nose::face_with_symbols_on_mouth:

Has anyone else experienced an issue like this?

Folks will definitely want some log files: https://support.plex.tv/articles/201869908-log-files/

If you can grab from client and server that might help folks track things down as it does seem like you’ve done a lot of the initially troubleshooting that should help sort this out.

Do you have any DNS filters running? Sometimes those can get a false positive that might impact your authentication to Plex servers which is required for Plex to work. That’d be an aspect that would impact you but not your remote friends. Some clients - like Roku - cache that authentication better than others which could explain why your Samsung keeps working.

1 Like

Y’know, I had an issue scarily similar to this about a week ago. I do not use any odd systems like NGINX, PiHole, or special intermediaries. Mid-movie, my player game me the spinner of death when I tried to reverse to see something I missed in the movie. The client is an Nvidia Shield, connected via ethernet to a switch, from there to a switch, from there to the server (Ubuntu server with Docker-based Plex).

When I killed the app for non-response, upon coming back up, it took a few seconds for metadata to load. Eventually, it did, but playing the media gave me the error that it was an indirect connection. This flabbergasted me, as I am connected as nearly directly as it is possible to do. After a series of reboots of devices one by one, it EVENTUALLY worked again, but what is strange to me is how it happened at all, mid-show.

Rebooted shield: indirect connection.
Rebooted switch behind shield: indirect connection.
Rebooted switch next to server: indirect connection.
Rebooted Docker on server: indirect connection.
Rebooted server itself: indirect connection.
Rebooted router: Connection established.

This was a bizarre issue, and all I can think of is some kind of massive error in the router’s DHCP that caused a routing issue for the switches, which caused my client to be unable to connect to the server directly. This is odd, since we do NOT use the router as a switch.

Edit: By the time it was fixed, I had no logs, and was frustrated enough. I browsed the console at the time of the error, but didn’t see anything that stood out as coming from the client’s failed connection.

---------Story over---------

Anyway, all I can suggest is… REBOOT EVERYTHING. It’s silly advice usually given to un-techy people, but it can fix things. Reboot the server itself, not just the docker. Reboot your DHCP/router, even if it is not in-between your client and server.

Based on the clients affected or not, it sounds like things most likely to be on wireless work fine (TV, phone) and remote access (friends), but not wired devices. If you use a separate subnet for wireless than wired, then it could result in connection issues if the WIRED subnet is screwed up.

1 Like

Thanks for the response and question. Since not all clients are affected by this, and the ones that are, are using the same unbound DNS server on my opnsense firewall

Thanks for your reply and I can appreciate your story as I experience something similar to that in the past than unrelated to this issue.

For what it’s worth, I had restarted the Plex server docker several times, which only resolves the issue for 15 minutes. Rebooted my opnsense firewall since the issue started.

I’m still bagging my head against the wall and narrowing this down. And ruling out one component at a time as you can see.

I’ve had a couple short-term dips in availability over the last 2 weeks in the evenings when I’m home. When checking my logs all is well on my end, I’ve chalked it up to either ISP issues upstream or Plex authentication issues which are known to happen.

Surprisingly there isn’t much on status.plex.tv but I know for a fact everything on my end is fine since it springs back to life after a few minutes without my intervention.

1 Like

Thanks for your reply and I appreciate the insight. However, my issue is consistent as outlined above and started happening within the last 2 weeks.

Update:

I re-checked nginx timeout settings and changed these in my Plex nginx config (plex.subdomain.conf):

proxy_read_timeout 3600;

proxy_connect_timeout 3600;

proxy_send_timeout 3600;

send_timeout 3600;

I changed WebSocket support :

proxy_http_version 1.1;

proxy_set_header Upgrade $http_upgrade;

proxy_set_header Connection “upgrade”;

Summary:

  • Changed connection header by changing to $http_connection which properly handles both normal and WebSocket connections.
  • Increased all timeouts to 3600s (1 hour) in the main location block.
  • Added send_timeout to main location.
  • Removed conflicting/duplicate Connection headers

After restarting the Plex docker, the Plex app on my Google TV box successfully reconnected to my Plex again and showed server and libraries. I started playing media too. Also my Android phone webUI did the same.

After 15 minutes:

Android phone:

But after 15min the issue returned when I refreshed browser. (tested multiple browsers). However, my Android Plex app continues to work fine.

Google TV (onn):

Media continues to play (started before 15min mark), but once I exit Plex app and reopen, my Plex server is no longer available and home screen pinned libraries gone:

Samsung TV native Plex app and Remote friends:

Are NOT affected by this issue. :exclamation_question_mark:

===

Still banging head against wall and can’t seem to figure this one out.

New Analysis - This is NOT an nginx timeout issue

Since the problem:

  • Still happens at exactly 15 minutes (not 5 minutes from the old 300s timeout)
  • Affects only WebUI and Google TV when they reconnect
  • Does NOT affect active streaming (media continues playing)
  • Does NOT affect Samsung TV or friends’ devices
  • Does NOT affect Android Plex app (only Android WebUI)

This points to Plex’s authentication token/claim system, not nginx.

Root Cause: Plex.direct Certificate/Token Claims

The 15-minute mark is likely tied to Plex’s server claim token or plex.direct DNS/certificate refresh cycle. Here’s what I think is happening:

The Pattern Suggests:

  1. When Plex restarts, it generates a fresh claim/token
  2. Certain clients (WebUI, Google TV app) receive this token
  3. After 15 minutes, these clients try to re-validate the server using plex.direct domains
  4. This validation fails because of your reverse proxy setup
  5. Clients that maintain persistent connections (Samsung TV, active streams) don’t re-validate as aggressively

I feel like I’m getting warmer, stay tuned…

UPDATE:

In my browser dev tools > network, I see this as pending for a long time:

wss://110-175-138-164.<myPlexServerHash>.plex.direct:32400

Which is a pending WebSocket connection and may be my smoking gun…

My Analysis:

The above wss URL is pointing to an external IP instead of the internal IP of my nginx reverse-proxy server. The WebSocket connection is stuck in “pending” state, which means the client is trying to establish a secure WebSocket connection to my Plex server via the plex.direct domain public address.

My Plex server settings were already configured in this manner for several months and before this issue started occurring:

  • Remote Access: Disabled

  • Custom server access URLs to: https://plex[.]]MyDomain[.]com:443

  • Secure connections to: Preferred (not Required)

  • Disabled “Enable Relay” option

===

I started with fixing the DNS resolution for my servers <myServersHash>.plex.direct domain so that it points to my nginx internally, then the WebSocket connections should work through my nginx reverse proxy.

After adding an Opnsense Unbound DNS Override record for <myPlexServersHash>.plex.direct to point to my nginx docker IP, I now see it is resolving to my nginx when doing nslookup from various clients.

I then restarted the Plex docker and tested again…

The Plex webUI now showed my server and libraries again, which I had to re-pin all my libraries again, and the same resolved the issue for my Google TV (onn) Plex app.

AFTER 15min, the Plex webUI client issue returned after refreshing the browser on several internal devices and I no longer see my Plex server and libraries.

However, the Plex app on my Google TV (onn) box NOW continues to work and maintain my server with pinned libraries—even after re-opening the app and turning off/on the onn box.

Update: after 30 minutes and checking my Google TV Plex app again, the server disappeared with all my libraries.

Still no resolution…

Any thoughts from the community?

Have you seen this post?

It doesn’t apply to my issue.

What’s interesting is, if I make any test edits to the Plex > Settings > Network > Custom Server Access URL’s field and save it, the issue gets resolved when I refresh the Plex webUI on my devices.

I am repeating myself now, but context is important :-/

However, the issue returns after ~15min and my server and libraries disappear on my Google TV’s (onn box).

Again, this issue is not affecting my Plex Android phone app, Samsung TV Plex app, nor does it affect my remote users. However, it does affect my account (admin) when testing externally via Plex webUI, but does not affect the Plex app on the same phone internally or externally…

UPDATE:

After 12 hours, I’m came back to my browser tab for the Plex webUI and all looked good (without refreshing). I even testing playing a movie and it worked fine.

However, when I refreshed the browser tab and I selected my home user (admin), my server and libraries disappeared again, and I was faced with the message again":

Your home screen is empty
Your home screen is based on sources pinned to your sidebar. Choose a source from the More menu and pin it to see its content here.

If I restart the Plex server docker or make a minor edit to the Plex settings > Network > ‘custom server url’ field, it resolves the issue if I refresh again. But I have to re-pin my server’s libraries for the home screen to show properly.

What could be causing this?

This isn’t really an area that I get into, but it seems that the Google TV and the Plex webUI are seeing that they are being forced to maintain a secure connection over port 443, which is typically reserved for HTTPS web traffic. I suspect that they are not happy being forced to use this port (or forced to use HTTPS) and disconnect. I would try a different port - 32400?. https://plex.mydomain.com:32400 Frankly, I don’t see a reason why you would want to use port 443 in this case. My two cents worth. Posting logs might help in getting some higher level plex support.

Thanks for your reply and you make a fair point. Hosting Plex server on Port 443 via reverse proxy is a supported method and has worked for me for over a year.

To summarize my issue on this post, it’s only affecting My Plex admin account via the webUI and two Google TV ONN boxes using Plex app.

NONE of my remote users, my Android phone app, or my Samsung TV Plex app is affected.

The reason why I use use port 443 instead of the native 32400 is to reduce my attack surface, and take advantage nginx reverse proxy.

I only have to allow one port forward (443) in this scenario.

Perhaps I’ll switch my Plex server back to Port 32400 as a test and see if the issue resolves itself.

I went to Google AI with this question:

Is it required to use port 443 on a nginx reverse proxy?

Response:

No, it is not required to use port 443 for an Nginx reverse proxy, though it is standard practice for HTTPS. You can configure Nginx to listen on and proxy traffic to any available port, but you would need to specify the non-standard port in the client’s URL

:rofl:

Right, that is correct. As to my last point, I wanted to keep all my remote web app services on Port 443 via reverse proxy.

To be clear, my reverse proxy accepts connections externally on 443 and uses port 32400 to my Plex docker internally.

I’ll go back to Port 32400 natively without nginx and test.

So I switched back to Plex native Port 32400 without relay and no nginx as a test…

1. Changed opnsense nat rules and updated my unbound DNS Plex override record.

2. Removes Plex settings custom network URL and restarted Plex server docker.

3. Enabled Plex settings Remote access and enabled manual specify of Port 32400

4. Renamed nginx Plex subdomain conf file to.bak

5. Rebooted and reinstalled Plex app on Google TV ONN boxes

====

Results:

* Google TV ONN boxes still experiencing the same issue explained above (internal).

* Plex webUI on multiple laptops and phone experience same issue explained above (internal and external).

* Plex app on Android phone continues to work fine without issue.

* External/ remote users using Plex app on various devices continue to work fine without issue.

====

Some debugging and testing I proceeded to do:

# Stop Plex

docker stop plex

# Remove claim file

docker exec plex rm -f “/config/Library/Application Support/Plex Media Server/plexmediaserver.pid”

# Edit Preferences.xml to remove stale data

docker start plex

sleep 5

# Get a new claim token from https://plex.tv/claim

# Then update your docker with PLEX_CLAIM environment variable

-

# Test if Plex container can reach plex.tv

docker exec plex curl -v https://plex.tv

# Test DNS resolution

docker exec plex nslookup plex.tv

# Test specific plex.tv endpoints

docker exec plex curl -v https://plex.tv/api/v2/ping

-

# Verify what IP and URL is configured

docker exec plex cat “/config/Library/Application Support/Plex Media Server/Preferences.xml” | grep -oP ‘(PublicAddress|customConnections|ManualPortMappingMode|PublishServerOnPlexOnlineKey)=“[^”]*"’

-

# Verify what IP and URL is configured

docker exec plex cat “/config/Library/Application Support/Plex Media Server/Preferences.xml” | grep -oP ‘(PublicAddress|customConnections|ManualPortMappingMode|PublishServerOnPlexOnlineKey)=“[^”]*"’

-

#Verify what is plex.tv has registered

TOKEN=$(docker exec plex cat “/config/Library/Application Support/Plex Media Server/Preferences.xml” | grep -oP ‘PlexOnlineToken=“[^”]*"’ | cut -d’"’ -f2)

# Check the full resources response

curl -s -H “X-Plex-Token: $TOKEN” “https://plex.tv/api/v2/resources?includeHttps=1&includeRelay=1” > full-resources.json

# Show full output

cat full-resources.json

# Also check your actual connections

curl -s -H “X-Plex-Token: $TOKEN” “https://plex.tv/api/servers/f8d260306fee327d916a<removed>”

-

# Verify token works

curl -s -H “X-Plex-Token: $TOKEN” “https://plex.tv/api/v2/user” | grep -o ‘“username”:“[^”]*"’

# Check server registration from plex.tv’s perspective

curl -s -H “X-Plex-Token: $TOKEN” “https://plex.tv/pms/servers.xml”

-

# Restart Plex to force re-registration

docker restart plex

# Wait 30 seconds

sleep 30

# Check again

TOKEN=$(docker exec plex cat “/config/Library/Application Support/Plex Media Server/Preferences.xml” | grep -oP ‘PlexOnlineToken=“[^”]*"’ | cut -d’"’ -f2)

curl -s -H “X-Plex-Token: $TOKEN” “https://plex.tv/api/v2/resources?includeHttps=1” | grep -c ‘“provides”:“server”’

-

# Check IP, domain and presence

TOKEN=$(docker exec plex cat “/config/Library/Application Support/Plex Media Server/Preferences.xml” | grep -oP ‘PlexOnlineToken=“[^”]*"’ | cut -d’"’ -f2)

echo “Token (first 20 chars): ${TOKEN:0:20}…”

# v1 Resources API

curl -s -H “X-Plex-Token: $TOKEN” “https://plex.tv/api/resources?includeHttps=1&includeRelay=1”

# Classic servers endpoint

curl -s -H “X-Plex-Token: $TOKEN” “https://plex.tv/pms/servers.xml”
#Monitor Plex visibility script

TOKEN=$(docker exec plex cat “/config/Library/Application Support/Plex Media Server/Preferences.xml” | grep -oP ‘PlexOnlineToken=“[^”]*"’ | cut -d’"’ -f2)

while true; do

echo “=== $(date +%H:%M:%S) ===”

# Check plex.tv visibility

SERVERS=$(curl -s -H “X-Plex-Token: $TOKEN” “https://plex.tv/api/resources?includeHttps=1” | grep -c ‘name=“LeeFlix”’)

echo “LeeFlix visible on plex.tv: $SERVERS”

# Check local from inside container

docker exec plex curl -s -m 2 http://localhost:32400/identity > /dev/null 2>&1 && echo “✓ Local OK” || echo “✗ Local FAIL”

echo “”

sleep 300

done

The output from the above commands did not reveal any issues and had expected working output.

What could I be missing y’all?

1 Like

Without seeing the Logs that relate to the times that the server and libraries disappear, I think that it will continue to be anybody’s guess.