Media/File Server or NAS?

Well, I’ve decided it’s time to upgrade my storage solution from multiple external HDD’s to something more robust that has redundancy built in. I’m thinking about 4 6TB Iron Wolf’s in either a NAS or possibly just a Deb based media server. Having never used either, I guess my question is which is the best bang for my buck? Obviously I’d like to use RAID (5 I’m thinking) and if I choose a media server, I suppose Plex may be an option although I currently use Kodi.

If I choose the media server route, what’s the minimum CPU/RAM I should use and number of SATA ports considering I want RAID? I watched the videos about building a media server on here, but that was only using a single hdd and I want to know about any other obstacles I may encounter with a RAID setup. Thanks in advance for any advice.

Check out ZFS and FreeNAS

2 Likes

Yeah, FreeNAS all the way.

FreeNAS has support for Plex and Kodi, through their “plugin” system. Think of it like Linux containers, but for BSD.

RAID 5 is not recommended (one disk worth of spare) for arrays of 4TB or larger disks because you can lose another drive while rebuilding the array from the first failure.

My recommendation? RAIDZ-2 (equivalent to RAID6)

Do you have a budget in mind? There’s a lot of good kit out there for pretty cheap. Do you already have hardware you want to use? The IronWolfs are good, but If you want to go with 8TB disks, you can shuck the WD EasyStore 8TB disks and get white label enterprise disks, for $150 when they’re on sale.

As far as the sata ports go, you want to consider if you want to get a controller or use onboard. I recommend a controller, but that’s up to budget and number of disks. Onboard will work fine for 4 or fewer, typically.

As far as CPU/RAM recommendations: ZFS likes to eat ram. I like to use at least 16GB of ram on my NAS systems, but it really depends on what you’re doing. My NAS is a 48TB system, and I’ve got 48GB of ram in it, because I also run VMs. Before I got this one, I had a 20TB array with 16GB of ram and it didn’t quite feel like enough. I spent a lot of time swapping. That said, I did run a lot of services on it.

As far as CPU goes, that depends on what you want to do. Ryzen is a strong platform for this due to price to performance ratio. How many concurrent transcodes do you want Plex to support? (how many people will be watching it at once) Do you want to run any other services/VMs on this server?

Setting up a RAID array is quite simple. Especially with FreeNAS, you just throw all the disks in, boot it and use the web UI to configure the array, set up your shares and then you’re off to the races.

I recommend against using Linux for a fileserver, simply because FreeNAS is so easy to use and solid. Nothing against Linux though.

Here’s a quick list I threw together. I’m sure it could be refined to save a bunch of cash, but this is a start:

https://pcpartpicker.com/list/3XkB9J

I didn’t include disks because I’m not sure what your storage requirements are yet. If you don’t know what they’ll be, tell me a bit about your storage habits, how long you’ve been storing the data you have and if you expect your needs to change and I can try to make a recommendation for you.

3 Likes

For the OS, use OpenMediaVault (Debian with a nice network interface) or Freenas. I personally use OMV and it’s been useful moving away from microsoft.

Use ZFS as the filesystem. This will take a little bit or research to learn how to use it properly, but it’s worth it and once you understand what it is and how it behaves it’s pretty simple. OpenMediaVault has a ZFS plugin, allowing you to do basic management from the network UI if you like. No idea about Freenas but it seems likely. I prefer using mirrored vdevs for active storage, and raidz2-3 for backup. Use syncoid or pyznap and zfs send/receive to take advantage of snapshots which are fucking awesome. Snapshots let you revert a file or the whole system back to any stored snapshots times you have.

It’s best to use whatever old computer parts you have laying around for a fileserver, but In general a full ATX motherboard is desireable so you have lots of pcie slots, which means better expandability and less burning money.

