Setting up an UnRaid Server - Step by Step from a newbies standpoint
#1
First off.. anyone feel free to correct me if anything looks wrong here..
These instructions are by no means written by me. I have muddled through the forums (Unraid and here on XBMC) to get this information. I cut and pasted, for my own notes, the work of others to get my system going. Im new to this myself and if its not included in this, I probably don’t know the answer. There is a lot of information on the unRaid forums and the official and unofficial wiki and specific information on UnRaid and XBMC in these forums.. read, read, read. I just wanted to get my setup notes written down in one place before I forgot and figured I would share. These instructions are assuming you have a monitor and keyboard hooked up to the unRaid server initially (no mouse needed), that you have the bios set to allow booting from the USB flash drive, that you are only using SATA drives and that the bios is set to NOT EMMULATE ide ports, Im using windows 7 on my main computer. These instructions may differ a little if youre not. For some great builds with parts lists check out this link http://forum.xbmc.org/showthread.php?tid=104489

1st download these following files
The latest unraid server (version 5 in in the late stages of an official final release, Its been around and is still in the ‘testing’ phase, use at your own risk, version 4.7 is the latest official release.. I used 5 release candidate 3)
The Latest preclear – at bottom of 1st post
The Latest unMenu

Using your regular computer, Quick format flash drive to FAT with name
UNRAID
it should be six capital characters

Copy contents of latest unraid server zip file to flash drive, make sure the folder structure is preserved during the unzipping.

Open contents of flash drive, right-click and choose to ‘run as administrator’ on ‘make_bootable’ file.

From the preclear zip, copy the file ‘preclear_disk.sh’ to the root of flash drive (the same directory as bzimage and bzroot)

Create an unmenu folder in root of flash drive

From the unmenu zip, copy ‘unmenu_install’ to the unmenu folder

Eject flash drive by right clicking and selecting ‘eject’
Plug flash drive into server and boot into unRAID

Login as root by typing
root
at the prompt

Check networking by typing
ifconfig eth0
If there is a good ip address then networking is working. While its visible, make a note of the ip address.

Test to see if unraid is seeing your hard drives by typing:
dmesg|grep SATA|grep link
the vertical line is under the backspace key and looks like a colon but with lines instead of dots

Go to any computer on your network and open up a web browser type
//tower
if that doesn’t pull up the unRaid GUI interface, then try the ip address of the unraid box. Get a little familiar with the interface.. but don’t select disks yet.

Install UnMenu from console (the raid box) – UnMenu is an addon, that adds to the stock unraid interface. Its not 100% necessary, but I can see how it will be usefull.
cd /boot/unmenu
unmenu_install -i -d /boot/unmenu
./uu
echo "/boot/unmenu/uu" >> /boot/config/go


After you type these commands go to your regular computer or any computer on your network and type
//tower:8080
to get to the interface. Look around and get familiar with UnMenu its pretty neat..

Now for the Drives.. Pre-clearing is not necessary, but is highly recommended by most in the community. It writes zeroes to the drive and puts it through a series of tests, depending on the size of your drive it can take 20+ hours to preclear. The good news is that you can do several drives concurrently. You can read more about preclearing here http://lime-technology.com/forum/index.php?topic=2817.0

Preclear drives (on Console)
Before I added my drives to the case, I used a labelmaker to label the exact model number of the drive and the last 4 digits of the serial number. The info is on the factory label on top of the drives but is unreadable when mounted.
Log in as root
cd /boot
preclear_disk.sh –l

that’s the lowercase letter “L” not the number ‘1’and there is also a space before the minus sign

This will return all drives available for pre-clearing. Make a note of which ones say “sda or sdb or sdanything beside them.. this is how you will tell preclear which one to clear. If any say hda hdb or hdanything, and you don’t have any IDE drives installed, we need to go back into the bios and make sure your sata is set to ACHI mode and make sure its not emulating an ide port.
Now that you have identified the drive you want to preclear, check again.. just so you’re absolutely positive you are on the right drive.
preclear_disk.sh /dev/sdx
replace the sdx with whatever drive you want to preclear (sda or sdb or sdwhatever) You will be prompted and have to enter “Yes” to start the process
If you have several disks to do, hit
alt-f2
to open up a new console, log in as root and run the preclear script again, but on the other drive. You can choose alt-f3 and do it again if need be (up to 4 concurrently)

