Plex Web uses the wrong internal IP

Server Version#: 1.22.1.4275-48e10484b
Player Version#: app.plex.tv

I moved my Plex installation to a different server (both Ubuntu 20.04) on another network, as per the Move an Install to Another System guide. Remote access works fine, but the private IP has not been updated according to the new server.

Usually when I use the official web player at app.plex.tv and I look at the browser’s network inspector, I can see that it makes a call using the internal IP (10-x-x-x.*.plex.direct) first and uses that for the remaining network calls if it works, otherwise it falls back to the external address.
However, my Plex client is stuck at the old private IP, so the initial XHR call for the private IP always fails, causing it to use the external address instead and pass the traffic through my router using NAT reflection. I have to access Plex directly at 10.x.x.x:32400 in my browser in order to force the video streaming traffic through its internal IP address.

In the remote access settings, the correct private IP appears on the new server. I have tried disabling and re-enabling remote access entirely, to no avail. The server has been online with the new IP for 4 days now without any changes.
The server has a single NIC with one IP address on a normal /24 network, so there’s nothing fancy about the network configuration.
I have tried logging in and out many times, and also logging to the Plex web client from another browser that has never been used for Plex before, but the issue remains. So it seems like the outdated IP comes from the server rather than a browser cache.
The previous server was shut down gracefully before its data folder was extracted, and has definitely not been online since then.

Any ideas on how to get Plex to force a refresh of a server’s private IP?

1 Like

Perform a “Switch User” to e.g. the Guest account and back, to force the client app to refresh it’s info about your server.

Which of course can only work if the server has been signed into your plex.tv account.

Thanks for your response! I enabled the guest account, switched to it and then back to the root user, however it didn’t change anything.
I have also tried logging my server out of plex.tv and back in multiple times, to no avail. The Plex insists on using the outdated internal IP, unless I access it directly on that address. :neutral_face:

Clear the cache of your web browser and do the above again. I removed that 2 year old server from your account, so only one remains now.

It didn’t help, unfortunately.
I have tried everything mentioned several times after your change, and also using yet another browser which hasn’t been used before. It’s still stuck at the old internal IP.

Even when I access the server at [current internal IP]:32400, I can see that it attempts to contact the previous IP using a plex.direct hostname, and fails, but luckily it falls back to the address that I used to access the web client.

However, my library sharing count is now correct in Users & Sharing, unlike before where it was saying 4 instead of 2 for some users. So that old server was definitely causing some confusion.

sudo systemd-resolve --flush-caches

That also didn’t help, unfortunately.

Open the command line.

nslookup <name of the host>

Show me what your DNS is returning.

Also, which local DNS resolver are you running on the LAN / Gateway ?

Which hostname should I try to resolve?
I’m not using a custom domain name, just the built-in *.plex.direct mechanism, which is working fine for the external IP address.

My router is acting as a DNS forwarder (Unbound) for my ISPs DNS servers. I have just tried switching to 8.8.8.8 and 8.8.4.4 to see if it helps. So far no difference.
Also, the plex.direct hostname used in the browser’s XHR calls actually contains the incorrect IP address (10-10-10-1.*.plex.direct instead of 10-20-20-1.*.plex.direct) even before resolving it.

I’m really confused here.

Why are you using *.plex.direct names?

Those are intended for internal use by PMS and its clients.

For normal users:

  1. FQDN
    -or-
  2. LAN/WAN IP address

If you have a local DNS resolver which resolves to IP addresses only, you can use that as well.

I’m not using the *.plex.direct name myself, but I can see that my browser uses it.

I’ve always just been using the official web client at plex.tv, and until now it has worked fine - if I was on the same network as Plex, it would use the local network using the private IP, and otherwise the external IP using the internet. Everything just worked, and I never had to input any IPs or do any manual network configuration.
But now, the local check always fails, so it only uses the external IP. The only way to stream media data using the private IP address is to enter it into my browser when accessing Plex. Otherwise, if I use Plex Web (app.plex.tv) while connected to a VPN for instance, the traffic would pass through that rather than the local network, even though my Plex server is right next to me.

The private IP is correct according to the “Remote Access” settings page, but Plex insists on providing the previous server’s IP to clients, even though that IP has never been in use on the current server.

Any suggestions?
I’m afraid my VPN provider will cancel my subscription some day, since I’m (needlessly) transferring hundreds of gigabytes of “local” traffic through them each month due to this issue. :slight_smile:
(The access-by-IP trick works on the computer, but most of my streaming is from my smart TV.)

I found the solution: Inside the server’s control panel, go to Settings → Network, locate the setting “Preferred network interface” and choose the network interface instead of “Any”.
Now it uses the correct internal IP even if I change it back to “Any”. :smiley:

I cannot rule out that I might have used this setting on my previous Plex server (whose config+data dirs got copied to the new one) to bind it to a specific network interface.
The old server’s NIC had a different name which doesn’t exist on this new server, so maybe Plex was actually configured to prefer a non-existing NIC, and simply showed “Any” because it couldn’t match the configured preferred NIC name to an actual device.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.