Modern ATX boards tend to have a good amount of sata slots, but if you need more, then get an HBA card. Search ebay “Dell H310 6Gbps SAS HBA LSI 9211-8i” and you should see plenty of options for “IT firmware” pre-flashed cards for ~$55. Note that these cards are generally intended for cases with forced air, so it’s highly recommended to put a fan over the heatsink on them to prevent problems that can sometimes happen. Take off the heat sink, clean the old paste off, drill two holes in the corners, put the heatsink back on with some spare paste, and use twist ties to mount a fan fan to the heatsink.

If you want to connect sata SSD’s to the HBA, you need one of these cables, just make sure you know what length of cable you need, and if getting a right angled version is prudent before ordering. If you had disks connected to a backplane that feature an SAS connection, you could use one of these.

If you are doing actual work in your storage, then once you have about 6 disks in zfs (3 mirrored vdevs) you start benefiting from 10g network stuff, which pcie makes easy, but that’s a whole other topic.

If starting out with new hardware, I’d likely make a system based off a ryzen apu. I could likely downclock it for better power savings too.

ECC ram is recommended if you can get it for a decent price, but in no way required despite some very vocal people. I am unfamiliar with which combinations of ryzen cpu’s and motherboards support ECC. I think asrock and gigabyte have some, but research this carefully.

Also, for cheap sources of drives, look up “shucking”, Easystores for periodic deals. And when you plug in a new drive and it flat out doesn’t work, look up “3.3v pin reset” use some tape and problem solved.

1 Like

Thanks for the information. I’d never heard of shucking and that’s awesome and easy to do. I don’t suppose the Red drives are in the cheaper WD Elements and My Book external enclosures though, right lol? I’ve dabbled in Linux before with Ubuntu and at this point in my life, I don’t think I want to make the jump yet, but I’m not against setting something up in a Linux environment that I can then access with Kodi on my Windows PC and Firestick 4k.

My setup will be streaming one or two movies at most at a time. Right now most of my content is 1080p but I am very slowly adding 4k content as well. FreeNAS sounds like the way to go. I am wondering if a Ryzen and 16GB are necessary though? Older Core I7 systems with 8GB are dirt cheap and I’ve seen people use ancient Core Duo’s with 4GB RAM on some setups. But forgive me if there are other demanding aspects of FreeNAS that I am not aware of.

RAID 6, or its equivalent sounds like the way to go. I knew this already but was just being cheap. However, since I will be running without a backup (at least at first), having the extra drive protection is probably smart. But I keep asking myself, if RAID 6 only affords me 16TB of my 32TB of drives and puts constant wear on all 4 drives, would it not be smarter to have a RAID 0 array of 2 drives and backup that array to a second RAID 0 array once a week, where the 2nd array gets no use? I know there’s RAID 10 but that writes to all 4 drives and can only sustain 1 drive failure. Again, I’m probably missing a huge point and I know that would require more than a set-and-forget setup.

Now, the media server won’t need a dedicated graphics card if the CPU I choose has Intel Graphics integrated, right? The client will be doing the rendering. I would only need a dedicated card if I choose a CPU without an integrated graphics chip.

FreeNAS uses ZFS and needs a ton of RAM for performance, but if you’re streaming a couple of videos at a time that won’t make any difference for your use-case.

If you go with FreeNAS use ZFS redundancy. Otherwise, RAID6 is unnecessary, RAID5 is fine for media storage. If a disk dies replace it. We’re just talking movies and TV shows here after all right.

Right, no need for discrete graphics on a NAS.

Maybe a better way of putting it is that ZFS benefits from all the RAM you can throw at it. It also works well with 8GB, if that’s what you’ve got. It is just a truth of computers that RAM is orders of magnitude faster than disks, so ZFS knows how to use RAM to adaptively cache data.

A common rule of thumb is to plan for at least 1GB of RAM per 1TB of storage, but it depends on your workload.

Each pair of disks can sustain a drive failure. So up to two may fail.

