Use Separate WireGuard Interfaces or Profiles

Use Separate 스포츠중계 WireGuard Interfaces or Profiles

If you're using your PiVPN for multiple tasks (e.g., Plex + SSH + web access), you can:

  • Create multiple WireGuard profiles with different purposes

  • Example:

    • plex-only.conf: Routes only Plex-related IPs and ports

    • full-tunnel.conf: Routes all traffic through VPN

In your plex-only.conf:

 

ini

복사편집

AllowedIPs = 192.168.1.50/32

This will only route traffic to your Plex server (e.g., 192.168.1.50), leaving all other traffic outside the tunnel for speed.

???? Benefit: Reduces load on your VPN and gives Plex the full pipeline.


✅ 2. Enable Quality of Service (QoS) on Your Router

Most modern routers offer QoS settings that let you prioritize traffic based on:

  • Port number

  • IP address

  • Device (MAC address)

Example:

  • Plex typically uses port 32400

  • Your Plex server might be at 192.168.1.50

  • In your router QoS settings:

    • Set high priority for:

      • Outbound traffic on port 32400

      • Device IP: 192.168.1.50

      • Service: WireGuard (UDP port 51820)

This ensures your router allocates top-tier bandwidth to Plex sessions, even if others are uploading or gaming.


✅ 3. Use Policy-Based Routing or Split Tunneling

If your VPN server is running on a Linux machine or router, use iptables or ip rule to:

  • Route Plex-bound traffic (e.g., Plex clients or Plex IP) through a dedicated interface

  • Deprioritize other VPN routes or leave them out of the tunnel

Example:

 

bash

복사편집

ip rule add from 192.168.1.100/32 table 200 ip route add default via 10.6.0.1 dev wg0 table 200

  • This will route only traffic from your Plex client (e.g., your mobile device abroad) through the VPN


✅ 4. Optimize 스포츠중계 MTU for Plex Traffic

MTU (Maximum Transmission Unit) mismatch causes latency spikes and buffering.

  • On WireGuard config:

     

    ini

    복사편집

    MTU = 1420

  • You can experiment with 1400–1420 to see what performs best for your connection

Test using: ping -M do -s 1472 [your home IP] and subtract 28 bytes.


✅ 5. Monitor Real-Time Traffic and Logs

Use tools like:

  • iftop / nload / vnstat on the VPN server

  • Plex Dashboard to confirm Direct Play or Transcoding

  • htop or btop to check CPU load and bandwidth usage

See if Plex traffic spikes are being affected by other processes like SSH, FTP, or backups.


???? Bonus Strategy: Run PiVPN and Plex on Separate Devices

  • Host PiVPN on a Raspberry Pi or router

  • Run Plex on a separate PC or NAS

  • This isolates load and avoids port conflicts or resource hogging


???? Recap: Ways to Prioritize Plex Over VPN

Method Priority Boost? Complexity
Split VPN profile (AllowedIPs) ✅✅✅ Easy
Router QoS ✅✅ Moderate
iptables / policy routing ✅✅✅ Advanced
Dedicated devices ✅✅ Moderate
MTU tuning Easy
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

Comments on “Use Separate WireGuard Interfaces or Profiles”

Leave a Reply

Gravatar