Homebrew NAS/Time Capsule
Homebrew NAS/Time Capsule
History
I've had folders shared over my home network since I had a network, allowing me to access files from multiple machines, and back up important data to a central location. Eventually, I devoted an old AMD desktop to act as a mail and file server, running Ubuntu. Since my household is generally running OS X machines, I set up AFP shares using netatalk.
However, running a desktop 24/7 for something as simple as email and file sharing seemed pretty wasteful, both in terms of physical space and power usage. I experimented with scheduled shutdown and reboot to save some power over night, but there were issues; email being unavailable when overseas in another timezone is very annoying. So I looked into alternatives.
I set up a Raspberry Pi as a low-power always-on mail server which has been happily running 24/7 for the last six months, but file sharing was slightly more troublesome. The Pi can share USB drives but power supply can be an issue and speed would be limited to USB 2.0 between the disk and the Pi, and to 10/100 ethernet between the Pi and the network.
Solution
So I began looking into off-the-shelf NAS systems. There are many now available which can run a full Linux install, meaning it would be possible to replicate the existing shares on a far smaller box. But even older NAS systems are still quite expensive, and most need reflashing via serial cable to get working with Linux. In addition the form factors are almost universally boxy, which is not the most efficient shape to fit in my office.
I then read about the Seagate GoFlex Net. It's a small NAS device capable of sharing two 2.5" SATA drives, and a USB device, over Gigabit ethernet. It runs pogoplug software and costs around £25-£30.
I found the excellent guide written by Don Charisma here detailing how Debian Linux can be (relatively) easily installed, and I was sold.
Once purchased, I wasted no time in dismantling the device to remove the logic board. I had read here of the possibility of converting the SATA ports for use with full size 3.5" drives, by running a wire supplying 12V from the DC power socket to three pins on each of the SATA ports.
Once soldered, I was able to share a couple of old 3.5" drives successfully using the built-in pogoplug software.
The next stage was to follow the steps documented by Don Charisma to get the GoFlex Net running Debian, and specifically Openmediavault, from a USB stick connected to the USB port, instead of the factory software. There are a couple of missing steps/details in his guide: firstly, around Step 6, an additional line needs to be added to the uBoot environment variables:
arcNumber 3089is needed to identify the device as a GoFlex Net. Otherwise the SATA drives will not be recognised. Secondly, when migrating the rootfs from the USB stick to one of the SATA disks, it is important to label the new disk partition as "rootfs" - the guide labels it as rootfs_hd. Once complete, I set up the AFP file shares in Openmediavault and the drives were visible on my network. Success!
Custom NAS case
But the form factor of the device is not ideal, and the stock housing will not accomodate the larger 3.5" drives, so some form of alternate housing is required. After a bit of thinking, I remembered an old rackmount server I had taking up space. It has three hot swap drive bays for SAS SCSI drives - but since all 3.5" drives are a standard size, I knew that the bays should be able to house SATA drives instead.
I stripped out the server's innards, leaving just the drive caddies and casing. Then I drilled and cut the casing to remove the superfluous rear section and top cover, to leave the drive bays, front panel, and a small section of floor to mount the GoFlex and cables to.
I needed to use SATA extension cables to connect the drives to the GFN, and decided to create new SATA back panels for the drive bays, so that the drive caddies can be inserted and removed from the front panel without fumbling for cables. I took some old steel PCI slot blanks, flattened them, and made two cuts along the long edge the width of a SATA connector apart, and then bent the resulting section of steel through 90° to act as a shelf for the connector. After epoxying the connector in place, I marked and cut the plates to length, and epoxied them to the end of the drive bays, with disks in place to make sure the connectors registered correctly.
So that gave me the possibility of sharing two SATA drives. But the USB port on the GoFlex Net got me thinking. I had an old USB hub/card reader sitting around, so as a test I tried removing the USB stick from the GFN and plugging it back in via the hub. It was recognised and booted perfectly, giving me three more USB ports to share things from. I fired up an old IDE external disk and plugged it into the hub and that too became available to share.
So the next things to try are:
- Get an IDE-to-USB converter, and hook up the third caddy via the USB hub
- Use a SATA-to-USB converter instead?
- Add a second GoFlex Net and add a third backplate, plus potentially a fourth drive at the back?
- Update OpenMediaVault software and try out additional plugins - Plex for instance?
- Replace the SATA ports on the GFN with horizontal orientation ones, so that I can enclose the back?
- Rewiring/extending the GFN LED arrays to the back plates of the caddies (to use the light pipes for activity and power in each caddy), or to the front panel, so that they can indicate disk activity?