IraqiGeek's Blog

Building The FrankenNAS

There comes a time in every tech-conscious person's life when they reach the conclusion that they need to have some sort of network attached storage (NAS) to store their backups and all their data in a safe and reliable form. For me that point came in 2012.

Initially, I thought about doing what most other people in my situation do: buy a Synology or a QNAP box, stuff it with disks, and call it a day. However, I didn't like the idea of being under the mercy of some manufacturer releasing updates or fixes for whatever bugs their software had. I also figured that since I was going to have this machine powered on 24/7 on my home network, it might as well be able to do a few additional things, like running the occasional VM. These two requirements meant pretty much my only option was to build a proper NAS from scratch.

After quite a bit of online research, I settled on the Gen7 ProLiant MicroServer from HP; paired it with an HP Smart Array P400 hardware RAID controller (complete with a battery backup module), a Sharkoon 5.25" to six 2.5" drive cage, and a triplet of 750GB WD Black 2.5" drive in a RAID-5 configuration, for a nominal 1.5TB of redundant storage. When I finally filled those initial three drives in early 2017, I extended it's storage with a triplet of 1750GB Samsung/Seagate SpinPoint M9T 2.5" drives, for a further nominal 3.5TB of redundant storage. For over five years, it served all my needs without any issues. But then came the whole Meltdown/Spectre shebang. Overnight, the old AMD N54L inside it went from being able to handle around 120MB/sec at 30-35% CPU usage, to maxing out at 100% with only 50-60MB/sec of throughput!

And so, the journey to build a new NAS began. The old HP stood at 14L in volume. For this build, my aim was to shrink that to 10L. This meant I'll be looking at a mini-TX build. I wanted to reuse my drive cage and hard drives, which meant the case will have to have a 5.25" full hight slot. Back in October 2017, I bought a used Intel i5-6400T CPU for £50. I didn't have any use for it, but for that price I couldn't let it slip, when the going rate on ebay was closer to €150. I also had a couple of 8GB 2400MHz DDR4 SO-DIMMs lying around. Those two meant the motherboard will have to have an LGA1155 socket, and preferably support SO-DIMM memory. Finally, I knew the old P400 wouldn't do it this time, as it can't handle more than 120MB/sec in RAID-5, and so I'll need a "new" RAID controller.

Unbeknownst to me, the market of LGA1155 mini-ITX boards that accept SO-DIMM memory, yet have a PCI-E slot to accept an expansion card is almost non-existent. The only board that I could find that fit those requirements was Jetway's NF594-Q170. Except this board cost over €220 in Europe. I wasn't going to pay that much for a mini-ITX board. The whole point of going SO-DIMM was not to shell €160 on 16GB of desktop DDR4 RAM!

