Tag Archives: Linux Mint

Create a self contained Media Server

Been a while since I’ve updated the guides on here, so here go’s, how to install the Required components onto a Linux Mint 17 machine.

First, obviously download the Linux Mint disk, I use the 64bit Mate version, but if you are more a fan of Cinnamon then that’s upto you.

Once the basic install of Mint is complete (Just your standard next/next, through the install). Login to the server, bring up Terminal

sudo apt-get update
sudo apt-get install guake
sudo apt-get upgrade
sudo apt-get dist-upgrade

That will get Mint upto the latest version of everything in it’s base install. After all that’s complete just reboot the machine/VM.

Setup for the Services

First off, we need Samba installed (probably, if you don’t then skip this section, but if you have a Windows machine on the network, it’s worth doing).

sudo apt-get install samba

That will get Samba basics installed. How much we setup depends, for now though we are going to leave it as it is (most of the time it’s already installed)

Plex Server

Pop along to the Plex Download Page and download the Ubuntu 64bit release. This get’s downloaded as a Debian Package (deb) file, and by default will be in the ~/Downloads folder. So to install this we need to use DPKG, so from the Terminal

sudo dpkg -i ~/Downloads/plexmediaserver????.deb

That should install the server on the local machine, to test bring up a browser and goto http://127.0.0.1:32400/web After agreeing to the license you should get a nice empty server display.

Sick Beard

Next up, automating TV Downloads. For this we will be using Sick Beard, so let’s do that.

First let’s make sure you have an up to date version of Python installed. To do this from Terminal

python -V

Make sure it comes back with 2.5 or later (Mint 17.1 should be 2.7.6), next up we need Cheetah installed, this is easy from Terminal type

 sudo apt-get install python-cheetah

That will get Cheetah installed, now we need to get the Sick Beard source down and compile it. So from the Terminal (I’ve used the HTTP git source of the repo, because of possible proxy issues, but if you have issues, use git:// instead of http://)

cd ~
git clone http://github.com/midgetspy/Sick-Beard.git .sickbeard

That will put the application in the .sickbeard folder ‘hidden’ in your home folder, cd into it (cd ~/.sickbeard) to continue setup. Then

cp -a autoProcessTV/autoProcessTV.cfg.sample autoProcessTV/autoProcessTV.cfg

python ~/.sickbeard/SickBeard.py -q

Then goto http://127.0.0.1:8081 from your local browser to make sure it’s up and running.

Next, we need to automate it so we don’t have to do that everytime.

sudo cp ~/.sickbeard/init.ubuntu /etc/init.d/sickbeard
sudo chmod +x /etc/init.d/sickbeard
sudo nano /etc/default/sickbeard

When nano opens up, you need the following 3 lines in it, obviously changing the relevant sections so they are correct for your install (basically the username part in /home/??? and SB_USER)

SB_HOME=/home/user/.sickbeard/
SB_DATA=/home/user/.sickbeard/
SB_USER=user

Then we need to add the correct bit’s to make sure it all starts at boot time.

sudo chmod +x /etc/default/sickbeard
sudo update-rc.d sickbeard defaults

That should be it, just give the box a reboot now, to make sure. After the machine comes back up, got http://127.0.0.1:32400/web and http://127.0.0.1:8081 and make sure both services we have already installed are up and running.

CouchPotato

Next we need to install Couch Potato,  the easiest way to do this is to clone it via Git, that’s easy enough to do.

cd ~
git clone git://github.com/RuudBurger/CouchPotatoServer.git .couchpotato

That will grab the latest code, and pop it into the ‘hidden’ folder .couchpotato

Next we need to set it up to auto start, so

cd ~/.couchpotato/init
sudo cp ~/.couchpotato/init/ubuntu /etc/init.d/couchpotato
sudo chmod +x /etc/init.d/couchpotato
sudo nano ~/.couchpotato/init/ubuntu.default

That will start nano editor up, and we need to put the relevant information on the home directory and the user in here, mine looks like this

# COPY THIS FILE TO /etc/default/couchpotato
# OPTIONS: CP_HOME, CP_USER, CP_DATA, CP_PIDFILE, PYTHON_BIN, CP_OPTS, SSD_OPTS

CP_HOME=/home/media/.couchpotato
CP_DATA=/home/media/.couchpotato
CP_USER=media
CP_PIDFILE=/home/media/.couchpotato/couchpotato.pid

So just make sure the path’s and user name is correct, and copy the above, then lets add all this to the init.d

sudo cp ~/.couchpotato/init/ubuntu.default /etc/default/couchpotato
sudo chmod +x /etc/default/couchpotato
sudo update-rc.d couchpotato defaults

and now you should be able to use sudo /etc/init.d/couchpotato start/stop  to start and stop the process. So go ahead and start it. Then make sure you can get to http://127.0.0.1:5050, it should launch the wizard to finish the configuration off. Just put a username and password in, and untick the launch browser box. I also change the port to 8082 as it’s easier to remember as next up from Sick Beard and what we are installing next (the download glue)

SabNzb

sudo add-apt-repository ppa:jcfp/ppa
sudo apt-get update

That will add the right repository, and update everything so we can then just go

sudo apt-get install par2
sudo apt-get install sabnzbdplus
sudo apt-get install sabnzbdplus-theme-mobile

All the dependencies that are needed will be listed, then just Say and away you go.

Now let’s get it setup so it automatically starts at boot, that’s done pretty much the same way we have done the others so far, so

sudo nano /etc/default/sabnzbdplus

and we need to edit a couple of variables in there, the USER= one should be your mint username, and HOST= should be 0.0.0.0 and I set the PORT= to be 8080 as then all the apps we have just installed are nicely concatenated together in a port range.

Save the file out, and sudo service sabnzbdplus restart 

Launch a browser on http://127.0.0.1:8080 and go through the initial setup (news server etc).

Next up is configuring it all. So that in my next post.