After 20 something hours, and the Pre-clears are done, CTRL-D out of each Vterm,

Now we will add drives to array (from another computer) go to your web browser and type
//tower
Go to devices
Leave parity blank for now
drop down next to disk1 and select disk to assign
drop down next to disk2 and select disk to assign
click Main -> Start Array
Click Format, since we precleared the drives, this should only take a minute or two.

Create User Shares (from another computer) - Decide how you want them split, but this is how mine are.. Short and sweet explaination is that with a split level of 2, the upper 2 levels of folders will get put on drives assigned by UnRaid, anything below the first 2 levels will get grouped together. I have a share called media with folders called Movies, Series, Ebooks, and Music. Now under the movies folder I have folders named by the title of the movie which contain fanart, metadata, the movie, other folders related to the movie, etc.. With a split level of 2, my folders named after the name of the movies may be on different drives, but all folders below that will be grouped together. So superman may be on a different drive than Forrest Gump, the the files and folders associated with superman will remain with the movie, as will Forrest Gumps will remain with it. On your computer you will not see individual drives (unless you want to) you will see one big drive that will appear to have superman and Forrest Gump on, but in reality, they could possibly be on different physical drives.

Main -> Stop array
Shares -> Enable User Shares -> apply
Main -> Start array
Shares -> edit shares properties

I used SMB shares

Now that you have the array started with drives that have passed the test, you have a decision to make. You can copy your existing data to the array without a parity disk assigned, or you can assign one first. If you copy large amounts of data with a parity assigned, it will take significantly longer, but you will be protected if a drive fails. The happy medium that I did (you may feel diifferent with your data) was to copy my data to the array with terracopy, and only after I was confident did I delete my data from my original drive. Its up to you, this method worked for me. I understand that I wasn’t protected from a drive failure during that window, but since I copied the files, I always had a backup.

stop array, add parity drive, parity-sync will start, start array.

when parity sync is complete run manual parity check.

I haven’t set up a cache drive yet or sickbeard/couchpotato/sab, but plan on it.. Here is an excellent link outlining the benefits of using one
http://lime-technology.com/forum/index.php?topic=5754.0
Use this: http://lime-technology.com/forum/index.p...ic=14760.0 for getting Sab, SB & CP up and running. And you can get the updated packages here https://github.com/Influencer/UNplugged
I set to share my flash drive too so I wouldn’t have to keep adding and removing to to put files on it. Also until you get it up and running flawless, make a copy of your syslog found on your drive after every shutdown. It can help the community help you figure out whats happening if you run into a problem. This syslog is written over at each shutdown. So if you don’t save a copy, it will get written over each time.
also, dont just power off your console, there is a shutdown button from within //tower to safely shut it down
or from the command prompt of the console type
shutdown -P now <-- the letter p has to be capitalized
You can pretty much remove the monitor and keyboard and ‘tuck’ your new server in the corner next to your router. Once powered back up it should start without any user input needed.

In XBMC I just added a source called
smb://tower/media/movies and one called
smb://tower/media/series
and everything is working like a champ!

I also mapped the share to a drive letter on my windows machine.
Good luck.. Read, read, read..
Reply
#2
Good write up.

I am not a fan of a cache drive. I like not worrying about parity protection and "is it safe?"

I am also not a big fan on sick/sab/couch/headphones/MySQL on an Unraid box either. I much prefer running those programs from my primary HTPC. Why?

-Easier to update sab in Ubuntu/Windows
-Post-processing can eat a CPU and most of the time when using GPU decoding your HTPC doesn't need that CPU
-MySQL can eat RAM like no ones business and otherwise Unraid doesn't need a lot of RAM (is wasteful)
-Allows me to keep the stock Unraid software for maximum support
-If I screw up configuration or something goes wrong I feel better blowing away an XBMCbuntu install than my Unraid OS

