Design your own NAS with $25 4x SATA HAT for NanoPi M4 Board

NanoPi M4 is one of the many Rockchip RK3399 boards available on the market today. The SBC follows Raspberry Pi form factor, comes with 2 to 4 GB RAM, four USB 3.0 ports, Gigabit Etherent, HDMI 2.0, etc.. and exposes the 2-lane PCIe interface from the Rockchip processor not through a typical PCIe slot or mini PCIe slot, but instead through a 2.54mm pitch header.

I feel like an odd choice at first glance, but it now makes complete sense, as the company has launched a 4x SATA HAT for NanoPi M4 board that leverages the header with PCIe 2x signals.

4x SATA HAT NanoPi M44x SATA HAT for NanoPi M4 key features and specifications:

  • PCIe to SATA Chipset – Marvell 88SE9215 four-port 6Gbps SATA I/O controller
  • USB – 2x 4-pin USB 2.0 host connectors
  • Expansion – NanoPi M4 40-pin header exposed
  • Misc
    • Power key, unpopulated power key jumper
    • Power LED, 4x SATA LEDs
    • Heat dissipation – 2x PCB nuts for mounting a heatsink on top of Marvell chipset; 2-pin header for fan, PWM modulation for 12V output
  • Power Supply
    • 12V DC input via power barrel jack or 4-pin header; 2A needed for one 3.5″ hard drive or four 2.5″ hard drives; 5A needed for four 3.5″ hard drives
    • 4-pin power connector with 12V and 5V output
  • Dimensions – 65 x 56 mm
  • Weight – 33.48 grams

M4 SATA HATThe company provides Ubuntu based FriendlyCore 18.04 64-bit, FriendlyDesktop 18.04 64-bit, and Lubuntu 16.04 32bit with Linux 4.4, Uboot-2014.10 for NanoPi M4, and those images can be used with the M4 SATA HAT.

The company ran iozone to show the performance with one 750GB Crucial MX300 SSD.

NanoPi M4 SATA HAT iozone benchmarkRandom reads and writes are much faster than eMMC flash modules and micro SD cards, but do not quite reach the performance of NVMe SSDs which can be connected to the company’s higher end NanoPC-T4 board.

This HAT will ease the design of NAS based on Rockchip RK3399 processor with up to four drive, and it won’t bread the bank as the 4x SATA HAT sells for $25 with heatsink, thermal pad, screws, metal standard, SATA I/F and power cable. If you don’t own one already, you’ll also need to add NanoPi M4 for $65 and up,  a 12V power supply, an enclosure, and obivously the storage device(s).

NanoPi M4 NAS

Thanks to theguyuk for the tip.

Share this:
FacebookTwitterHacker NewsSlashdotRedditLinkedInPinterestFlipboardMeWeLineEmailShare

Support CNX Software! Donate via cryptocurrencies, become a Patron on Patreon, or purchase goods on Amazon or Aliexpress

ROCK 5 ITX RK3588 mini-ITX motherboard