I prefer to do the raid10-type striping across mirrored sets. It performs well and is easy to expand incrementally by adding or replacing two disks at a time.
If you’re worried about disk wear, get a spare disk at some point. You should have at least a year or two to save up for one before you have to worry about a disk failure due to wear (assuming you weeded out fault disks that would fail earlier by doing proper burn-in).

Please understand that RAID is not a backup. Disk redundancy is for the reliability of your server. The server remains operational when a disk fails. It doesn’t help you when you accidentally deleted or overwrote an important file. That is where you need a backup. And a backup doesn’t help if your disk fails at the end of a 6+ hour render. Of course, you also want your backups to be reliable, so the two ideas can be complementary.

ZFS has a lot of important features that it is good to become familiar with. Some examples include

  • disk redundancy
  • checksums
  • snapshots
  • compression
  • copy on write
  • send/recv
  • storage pooling

Throwing my two cents in for FreeNAS as well.

You only get off-label enterprise drives from the 8TB 3.5in enclosures. The My Book enclosures may work. I forget off the top of my head. Here’s the /r/datahoarder cheatsheet for them:

Okay, so a 4k transcode requires 22000 cpubench for a CPU transcode. That means you’ll pretty much need a Ryzen 7 for a single stream, or you could go with GPU transcoding and get something like a 1050 ti.

Older i7 systems will work fine. I used an i7-2600k for a good few years as my freenas server. 4GB of ram is definitely too little. FreeNAS absolute minimum requirement, from the company that makes it, is 8GB. This is because ZFS uses lots of ram. You can tune it down below 4GB of ram, but you run into major performance problems at that point.

If you’re going to use 4 disks, RAID10 will be fine, IMO. In fact, striped mirrors (how ZFS calls RAID10) is the fastest way to have a failure tolerant array.

Need and get benefit from are two different things. I touched on it earlier, but if you want to take advantage of Plex GPU transcoding, you might want to consider a GTX 1050, or used 900 series card. But yes, to get the system to boot, you will not need a dedicated GPU if you use an Intel CPU with integrated graphics.

No need for a GPU. Every intel CPU from sandy bridge on has quicksync for hardware video encoding. Skylake and later do h.265 too.

Will Quicksync handle a 4k stream? I’m not trying to be argumentative. I’m just not experienced with quicksync’s capabilities since I have Xeons in my FreeNAS rig.

Yep, works fine with 4k. I have an i5-6500 running my plex server, does a great job.

1 Like

Perfect then!

Note you do need Plex Pass to do hardware encoding with Plex. That applies to both quicksync and GPU offloads.

Oh, is it still experimental?

No, they just like money.

I like money too. I don’t blame em. They make a good product. Lifetime PlexPass isn’t super expensive in the long run.

They also usually have a black friday sale for it, which is when I plan to pick it up.

They occasionally send out offers to get lifetime for $75, that’s what I did. I don’t use Plex much but I like the software and generally want to support them.

1 Like

Wow! The rabbit hole goes much deeper than I thought. I thank everyone that has responded. Now that I have more information, I’m not sure if I’m closer or further from a decision because of the additional things to consider lol. I will do some research on the suggestions given and come back with more questions I’m sure, but at this point I would just be showing more noobness on my part.

There is one thing that I can ask right now and it pertains to transcoding. I was under the impression that the media server only provides a storage location for my music and videos and is basically just a network share for my other devices to access. Does the video decoding/transcoding take place on the client if you are using Kodi or Plex, or are there different options for streaming?

Edit: I will be streaming to Firestick 4k on Kodi and occasionally on my computer as well.

1 Like

Kodi just direct plays from the source. If you’re just using Kodi all the above stuff doesn’t apply to you. I exclusively use Kodi myself, except when traveling.

Plex can direct play, but it can also transcode video to use less bandwidth, if you have a slow internet upload. It has dynamic bandwidth scaling too, so if you’re watching a movie on a train and switch cell towers it will switch to a lower bitrate then dynamically switch it back up to 1080p when you get a better connection. It also transcodes to a format your mobile device can decode in hardware, which saves a ton of battery life.