"Was there a way to use my mobile memory on a desktop board?" I asked Google. Sure enough, some Taiwanese company by the name of Ju-Jet Electronics had made such an adapter! The only thing left was sourcing it. Google suggested an e-tailer ( that supposedly sold them. But when I tried to buy from their online store, they required direct credit card payment through a less than reputable payment processor. As if that wasn't enough, they charged more for international shipping than two of the adapters cost! Following another couple of days of searching, I managed to get a pair from eBay for $32 shipped! This meant I could now use pretty much any LGA1155 mini-ITX board with a PCI-E slot.

A good, reliable, professional-class motherboard is a must for such a build. My old HP was shutdown about five times over the five years it served me. I expect the same level of availability of my new build. I settled on an Asus H170I-PRO. It provided a good set of features including an M.2 slot (already had a 256GB ADATA XPG SX7000) for a fast boot drive, dual GbE, and VRMs able to deliver more than 65W; meaning my 35W CPU would be a breeze for the 6-phase power delivery system. Best of all, Amazon sold the board for under €100, including shipping.

There were only three parts missing: The RAID controller, a case, and an efficient power supply. The case would be dictating the power supply format.

For RAID, I wanted a controller with plenty of features and room to grow. Mechanical drives evolved substantially over the past decade, but one area where not much has changed is throughput: They still can't output more than 140-150MB/sec. This means anything SATA-2 or SAS-1 (300MB/sec) would be more than enough. After some Googling, I found an old roundup at Toms's Hardware of three top-tier Enterprise controllers from 2009. While almost a decade old, those were some of the best RAID controllers money could buy back then, and the reviewed models continued to be sold until 2012/2013. I settled on the Adaptec 52445. It's small, has 6 internal SAS ports (each supporting 4 channels, for up 24 directly connected drives, or 256 drives with expanders), and provided me with an additional SFF-8088 for any crazy external-SAS ideas I might have in the future. Plus, with a bit of patience, it could be sourced on eBay for $30-40 including the Lithium-Ion backup battery module. Not bad for something that retailed at $1600 not many years ago!


Turning to the case, my requirement for a 5.25" bay greatly limited my options. Wanting a clean and simple design. A target volume of 10L made it harder still. The only case design I could find on the internet that came close was Lian Li's PC-Q07B. At under 11L (10.9L @ 193x208x280mm), it would be a good 30% smaller than the outgoing HP it substitutes. This case also accepts a standard ATX power supply, greatly facilitating the search for a high-efficiency, reasonably priced PSU. Only problem was that they stopped making this model in 2009. Again, after a couple of weeks of searching on eBay and I was able to buy a used one, in very clean condition, with the front USB ports upgraded to the 3.0 standard for under €50. Given the low power nature of the entire build, I needed to go with a low-power rating power supply, as even 80Plus Gold units don't hit 80% efficiency until 20% load. Dell's L265AM from their old OptiPlex 790/990 line early in the decade, rated at 265W with an 80Plus Gold certification fit the bill squarely. eBay has plenty of those available cheaply, and it wasn't hard to find a new (old-stock) unit for around €30 shipped.

For the CPU cooler, I went for a Noctua NH-L9i. It's low-profile fits with room to spare in the tight quarters of this small buid. Rated at 65W, it's almost twice the 35W of my i5-6400T. Reviewers and users praise its quietness and reliability. And at €38 shipped, I didn't have to look much further.

Finally, to keep the insides clean from dust, I bought a large sheet of thin foam, the kind used in air conditioning filters. Cut and glued pieces to size on all ventilation openings in the case (the black strip to the right of the motherboard, and the black fuzzy pieces on the back of the case).


Beyond the CPU and RAM, it took about two months to research, buy, and ship all those disparate components, from all corners around the world. And while it was a fun exercise, it reminded me why I hadn't really built a desktop system from scratch for over 15 years. It took way too many hours to research most components, and a few more fit everything together neatly in such tight quarters. I would've paid a pretty premium to have a fully integrated system from a major brand that could do the same, as my outgoing MicroServer did. The new Gen9 and Gen10 MicroServers sadly dropped the full-height 5.25" slot, rendering them unusable for such a build.


The keen eyed might have noticed the mish-mash of currency symbols throughout this post. This was no mistake. The CPU came from the UK, the motherboard from Italy, RAM was bought earlier locally in Portugal, the memory adapters and SAS-SATA cables came from China, the CPU cooler from Spain, the RAID controller from the US, and the case and power supply from Germany (different sellers).

Partly because of the mish-mash of disparate components used to build it, and partly because those components came from half a dozen countries across three continents, I christened this machine The FrankenNas :D


Unboxing the Bang & Olufsen Beoplay H5

I don't usually do unboxings, but this one... this one is different.
 Those who know me know I'm a sucker for bluetooth earphones. I've been using BT earphones almost exclusively with my phones ever since I discovered Sony's BT20NX back in 2007. That one lasted me over 5 years before one of the drivers failed. While I'm no audiophile, I do appreciate a good pair of earphones that provide clear, distortion free sound even when taken to max volume. I've also grown to appreciate the increasing range I get with each new wireless phones I get.
I've always peeked and oogled at Bang & Olufsen products in electronics shops, appreciating their uniquely Danish simple, yet elegant, design. There's something about Scandinavian design that's just so pleasing.
BeoPlay H5
Today, I received an unexpected - yet greatly appreciated - gift from a friend -the same friend I helped get past WannaCry a few weeks ago -in the form of a pair of B&O H5 bluetooth earphones. I can't even begin to describe how pleasing and elegant those tiny things are. Even opening the packaging exudes a sense of occasion. A sense of elegance.
The earphones are coated in this soft-touch material that feels almost like velvet to the touch. The cord connecting the two earpieces is not only tangle-proof, but also feels like silk when holding it. And the small metal cap, adorned with the B&O logo, on each earpiece has a spun texture that drags the fingers to contour with its curve. Even fitting the earbuds is accompanied by a reassuring, if soft, sort of thump to let you know they sat firmly in place.
I've always had a huge respect for Sony. The materials, design, and quality of their audio-visual products is amazing. My current pair, until today that is, is a Sony SBH80, which I've had and used daily for two years, and they never ceased to surprise me with how comfortable they are whether I'm in a T-Shirt or a suit and over-coat. They're intuitive, clear, have a battery that lasts ages, and are splash-proof. But the level of attention to detail in these B&O earphones is on an entirely different level. It's staggering.
Each earphone has a hidden magnet on the opposite end of the driver. When the two get close to each other, they click together forming a sort of B&O necklace. That, on its own, would've been a nice design feature. But these are B&O earphones; obviously there's more! When the earphones detect they are attached to each other, they automatically enter into stand-by mode to save power! That is as good as ergonomic design has ever gotten.
While they don't charge through Micro-USB, they come with a very nice cube-shaped charger, which is also covered in the same velvety soft-touch material as the earphones themselves, and has a rubbery base that helps it stick to the surface it sits on. The cable seems to be made of silicone, and is extremely flexible with absolutely no memory effect.
Remember those two magnetic ends on the earphones from above? They also serve another purpose. When each earphone is brought next to the corresponding side on the charging cube, it soft-clicks beautifully and securely in place. Once the two are docked into the cube, a tiny red LED will flash to indicate the earphones are charging. That same LED will light solid green once they have fully charged.
But we don't buy audio equipment because it looks niceor is made of pleasant to touch materials. So, how do these earphones sound? I'm delighted to report the sound coming out of the two 6.4mm "electro-dynamic" drivers is just as good as the first contact with those earphones would suggest. Sound is distortion free even at maximum volume, rich in bass without overdoing it, and the level of clarity is nothing short of fantastic. They're also quite loud! And goodness gracious are they light (18 grams, to be precise) and comfortable to wear! They're so light that I almost forget I'm wearing them.
All in all, I'm really happy with my new earphones, and I'm really grateful to my friend for this awesome gift. I've also gained a new appreciation for B&O and an understanding to why their products command such a price. Such quality and attention to detail do not come cheap.

It's all distant and abstract, until it hits someone you know

Ever since Stuxnet, there has been no shortage of news, almost on a daily basis, about some high profile government or private entity or institution being hacked. Sometimes, the hackers' objective is to infiltrate the target organization, to listen on and monitor its activities. Other times, the objective is to exfiltrate sensitive information from the target. Still other times, the objective is to destroy the target and their infrastructure. Whatever the target, it all seems distant, abstract, and not something that would happen to the average Joe. After all, what would your average hacker gain from hacking our personal computers, and our data?

Then, it happens to someone you know, and it suddenly becomes all too real.

It all started when a friend, who works at a small local business, called me a few days back around the end of the day asking if I could help with some computer trouble they were having at the office.  When I asked what was the problem, she said someone had entered into their office network and encrypted all their data and files, and was now demanding a ransom in order to deliver the encryption key. Naturally, I went immediately to their office to get a sense of the gravity of the situation.

Sure enough, while their office computers were up and running, all data and files were encrypted. Not only that, the ransomware that encrypted all files and data, had left a readme file containing payment instructions in every single folder where it had encrypted files.

This readme not only identified the victim by a uniqe ID (kind of like a customer number), but gave them instructions on where to buy bitcoins, which address to sent the bitcoins to, how to get in touch with the hacker (through a Tor hidden chatroom), and how to provide evidence of payment to the hacker. The instructions were clearly translated to Portuguese using an automated translator like Google Translate, but still!

How did this happen?

Like many businesses, this one constantly sends and receives letters and parcels, and deals extensively with logistics and transport companies. So, when an email appeared claiming to be from one such company, the person attending to this email didn't think much of opening the link embedded within this email. The link sent them to a site claiming that they had a parcel awaiting, but as the site didn't look quite right, this person closed the page, and even run an antivirus scan for good measure!

But it was already too late. Despite the antivirus proclaiming that all was fine, the machine was already infected and the ransomware was already at work encrypting all files it come by.

Now, anyone's first instinct in such an incidence, is to restore the last backup, clean up the system, and give this hacker the proverbial finger. However, the backup in this instance was synchronizing all data and files to the cloud, using Google Drive. But since the ransomware encrypted files, Drive did its job and synchronized all those encrypted files, rendering the Drive "backup" all but useless. While it was technically possible to restore an earlier version of each file, there were close to 50k files to restore, rendering the task practically impossible.

Given the relatively low ransom value beind demanded, and the time and effort required to get the business minimally operational without getting the encrypted files back, my advise was to try and pay the ransom. While there were no guarantees whoever controlled the ransomware would deliver the decryption password, I thought it was worth trying.

Here is were we hit our biggest hurdle. The ransom was being demanded in the form of a bitcoin payment. Everyone and their cousin on the internet, bills bitcoin as an easy and anonymous form of digital currency payment. But if you're in a rush, and need to get your hands on some bitcoins quickly, those online exchanges which you are willing to share your credit card information with are anything but anonymous, or quick for that matter.

I tried registering with over half a dozen exchanges, including coinbase, coinmama, cex and coinpanda. All those exchanges required several forms of proof of identity, proof of address, and proof of credit card ownership in order to buy bitcoins with a credit card. Beyond that, they required those proofs in high quality digital scans, and a human reviewed each and every detail. While I'd say this is commendable under normal circumstances, it's not very helpful when you're in a hurry. In the end, we bought our 0.25 bitcoins locally using The seller didn't respond for hours, and setting up the meeting posed its own safety and security challenges, as it was close to midnight by the time we heard from him. Luckily, he turned to be a friendly fellow, and didn't hesitate to help and was patient enough, despite the late hour, to wait with us until the transaction had enough confirmations on the network in order to provide us with the proof of payment demanded by the person controlling the ransomware.

From there, it took another 9 hours until we hard back from this person and received the encryption key. And would you look at that key!