Monday, December 21, 2015

NAS Box - other stuff

 I've decided to go with 2x8GB of RAM. In my case, the most important is the amount, not the speed of the sticks. Yeah, real men are not afraid of CL11. Second hand cost ~ 70$, quite a bargain.

As for the boot drive, I went with: SanDisk Cruzer Fit 16GB USB 2.0. It is reliable, small, and cheap. You can't go wrong with it. Price ~5$

NAS Box - the drives

Originally I've planned to get 2x2TB, but in the end I've ended up with 3x2TB in RaidZ
I've picked: Western Digital Green 2TB EARS for 50$ each.

- low power consumption
- available from the second hand

- hard to get 3 drives at the same time.

WD20EURS - are dedicated for AV recording, they do not have error correction
WD20EARS - are often used in external HDD enclosures.

It is not possible to turn on them Advanced Power Managment, this won't work:

To reduce power consumption, I've added additional 160GB laptop drive for plugins and non-encrypted stuff. I'd wicked idea to put inside the case external USB 2.0 drive. It worked but to minimize power consumption I've connected it to the SATA port.

If you change from USB to SATA Freenas will import the Volume without problems.

Saturday, December 12, 2015

NAS Box - the PSU

The short version is:
I was able to grab used Enermax Pro82+ for 25$!

The long version is:
Good PSU for this build is a key. Most so called, "expert bloggers" who only write about things not build them.. recommend 80Plus Gold - their are WRONG.

80Plus certifies products that have more than 80% energy efficiency at 20%, 50% and 100% of rated load. If your Nas box will require only 10%-15% of the base Wattage - then guess what 80% or more efficiency standard does not cover it. My build aims for 30-50W which is less than 20%, 80Plus Gold certificate does not cover it.

80 Plus test type[4] 115V internal non-redundant 230V internal redundant
Percentage of rated load 10% 20% 50% 100% 10% 20% 50% 100%
80 Plus
80% 80% 80%

80 Plus Bronze
82% 85% 82%
81% 85% 81%
80 Plus Silver
85% 88% 85%
85% 89% 85%
80 Plus Gold
87% 90% 87%
88% 92% 88%
80 Plus Platinum
90% 92% 89%
90% 94% 91%
80 Plus Titanium 90% 92% 94% 90% 90% 94% 96% 91%

Perfect example is be quiet! Straight Power 10 CM 800 W- 100$+, at 50W I will get75% efficiency even though it is 80Plus Gold.

After going over serie of reviews and tests. I went for Enermax 385 Pro82+, because it's efficiency is similar at 30-50W, and second hand costs 25$!

During my research, I found another solution, which is often recommended by "so called experts". There is a solution  which is called PicoPSU dedicated for small ITX boards. People say it has 96% efficiency or more. And that is correct, but the disadvantage is you have to feed it with external 12V PSU  (like AC DC 12V 8A 96W) which will have 85% efficiency at full load. Overall You will get 80%+ efficiency at 90W+ and additional adapters for SATA power. It is not worth it if you have enough space for the Full ATX build.

If you can't get Enermax for cheap, check out one of the FSP power supplies, they are worth consideration.

I've reached Enermax to ask if it's relevant for power efficiency to connect everything to one 12V line. They've replied next day. The short answer is - it does not matter how you connect it.

Pro tip from Enermax, how to determine which cables are from which power line?
Whole yellow cable - current line nr 1,
Yellow cable with black stripe - line nr 2.

Thanks, Enermax!

Sunday, November 22, 2015

NAS Box - the motherboard

After serious thinking, I went for BIOSTAR NM70I-1037U motherboard. 

- 4 SATA port
- PCI-E slot (possible upgrade to USB 3.0 or additional SATA drives)

- weak CPU cooler
- poor BIOS

I've found copper heatsink for northbridge somewhere in the basement. Screw layout fitted in. It was a bit too large mount. I had to modify it to make it worked. You can buy similar from all express. It is perfect heatsink replacement for NM70I-1037U.

Copper can be bent with just pliers, and after 5 minutes I was done.

The stock fan fits perfectly. I've read on the internet, that people are using Zalman northbridge cooler but it has no fan mount.

Here is the finall result, NM70I-1037U with copper heatsink. I'm really glad about the result.

I've tried to reach Biostar to get better bios, unfortunately they weren't willing to help me out.

Dear Customer

Interesting setup, unfortunately this motherboard/SOC design is not for overclocking.  There are no plans to add those type of changes, however if you are looking for a mini ITX motherboard with overclocking functions, we can recommend our Hi-Fi B85N 3D.

Sunday, November 8, 2015

NAS Box - the case

 I've found old Antec case online for just 12$. It's made from quality metal and looks pretty darn good. Unfortunately, it does not have special drive bay's and is not 100% black.
I've decided to spray paint it black, and that 's 6$.
I've found 5.25 LCD display for 4$!
I've ordered dust filters from china 4$. 2x 120mm and 1x140mm. The case had no mounts so I had to improvise.
It worked really well.
Total ~26$ spent.


  • dust filters everywhere
  • 6x 3.5 drive bays
  • LCD display with temps
  • cost
  • satisfaction


  • no special drive enclosers
  • Full-size ATX

Monday, October 12, 2015

DIY Project NAS box

Time to start the new home project, NAS box! It will be: Reliable, Expandable, Under 400$. This is the plan, which I came up with.

Build in Intel® Celeron® Processor 1037U - has more power, than any Atom out there. It has  TDP at 17W, but, unfortunately, there are no AES-NI instructions. You will get 4 SATA ports, support up to 16GB of ram, and one PCI or PCIE for further upgrades.
Price: not more than 80$.