38 Replies to “Design your own NAS with $25 4x SATA HAT for NanoPi M4 Board”

  1. That turns the NanoPi M4 into a very interesting kind of product, as $120 (4GB M4 + hat) gets you a very viable desktop-use-case SBC, with a light NAS side-job.

  2. > Marvell 88SE9215 four-port 6Gbps SATA I/O controller

    That’s a bit sad since I recommended using the 88SE9235 instead for a reason: the 88SE9235 uses 2 PCIe lanes while 88SE9215 just 1 so this results now in lower performance with connected SATA SSDs or more than 3 HDDs.

    Asides that glad they finally delivered (it’s been almost 5 months since 1st prototype) and even improved the design. The 2 independent 12V inputs are great especially since ‘5V only powering via USB-C’ is NanoPi M4’s weakest spot.

      1. Yes, you only need one appropriate 12V source connected to the HAT and there DCDC circuitry generates the 5V needed for M4 and the connected SATA devices as well.

    1. Weird test results from FriendlyElec. Why is the same eMMC module 90MB/s faster on the T4? And is the 340MB/s the limit of the SSD or of the hat?
      I’ll see to source one so I can test it with multiple drives.

    1. Good protoype for any product maker working on a mass Nas design. Working software and hardware. Not just a board dump like other SBC vendors.

  3. The microfit 12v connect is a good idea and they even worked out you might want remote power control. If you wanted to build a cluster for some reason this is what you want even if you don’t use the SATA part. You’d only need an ATX PSU, a switch and an arduino or esp for powering the boards on and off.

    1. > If you wanted to build a cluster for some reason this is what you want even if you don’t use the SATA part

      My understanding is that for such a cluster use case this HAT is not needed with a sufficient 5V source since the PWR_KEY pin is present on the 24 pin GPIO header here (on NEO4 it’s instead pin30 on the 40 pin header).

      1. That’s interesting. I was thinking that the power control on the HAT was part of the DC-DC supply for the 5v. Either way with this HAT you get to tap into the meaty 12v rails on almost any cheap ATX PSUs instead of trying to find lots of good 5v supplies or one 5v supply that can put out enough current for many boards.

    1. > but no Raid support I guess

      Fortunately yes! 🙂 I mean, yes, no RAID support (the Marvell HyperDuo stuff has a pretty bad reputation and most people realized that ‘HW RAID’ in general is nothing that great these days)

  4. To make user-friendly device, we need some enclosure for 2-4 hdds. It should lack of any hardware. I can’t find something suitable on AliExpress.

    1. I found some in the past but they were expensive. Which makes sense as there isn’t much of a market for a box to put disks in.

      I’m not sure if it’s available in the rest of the world but over here Daiso (they sell the same stuff in the US AFAIK) sell a miniature version of the pipes and shelves racking system. You can build up a little rack that has space for your SBC, drives and power supply for 10 bucks out of it. If you have a 3D printer you can print out nice mounts for everything. If not you can just cable tie everything and still have something that doesn’t fall apart when moved.

    2. > we need some enclosure for 2-4 hdds

      The next scrap yard next to you features those for free: old PC enclosures! 🙂

      Seriously: as soon as you skip the PC’s ATX PSU and simply screw the NanoPI M4 to the enclosure (using it as a heatsink) you’re done and are also way more energy efficient when powering the setup with an external 12V PSU compared to an inefficient ATX PSU.

  5. Friends, I’m planning to buy this hat with M4 board. How to select ram amount in M4 config – is there any usecase for 4gb version? I’m going to use OMV.

    1. > is there any usecase for 4gb version?

      With your server use case only if you think about running a bunch of containers or VMs at the same time (OMV has a pretty nice Docker integration). With ‘basic NAS operation’ you would be fine with 1GB or 512MB as well. More RAM always only ends up as filesystem buffer/caches.

      Please note that I’ve no idea whether the 88SE9215 will work out of the box with the OMV image since I’ve not tested it personally so far. The 88SE9215 controller is rather old and should as such be supported by Rockchip’s 4.4 kernel the OMV image is based on. If it doesn’t work you need to use armbian-config to switch to mainline kernel.

      Yesterday I checked FriendlyELEC’s kernel repo on Github and saw no relevant changes so I would assume it will simply work.

      1. There’s one use case where you need tons of RAM, it’s when using rsync with lots of small files. I’ve spent quite some time this week-end trying to address OOM issues on my NAS because the file count grew enough to kill it despite the swap I added there :-/

    2. “More RAM always only ends up as filesystem buffer/caches.”

      So things like zfs on linux will profit from it.

      1. > things like zfs on linux will profit from it

        Why/how? ZFS by default wants to use almost the entire RAM as ARC ( adaptive replacement cache used for speeding up reads of most accessed data). Is this useful on a home/SOHO NAS? Usually not since access patterns don’t fit. You then have data sitting in RAM waiting for accesses that won’t happen anytime soon.

        Adjusting ARC size is usually the first thing I do when setting up ZFS on a home/SOHO NAS low on memory. No performance differences. Of course on a high-performance filer serving a lot of users and especially other servers (SAN storage) that’s something entirely different, those machines get as much RAM as possible and lowering the ARC size has negative impact on performance.

        But that’s a different use case anyway.

    1. You can, you just need the 5.25 enclosure to place it into. Maybe FriendlyElec should start to think about providing 3.5 inch enclosures for their boards so that they can be placed into mini-PC like cases.

  6. May i ask for opinions? a nanopi m4 with a sata hat? or go with Helios4? the difference is mostly at CPU ( m4 runs way faster across the boarder, the other part is RAM, while nanopi m4 have upwards of 4G ddr4, Helios have the advantage of getting ECC, the last is about the VPU/GPU? ( i may not recall the right thing here ) nanopi m4 have a better GPU / VPU for possibility to be enabled to add transcoding ability to this nas, kind of in a fight@@
    also. i am also considering whether the rockpi4 or nanopi m4 is better in this case, one have a full size m.2 key, which i can extend to a PCIEx4 and i can find some 88SE9230 based 4 port SSD extentions cards around 55USD, kind of a close fight here

    1. It solely depends on your main use case : M4 has tons of CPU power but not that much I/O. The Clearfog SOM (basis of Helios4) has 3 times less CPU power but roughly 3 times more I/O bandwidth. In fact the single gigabit link will be a bottleneck for this one. If you want to build a solid NAS the Helios4 will likely be better. If you want to build a generic well balanced machine, the M4 certainly is better (and it has a display output that some people care about). Both will work reasonably well with a mainline kernel. I’d personally make an every day workstation out of the M4 and the file server out of the Helios4.

      1. I fully agree with @willy re M4 vs Helios4 — M4 has mixed desktop/light-NAS applications, wheres Helios4 is an excellent NAS and not at all a desktop (but could be a small headless server).

    2. > rockpi4 or nanopi m4 is better in this case, one have a full size m.2 key, which i can extend to a PCIEx4 and i can find some 88SE9230

      RockPro64 is the same RK3399 thing but with an x4 PCIe slot. And I would avoid the 88SE9230 but instead choose the 88SE9235 (no RAID/HyperDuo stuff). And of course M.2 cards with same chip exist too but then you’re on your own with powering the disks (an important part to keep in mind and something where the above SATA HAT shows an advantage).

  7. Having never used anything but Windows previously. . . . and, to say I’m a novice at 77 is an understatement, but. . . . . I have the Nanopi M4 and just got the 4x SATA Top Hat. How does the Marvell 88SE9215 controller “card” attach to the Top Hat?
    Thank you in advance for any help given. . . . . . . . .

Leave a Reply

Your email address will not be published. Required fields are marked *

Boardcon Rockchip RK3588S SBC with 8K, WiFI 6, 4G LTE, NVME SSD, HDMI 2.1...
Boardcon Rockchip RK3588S SBC with 8K, WiFI 6, 4G LTE, NVME SSD, HDMI 2.1...