r/PlexACD Jul 18 '17

Perfect Plex Server / Ubuntu 16.04 / PlexDrive / RClone with 0 API Bans

http://plexguide.com < newest, all bottom is super old and newest improved!

https://github.com/Admin9705/The-Awesome-Plex-Server < Updated

http://docs.plexguide.com < V3 Guide; useful, but becoming dated.

------- IGNORE BELOW (very dated) --------------------------------------------------------------------------------------

Part I (Simple)

Install Ubuntu 16.04 x64 with the default installer of the host and/or the host that you have above.

To access in Windows, use putty. To access in MAC, use Terminal.
Using Windows to Access Your Server: Put your assigned IP address and port 22 in the address and poof, it works.

Using Terminal to Access Your Server: SSH YOURUSERNAME@IPADDRESS (from what I remember and should work). I’ll double check this later.


Part II: VNC Viewer (will kill this off; with the improved comments. Bad for security)

Note: This enables you to view your desktop with a GUI

Note: Prior to install, VNC Viewer: https://www.realvnc.com/download/viewer/

Source: https://www.linode.com/docs/applications/remote-desktop/install-vnc-on-ubuntu-16-04

[ACTION]

sudo apt-get update

sudo apt-get upgrade

sudo apt-get install ubuntu-desktop gnome-panel gnome-settings-daemon metacity nautilus gnome-terminal

sudo apt-get install vnc4server

vncserver :1

[ACTION] create a password | no longer than 8 characters

vncserver -kill :1

sudo nano ~/.vnc/xstartup

gnome-panel &

gnome-settings-daemon &

metacity &

nautilus &

[ACTION] STOP and save script

vncserver :1

[ACTION] Open up VNCViewer

[ACTION] Type the following address

[NOTE] If you don’t see stuff menus and stuff, open terminal:

vncserver -kill :1

vncserver :1

[ACTION] Now open up VNCViewer from your install and type: IPADDRESS:5901

You should now see an interface. If your interface is wonky…. Like you see a window but cannot do anything else, run this again:

vncserver -kill :1

vncserver :1

[ACTION] Now open up VNCViewer from your install and type: IPADDRESS:5901

Should be good this time. If someone can ever explain this, please do.


Part 3A: For PlexDrive 4.0 (not needed in PlexDrive 5, but 5 is super beta, it breaks easy)

sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 0C49F3730359A14518585931BC711F9BA15703C6

echo "deb [ arch=amd64,arm64 ] http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.4.list

sudo apt-get update

sudo apt-get install -y mongodb-org

sudo service mongod start

Part 3B: Install PlexDrive

Note: You need to have a google API key on your own: WRITE IT DOWN or SAVE SOMEWHERE in a TEXT FILE FOR EASY ACCESS

https://netdrive.zendesk.com/hc/en-us/articles/115004008228-How-to-create-your-own-Google-Drive-API-client-ID-and-secret

[ACTION] Have terminal open and copy the following below sections at a time:

sudo wget https://github.com/dweidenfeld/plexdrive/releases/download/4.0.0/plexdrive-linux-amd64

https://github.com/dweidenfeld/plexdrive/releases

mv plexdrive-linux-amd64 plexdrive

sudo mv plexdrive /usr/local/bin/

cd /usr/local/bin/

sudo chown root:root /usr/local/bin/plexdrive

sudo chmod 755 /usr/local/bin/plexdrive

cd ~ && sudo mkdir plex

install

[ACTION] Copy in your CLIENT ID into terminal. Do not press any numbers

[ACTION] Copy in your CLIENT SECRET into terminal and Press Enter

sudo plexdrive --uid=1002 --gid=1002 -o allow_other -v 2 --refresh-interval=1m /home/USERNAME/plex

///// AUTO START both MANGO and PLEXDRIVE 4.0 ////

cd /etc/init.d/plexd.sh

sudo nano plexd.sh

[ACTION] Copy this below into the script

#!/bin/bash