It will be cheaper in a long run to buy 16GB.
Price: used 75$

WD green serie will be perfect, as a starter. After that, I can add additional 2 drives, or 4 drives with expansion PCI/PCI-E card if needed.
Price: used 120$

Power Supply:
350W+ BeQuiet, Enermax, Chieftec, Fortran, etc
The most important part is certification Bronze 80+ or more.

Price: Refibrushed 30$

Old Antec, Zalman, Fractal, etc case.
Including LCD Panel and Dust filters.
Price: used 30$

16GB Sandisk
It must be small as possible. FreeNAS does not require it, I am.
Price: 7$

Total: ~340$

Sunday, August 16, 2015

Home Server based on Pi

About one year ago I bought Banana Pi, which at that time, was a  raspberry Pi clone on steroids. At the beginning it had no goal nor purpose - another toy added to the collection. After one year it evolved into a fully functional home server which, to putting it simply, makes my life easier.

It started from OpenMediaVault. The first idea was to use Truecrypt with OMV to create a NAS box for home. Even though this seems to make sense, unfortunately OMV has its drawbacks, for example you can’t use it with a filesystem which wasn't created by OMV. For those of you who do not "speak" IT: it won’t work with truecrypt. As a great tool as OMV is it wasn't able to fulfill my needs. If you are looking for a simple out of the box NAS solution - it is perfect for you.

Even if it sounds unbelievable, installation of truecrypt on the Pi was extreamly easy. Everything is written somewhere in the internet, so excuse me i will omit it here.

In my case logical replacement for OMV was just Samba, my home network is based on windows and Linux machines, and if really there is someone non it here: both Linux and Windows speak Samba, of course Linux speaks more than just one language (Samba), but Windows.. Well that's a different story.

As simple samba installation is, its configuration is always a pain in the a.. .Therefore I’ve installed SWAT for web base samba administration. Unfortunately like always there had to be "but's" all over the place.

First of all mounted truecrypt volume by default is available only for root. There are two ways of doing things: add samba user to root group or play around with mount options in truecrypt. Trust me that’s not an easy thing to do, when most of the documentation is for truecrypt on windows.

I had encrypted NAS which is not easy to buy in store. I was happy (silly not to). The beauty of the solution is, that I can detach the usb drive from the Pi and connect it to a laptop or any other PC.It will work with truecrypt on windows without any problems.

For a while I was using OUYA with Kodi as a media center, because OUYA can "speak" samba. But I've bought Blue ray Home Theater. I found out that up scaling algorithms in the Home Theater can do magic.To put it simple as I can: image quality on it is better than on Kodi (at least installed on OUYA).

Home Theater do not "speak" Samba, there are "hacks" which can be used to fix that, but I prefer clean solutions. Home Theater speaks DLNA. Installation of miniDLNA on Pi is easy and the only thing you have to do is configuration file modifcations. There is no rocket science there. My Home Theater can now speak with NAS box. Perfect!

Few weeks after I found an unused USB DVB-T dongle, and thought it would be nice to test out proof of concept: stream TV out of the Pi. I've tracked down a solution which I could use, TvHeadend. It was already in Linux repository, so the installation was simple, just "apt-get". Done.
The problem here was, how to find the right firmware for the USB dongle. In my case the 5-th worked. TvHeadend configuration wasn't easy nor difficult - youtube will tell you all. Everything worked like a charm.

I had to add DVBS2 to the setup.I bought second hand DVBS2 USB device for $30 and proceed. And yes there were problems.. at the beginning I thought the usb device is damaged, because I could not make it work. Finally, I found the root cause, which was the old version of the TvHeadend. I've downloaded source code and compiled it manually. Version 4.x fixed the issue. At least this one.

A minor issue I faced, is that the version of VLC plug-in must be compatible with TvHeadend version installed on the server. If that does not work, or there is shattering - just update the plug-in. Kodi is able to update it's plug-in’s on its own. If a plug-in on my phone or ouya was newer than the servers I would have to update the server. I can live with it.

Setup was complete, but there was one "small tiny little" problem which is truecrypt performance. Originally the drive connected to Pi was used before on a PC. For the encryption  I've used SHA512 + AES-Twofish which was an overkill for the Pi. To be precise, I was able to achieve write speed of 3,5-4,5 MB/s. For those who download something with speed less than 20MBits/sec, it's fine. I needed it more.

I've recently decrypted and re-encrypted the volume again. Trust me there is no other option like copy the data somewhere and copy it back again. I've changed the encryption algorithm to RIPEMD-160 + AES which  gives me more than 7,5MB/s. It is sufficient for downloading stuff onto the NAS with the speed of 50MBit/sec . I have faster internet than that.

I bought ceramic heat sink for the Pi. I hoped I would be able to push it further than current 1.1Ghz. Unfortunately the heat sink allowed me to achieve.. big nothing. I'm not able to push it even to 1.15Ghz.  I know I'm at the end of the road. I know that the next NAS box will be based on x86, even though Orange Pi offers Quad core and 1Gigabit network. I'm sick of the cables, and small power supplies everywhere.

Overall I'm happy with the result, because I'm able to:

  • - stream TV over internet on PC, or Kodi(to be honest I do not watch TV)
  • - download any media and stream it on any device I have
  • - use encrypted NAS with all of my devices
  • - in future connect to it printer and it will work

There are things which can be added to the setup, like printer shared with Samba, or ownCloud. Some may ask about OpenVPN? I prefer not to put that on NAS box. Some things are meant to be separated. The NAS BOX no.1 is final.

Sunday, August 2, 2015