Even a weak ION box can do the job really and it lets you build a leaner Unraid system. The only major downside is that my main HTPC has to be on for other clients to work, but it runs 24/7.

One last note on the MySQL/RAM thing- if you have a very large library (Unraid tends to help with that) throw 4GB in your MySQL box and change the Query Cache Configuration for best results. Change it to:

Quote:query_cache_limit = 2M
query_cache_size = 32M

Reply
#3
Will do.. I havent set up MySql yet either. Im taking this in baby steps impleminting what I want in stages. I did over power it a little (a6/3500 4g ram) with hopes for the apps like sb/cp/sab, Ill see how it goes from here Smile
Reply
#4
(2012-06-01, 03:41)poofyhairguy Wrote: I am also not a big fan on sick/sab/couch/headphones/MySQL on an Unraid box either. I much prefer running those programs from my primary HTPC.

Going to have to disagree with that. Running sab/SB/CP on my unRAID box has made my HTPC (Acer Revo 1600) infinitely more stable.
Reply
#5
(2012-06-01, 04:48)spencers Wrote:
(2012-06-01, 03:41)poofyhairguy Wrote: I am also not a big fan on sick/sab/couch/headphones/MySQL on an Unraid box either. I much prefer running those programs from my primary HTPC.

Going to have to disagree with that. Running sab/SB/CP on my unRAID box has made my HTPC (Acer Revo 1600) infinitely more stable.

Hmmmm. Ok I will take my earlier statement back- I guess an ION box can't do it. My current machine that does that stuff is an ancient AMD x2 (the lowest end model when they first came out) so it can't take that much power in general though.

Reply
#6
(2012-06-01, 05:11)poofyhairguy Wrote:
(2012-06-01, 04:48)spencers Wrote:
(2012-06-01, 03:41)poofyhairguy Wrote: I am also not a big fan on sick/sab/couch/headphones/MySQL on an Unraid box either. I much prefer running those programs from my primary HTPC.

Going to have to disagree with that. Running sab/SB/CP on my unRAID box has made my HTPC (Acer Revo 1600) infinitely more stable.

Hmmmm. Ok I will take my earlier statement back- I guess an ION box can't do it. My current machine that does that stuff is an ancient AMD x2 (the lowest end model when they first came out) so it can't take that much power in general though.

I think maybe spencers meant that the Revo would buffer and choke while sab did unrars, and sb and cp did their post processing scripts. I know my Revo 3610 would do that. Another problem is that a lot of people put small (30-60gb) SSDs in their HTPC, which means the temp download folder could fill up and cause errors. This would also happen on my Revo.

I thought that building a faster HTPC might solve the buffering issue, but it hasn't. So I just schedule sab to only work in the middle of the night.

I think you have scared me from trying to install those apps on my unraid box, though, Poof. I would hate to screw it up and lose all that data.
My Living Room Theater XBMC Mini-ITX Build
CASE: MI-100 - MOBO: ASRock A75M-ITX - APU: A6-3500
Kingston 4GB 1600MHz - SanDisk 128GB SSD -- DVDRW
W7 HP - Kodi 15 - Confluence | ATV1 w/BCM970015 & Crystalbuntu in the BR
Reply
#7
You won't lose the data. It is not that hard to reinstall Unraid.

Yeah I guess post-processing is too much for an ION.

Reply
#8
(2012-06-01, 05:33)maddog808 Wrote:
(2012-06-01, 05:11)poofyhairguy Wrote:
(2012-06-01, 04:48)spencers Wrote: Going to have to disagree with that. Running sab/SB/CP on my unRAID box has made my HTPC (Acer Revo 1600) infinitely more stable.

Hmmmm. Ok I will take my earlier statement back- I guess an ION box can't do it. My current machine that does that stuff is an ancient AMD x2 (the lowest end model when they first came out) so it can't take that much power in general though.

I think maybe spencers meant that the Revo would buffer and choke while sab did unrars, and sb and cp did their post processing scripts. I know my Revo 3610 would do that. Another problem is that a lot of people put small (30-60gb) SSDs in their HTPC, which means the temp download folder could fill up and cause errors. This would also happen on my Revo.

