Plex Media Server on AsusWRT Arm Routers

Works only on arm routers like RT-AC56U, RT-AC68U, RT-AC87U, RT-AC3200, RT-AC5300...

No transcoding capabilities, just direct play on supported devices, like LG, Samsung TVs, Plex Android App...

Tested on RT-AC68U rev A2, RMerlin firmware v380.57, hdd usb3, Optware-NG & Entware-NG
Latest working version is 0.9.16.6, Plex no longer support ARMv5 used in this tutorial, please don't ask here for updates.

1 - Flash Rmerlin firmware from here

2a - Install Optware-NG from here and choose 2GB swap file

Install necessary packages

ipkg install nano findutils

or

2b - Install Entware-NG from here and choose 2GB swap file

Install necessary packages

opkg install nano findutils

3 - Setup Debian Jessie from here

4 - Enter chrooted debian with:

debian enter

5 - Update Debian

apt update && apt upgrade -y

6 - Install necessary packages

apt install wget zip bzip2 libexpat1 -y

- Download and install Plex Media Server

mkdir -p /apps && cd /apps
wget -c -O PlexMediaServer-0.9.16.6.1993-5089475.tar.bz2 http://goo.gl/ZzmVmO
bzip2 -cd PlexMediaServer-0.9.16.6.1993-5089475.tar.bz2 | tar -xv
mv ./PlexMediaServer-0.9.16.6.1993-5089475 ./plex && rm ./PlexMediaServer-0.9.16.6.1993-5089475.tar.bz2

- Fix library path and start script

sed -i 's|ulimit.*|export PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/var/lib/plexmediaserver"\n&|g' /apps/plex/start.sh
sed -i 's|.\/Plex\\ Media\\ Server|\/apps\/plex\/Plex\\ Media\\ Server|g' "/apps/plex/start.sh"

- Fix permissions of lib files

cd /apps/plex
find . -iname "*.so" -exec chmod 644 {} \;
find . -iname "*.so.*" -exec chmod 644 {} \;

10 - Create startup script

cat >> /etc/init.d/plexmediaserver << 'EOF'
#!/bin/sh
### BEGIN INIT INFO
# Provides: plexmediaserver
# Required-Start: $remote_fs $syslog $networking
# Required-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Plex Media Server
# Description: Plex Media Server for Linux,
# More information at http://www.plexapp.com
# Many thanks to the great PlexApp team for their wonderfull job !
# Author: Cedric Quillevere / origin@killy.net
# Rewamped Christian Svedin / christian.svedin@gmail.com
# Adapted by TeHashX / contact@hqt.ro
# Version: 1.3
### END INIT INFO
test -f "/apps/plex/start.sh" || exit 0
plex_running=`ps ax | grep "Plex Media Server" | awk '{ print $1 }' | wc -l`
case "$1" in
start)
if [ "$plex_running" -gt 1 ]; then
echo "Plex already running..."
exit 0
fi
echo -n "Starting Plex Media Server: "
/apps/plex/start.sh & >/dev/null 2>&1
sleep 1
echo "done"
;;
stop)
if [ "$plex_running" -eq 1 ]; then
echo "Plex Media Server is not running (no process found)..."
exit 0
fi
echo -n "Killing Plex Media Server: "
# Trying to kill the Plex Media Server itself but also the Plug-ins
ps ax | grep "Plex Media Server" | awk '{ print $1 }' | xargs kill >/dev/null 2>&1
ps ax | grep "Plex*" | awk '{ print $1 }' | xargs kill >/dev/null 2>&1
sleep 1
echo "done"
;;
restart)
sh $0 stop
sh $0 start
;;
status)
if [ "$plex_running" -gt 1 ]; then
echo "Plex Media Server process running."
else
echo "It seems that Plex Media Server isn't running (no process found)."
fi
;;
*)
echo "Usage: $0 {start|stop|restart|status}"
exit 1
;;
esac
exit 0
EOF

Press ENTER

11 - Give right permission

chmod +x /etc/init.d/plexmediaserver

12 - Exit Debian

exit

13 - Add Plex to chrooted services list