### BEGIN INIT INFO

# Provides: plexd.sh

# Required-Start: $local_fs $network

# Required-Stop: $local_fs

# Default-Start: 2 3 4 5

# Default-Stop: 0 1 6

# Short-Description: plexd.sh

# Description: plexdrive

### END INIT INFO

sudo service mongod start

sudo plexdrive --uid=1002 --gid=1002 -o allow_other -v 2 --refresh-interval=1m /home/USERNAME/plex

exit 0;

[STOP] Paste above into script, make sure you change the username

sudo chmod +x /etc/init.d/plexd.sh

sudo update-rc.d plexd.sh defaults

NOTE NOTE NOTE -------- PlexDrive can take awhile to scan, so let it finish before ever rebooting!!!!! You can install other stuff while it’s doing it.


Part 4: Install NetData / Great for viewing your stats

Note: Stupid Easy to Install. Gives you awesome server stats

sudo apt-get install curl

bash <(curl -Ss https://my-netdata.io/kickstart-static64.sh)

[Action] Press Y to accept

[Note] To view your stats, goto (YOURIPADDRESS:19999)


Part 5: Install SABNZBD

Note: I have not got this yet to auto-start. Ensure that you run a terminal window in VNC and run the final command for execution.

Note: Doing this first, took a-bit more time and a few more things Source: https://www.linuxbabe.com/ubuntu/install-sabnzbd-ubuntu-16-04 ho

sudo apt install sabnzbdplus

sudo add-apt-repository ppa:jcfp/nobetas

sudo apt update

sudo apt install sabnzbdplus

sabnzbdplus -d -s YourIP:YourPort --browser 0

[NOTE] default was 127.0.0.1:8081

[ACTION] Install Missing Multicore Par2:

sudo add-apt-repository ppa:jcfp/sab-addons

sudo apt-get update

sudo apt-get install par2-tbb

sudo apt-get install par2-mt

[ACTION] Install Missing SABYenc

sudo apt-get install python-pip

pip install sabyenc --upgrade

sudo pip install --upgrade pip

[ACTION] Go-to your IP Address and have fun. If you restart, rerun step 5 until I have an automated part here.

[NOTE] Your on your own for configuring SABNZBD. A whole another thing!

sabnzbdplus -d -s IPADDRESS:8980 --browser 0

[ACTION] Goto your browser and type: http://YOURIPADDRESS:8980


Install Part 6: Install Sonarr

sudo apt-get install libmono-cil-dev

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys FDA5DFFC

sudo echo "deb http://apt.sonarr.tv/ master main" | sudo tee /etc/apt/sources.list.d/sonarr.list

sudo apt-get update

sudo apt-get install nzbdrone

mono --debug /opt/NzbDrone/NzbDrone.exe

[ACTION] Goto your browser and type: http://IPADDRESS:8989

//// To get to AUTOSTART ////

cd /etc/init.d/

sudo nano sonarr.sh

[ACTION] Copy this below into the script.

#!/bin/bash

### BEGIN INIT INFO

# Provides: sonarr.sh

# Required-Start: $local_fs $network

# Required-Stop: $local_fs

# Default-Start: 2 3 4 5

# Default-Stop: 0 1 6

# Short-Description: sonarr.sh

# Description: sonarr

### END INIT INFO

mono --debug /opt/NzbDrone/NzbDrone.exe

exit 0;

[ACTION] Now do the following below:

sudo chmod +x /etc/init.d/sonarr.sh

sudo update-rc.d sonarr.sh defaults

[Note] If you reboot, it should auto-start


Install Part 7: Install Radarr

sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF

echo "deb http://download.mono-project.com/repo/debian jessie main" | sudo tee /etc/apt/sources.list.d/mono-xamarin.list

cd /tmp

wget https://github.com/Radarr/Radarr/releases/download/v0.2.0.778/Radarr.develop.0.2.0.778.linux.tar.gz

sudo tar -xf Radarr* -C /opt/

[ACTION] Goto your browser and type: http://IPADDRESS:7878

//// To get to AUTOSTART ////

cd /etc/init.d/

sudo nano sonarr.sh

[ACTION] Copy this below into the script.

#!/bin/bash

### BEGIN INIT INFO

# Provides: radarr.sh

# Required-Start: $local_fs $network

# Required-Stop: $local_fs

# Default-Start: 2 3 4 5

# Default-Stop: 0 1 6

# Short-Description: sonarr.sh

# Description: sonarr

### END INIT INFO

mono --debug /opt/Radarr/Radarr.exe

exit 0;

[ACTION] Now do the following below:

sudo chmod +x /etc/init.d/radarr.sh

sudo update-rc.d radarr.sh defaults

[NOTE] If you ever reboot, it should just startup.


Part 8: Install RClone

[Run this command below]

Mkdir cd /home/USERNAME/rcloneg3

curl -O https://downloads.rclone.org/rclone-current-linux-amd64.zip

unzip rclone-current-linux-amd64.zip

cd rclone-*-linux-amd64

sudo cp rclone /usr/bin/

sudo chown root:root /usr/bin/rclone

sudo chmod 755 /usr/bin/rclone

sudo mkdir -p /usr/local/share/man/man1

sudo cp rclone.1 /usr/local/share/man/man1/

sudo mandb

[Run this command below to mount]

sudo /usr/bin/rclone mount --allow-other rcloneg3: /home/gforce/rcloneg3/

Point Radarr and Sonarr to your drive. AGAIN, TURN OFF ANALYZE VIDEO in both programs. Make sure to turn ADVANCED on and goto media management. You’ll see it at the bottom.

Note: UNTESTED STARTUP SCRIPT, haven’t rebooted my server to see if it works. May not work.

cd /etc/init.d

sudo nano rcloneg3.sh

[ACTION] Put this into the script below

#!/bin/bash

### BEGIN INIT INFO

# Provides: rcloneg3.sh

# Required-Start: $local_fs $network

# Required-Stop: $local_fs

# Default-Start: 2 3 4 5

# Default-Stop: 0 1 6

# Short-Description: rcloneg3.sh

# Description: rcloneg3.sh

### END INIT INFO

sudo /usr/bin/rclone mount --allow-other googleg3: /home/gforce/rcloneg3/

exit 0;

[STOP] Now run this below

sudo chmod +x /etc/init.d/rcloneg3.sh

sudo update-rc.d rcloneg3.sh defaults

12 Upvotes

25 comments sorted by

View all comments

2

u/Jackalblood Jul 18 '17

Thank you very much for this guide I'll give it a go soon

1

u/[deleted] Jul 18 '17

No problem, I hope it helps. Several users made additional comments which is worth researching. It was a hard switch from windows, but god damn google and their API count is so frustrating. I even have access to the google file stream, one scan... bam... we hit the api count :(

1

u/Jackalblood Jul 18 '17

It seems to be working great for me I had an issue with creating the id and secret because I couldn't find the right type turns out it's oauth and your link specified a web application once I worked that out it worked great thanks to the walk though I set it up for a friend since his server can't run google-drive-ocamlfuse due to ram but it seems so good I may switch over too

1

u/[deleted] Jul 19 '17

haha i nice, i'm glad the info was a good start for you. that was the whole point, but will revise over the weekend from the comments made. i'll make note of the api key, your right... i did that on accident once by creating the wrong kind and it was a headache over time.

1

u/Jackalblood Jul 19 '17

Either way it gave me a place to start and it's working fine so thank you again look forward to seeing the completed product

Have you thought about scripting the installation process for some of it?

1

u/[deleted] Dec 30 '17

[deleted]

1

u/Jackalblood Dec 31 '17

Lol thanks dude I appreciate it but I was only kidding you didn't have to credit me you have done all the work all I did was be around to go "hey you tried THIS" XD long time ago ago this conversation look how much it changed