I thought that building a faster HTPC might solve the buffering issue, but it hasn't. So I just schedule sab to only work in the middle of the night.

I think you have scared me from trying to install those apps on my unraid box, though, Poof. I would hate to screw it up and lose all that data.

Eh, it caused instability across the board. It didn't matter if SAB was unRAR-ing or doing any post-processing scripts. I'd get random reboots in the middle of watching a movie, or the movie would just cut out. On occasion, I'd wake up or come home to one of the three (SAB/SB/CP) dead as a doornail, causing me to launch terminal to boot the app again. That was with XBMCbuntu. Moving to Openelec was only marginally more stable.

After moving all those processes to unRAID, I have had no problems at all with my Revo 1600. My unRAID box was up to 50 days uptime (before having to move houses), and SAB/SB/CP have never crashed.

You won't screw anything up or lose any data by having them running on your unRAID box. Just back up your unRAID USB stick every now-and-then, and you'll be fine. Smile
Reply
#9
Unless you have 3 systems..... dedicated unRAID box... dedicated HTPC..... and then Office PC witch does all the work.
Reply
#10
Great write up.

Please make this a sticky.
Reply
#11
Thanks for the writeup. Couple of questions thou.

#1 How do you remote into an unraid box to run it headless?

#2 Do you have to have the paid version to run SAB/SB/CP? Every time I try to install them, even from unmenu, it fails :/
XBMC specs: MINIX U9-H LibreELEC 4K all day

Home Theater - Samsung 65KS8000 - Denon 3200- Ascend Acoustics speakers - Maelstrom 18in sealed sub 7cu ft - Behringer EP2500

UNraid Server – Pentium G3258 – MSI - H81M-P33 – Antec HCG-400M PS - 8Gb RAM
Reply
#12
#1 - ssh for example (ssh tunnel to remote login to the http based menu)
#2 - no you can run it on the free version
Reply
#13
After sleeping on it I think I figured out why putting those things on a client works for me on a weak machine, but not for others.

Whatever machine I have had doing those jobs for more than a year now gets a HD for incoming downloads (completed downloads are moved to my Unraid servers). I do this because too often downloads will fail and can fill a small drive- with a 500GB HD whole seasons of shows can fail (and they do) and I am not in trouble.

As a side effect (I have never considered before) I am not throttling my SSD during post processing which would happen if I only had one drive. Saturated I/O would lead to buffering and stuttering on the XBMC interface.



Reply
#14
(2012-06-01, 17:28)Steini Wrote: #1 - ssh for example (ssh tunnel to remote login to the http based menu)
#2 - no you can run it on the free version

How do you ssh?.. nevermind I just figured out how to telnet in Smile

I wonder why I can't install them.. strange.
XBMC specs: MINIX U9-H LibreELEC 4K all day

Home Theater - Samsung 65KS8000 - Denon 3200- Ascend Acoustics speakers - Maelstrom 18in sealed sub 7cu ft - Behringer EP2500

UNraid Server – Pentium G3258 – MSI - H81M-P33 – Antec HCG-400M PS - 8Gb RAM
Reply
#15
(2012-06-01, 18:48)joe_sun Wrote:
(2012-06-01, 17:28)Steini Wrote: #1 - ssh for example (ssh tunnel to remote login to the http based menu)
#2 - no you can run it on the free version

How do you ssh?.. nevermind I just figured out how to telnet in Smile

I wonder why I can't install them.. strange.

SSH Daemon is not a part of the default UnRaid install. You can install it via unmenu if you like. As you discovered, the default way to log into UnRaid is telnet. As far as not being able to install via unmenu - you'll have to be more specific about the problem you see. I know unmenu is a little non-user friendly. You can install stuff temporarily (it will be gone on next reboot), or install permanently (really just re-installs at every powerup). There's also a difference in unmenu between downloading a package and installing it - make sure you've done both Smile
Reply

Logout Mark Read Team Forum Stats Members Help
Setting up an UnRaid Server - Step by Step from a newbies standpoint0