echo "" >>/opt/etc/chroot-services.list
echo "plexmediaserver" >>/opt/etc/chroot-services.list
chmod 755 /opt/etc/chroot-services.list

14 - Start Plex from outside debian together with mounted external folder

debian restart

15 - Wait about 30 seconds then go to default router ip address and port :32400/web, like 192.168.1.1:32400/web or www.asusrouter.com:32400/web

plex-1

16 - Create a new library and point to /mnt as path, if you want to mount a samba share use this guide
plex-path
Enjoy...

To be continued with the rest of setup if requested by user...

 

How to Install the Plex Unsupported App Store

Enter chrooted debian

debian enter

Download and unzip unsupported app store

cd /apps/plex/Resources/Plug-ins*
wget -c -O UnSupportedAppstore.bundle.zip goo.gl/ywJ3cZ
unzip UnSupportedAppstore.bundle.zip && rm UnSupportedAppstore.bundle.zip

Go to Plex webpage, click on Channels and install apps...

plex-unsupported-app-store
Sources: htpcguides.com, linksysinfo.org

  • Racerx NunyaBussiness

    what about connecting a wintv-dualhd usb tuner for local channels? anybody get this to work?

    • I don't think is possible to add an usb tuner to router.

    • Crustnut

      Maybe consider something like an Nvidia sheild tv. Much much more grunt and capable of transcoding among other Plexy things.

      • TeHashX

        Or, RPI, Odroid...
        They are cheaper than a router

      • Racerx NunyaBussiness

        i really dont want to buy any hardware. I was considering (2) hd homerun. which would be 4 tuners. Everything would of worked its a software thing with plex and right now it isnt worth my money if it isnt going to do what it SHOULD do

  • Jayakumar D

    Everything works just fine ..some file dont play as expected ..but is thr any way around to fix? cuz my client device is fully capable to play any file

    Didt see any success with unsupported apps

  • JustSomeRandomDDWRT

    Hi TeHashX - I've got a new R9000 that I want to put DD-WRT on, but unfortuantely, DD-WRT doesn't support PLEX. There is an available (and pretty sweet if I may add) R9000 firmware available - Kong MOD, but again.... no Plex support. The native R9000 firmware allows the Plex installation to do transcoding as well. Will your steps listed above (minus the asus firmware you list above) work? I'm having difficulty finding anything custom for the R9000.

    • Do you still have original firmware on your router? Copy plex package and I will try to make it work.

      • JustSomeRandomDDWRT

        I posted a lengthy reply to this, but apparently it's being approved? For some reason it's not showing up here.

        • Your previous message was flagged as spam and because contain links.
          Can you post another link for ftp://updates1.netgear.com?

          • JustSomeRandomDDWRT

            Try this one: http://bit.ly/2x4ve1a

            just stick an http in front of it.... bit.ly/2x4ve1a

          • TeHashX

            Can you install entware or optware on dd-wrt firmware? If yes, then try to install chrooted debian.

          • JustSomeRandomDDWRT

            Entware-ng for sure I can install on dd-wrt firmware. A Chrooted debian instance I'm not entirely sure. I did some google searching, and couldn't exactly find an article / tutorial on installing a chrooted debian instance. I've asked in the R9000 thread on the DD-WRT pages if anyone is familiar with this.

Get Email Notification When a Server or Port is Unreachable
SoftEther VPN Running on AsusWRT Routers
Minidlna UPnP Media Server through Debian Jessie Arm
How to Mount Samba Shares inside Chrooted Debian
Minidlna UPnP Media Server through Debian Jessie Arm
How to Mount Samba Shares inside Chrooted Debian
Spreed WebRTC server and web client
Asterisk VoIP Server running on AsusWRT Routers
Get Email Notification When a Server or Port is Unreachable
SoftEther VPN Running on AsusWRT Routers
NZBGet through Entware
Minidlna UPnP Media Server through Debian Jessie Arm

SUBSCRIBE

To be notified by email when a new tutorial is posted :)

Thanks for Subscribing! I'll keeping you up-to-date with latest tutorials!

Something went wrong, try again...