aboutsummaryrefslogtreecommitdiff
path: root/blog/posts/building_a_normal_server/index.md
diff options
context:
space:
mode:
Diffstat (limited to 'blog/posts/building_a_normal_server/index.md')
-rw-r--r--blog/posts/building_a_normal_server/index.md20
1 files changed, 11 insertions, 9 deletions
diff --git a/blog/posts/building_a_normal_server/index.md b/blog/posts/building_a_normal_server/index.md
index c455814..621ceeb 100644
--- a/blog/posts/building_a_normal_server/index.md
+++ b/blog/posts/building_a_normal_server/index.md
@@ -1,12 +1,12 @@
I spent the past few months making full use of all my physical engineering talents to build a NAS that is completely normal, and not weird at all, and involved an amount of 3D modeling, 3D printing, and hacksawing that is entirely typical of most home computer builds, all in the name of reusing an old laptop.
-## The Goal
+# The Goal
My previous daily driver computer and current home server is a mid-range gaming laptop from late 2019 that, due to a flat lithium battery and a broken trackpad resulting from a botched storage upgrade, has been rendered more or less useless as an actual portable computer. Boasting an Intel i7-9750H, an Nvidia GTX 1660-Ti, and 16 gigabytes of aftermarket DDR4, this baby has plenty enough power to play Elite Dangerous at a buttery smooth ~90FPS, while generating enough heat to add that extra layer of immersion while flying dangerously close to main-sequence stars to harvest hydrogen from their outer atmospheres. It's also good for Minecraft servers.
Now that it's in use as a home server, I find that the in-built 256 gigs of solid-state storage isn't really enough for my purposes. Now, it's plenty for one or two game servers, which is what I was using it for, but most other applications such as backups or media servers (which I would quite like to have) would be a bit stifled by that amount of space. Hence, a significant storage upgrade is in order.
-## The Method
+# The Method
There's a few ways I could go about this. My laptop actually has a decent amount of upgradeability, with a full-sized NVMe drive slot and a 2.5" SATA drive bay. The simplest, least janky, and most boring solution here would be to buy two high-capacity SSDs, throw 'em in there and be done.
@@ -16,17 +16,19 @@ Next option: USB external drives. External HDD solutions such as the WD MyBook a
Issue the first with this idea is that these hard drives take more power in a weirder voltage configuration than a USB port is equipped to deliver, so unless I want to teach myself electrical engineering each one will require its own power cable, which after the first drive gets sketchy fast:
-![Hooking up three hard drives with this configuration means a whopping FOUR power cables for one server. Unacceptable.](media/power_spaghet.png)
+<figure class="media">
+ <img src="media/power_spaghet.png" alt="Hooking up three hard drives with this configuration means a whopping FOUR power cables for one server. Unacceptable.">
+</figure>
Issue the second is that USB is just not the right tool for the job here. USB is designed for hot-plugging peripherals, not semi-permanent internal aspects of a hardware configuration, so trying to pull any fancy shit like RAID or even just relying on all the drives being *recognized* every boot opens the door to all sorts of weird, unfixable problems. In other words, it's very janky, and I'd rather just not deal with all that.
Of course, the reasonable way to build a NAS would be to get a machine that's actually fit for that purpose, like an off-the-shelf NAS box or a custom computer in a case with a lot of drive bays or something. I'd also rather not do this. I mean, I already have all this perfectly good computing power right here! I can't just let it go to waste. What I actually did is as follows:
-## The Madness
+# The Madness
I decided to buy internal PC hard drives and hook them up to the laptop using internal connectors. This would avoid the reliability concerns of USB, and allow me to use off-the-shelf components to power all the drives off of one AC outlet, at a much cheaper price per terabyte than either of the above options. Given most laptops aren't really equipped with the requisite hardware to make such an upgrade, this presented three major problems that I was about to have a lot of fun solving.
-### Problem the First: Data Connections
+## Problem the First: Data Connections
Generally, adding internal HDDs to a computer requires the use of an internal SATA connector. My laptop has one, and I will be using it, but I'd quite like to have more than one of these drives, both for redundancy and raw capacity, so I need a way to add more. In a desktop PC, such expansion would typically be done using a spare PCIe slot on the motherboard:
@@ -65,7 +67,7 @@ This feels a little like forbidden dark magics to me, and it probably isn't grea
Don't mind the fact that I had to cut holes in the bottom of my laptop to hook stuff up to the SATA ports. Just, um, ignore that.
-### Problem the Second: Powering All This Crap
+## Problem the Second: Powering All This Crap
Now that I've got my laptop *talking* to all these drives, they need power. I'm sure I could get this from the laptop somehow, but I'm not an electrical engineer, and the point of this project is to *not* have to buy a new computer, so I'll have to get it from elsewhere.
@@ -102,7 +104,7 @@ And furthermore, photos of the SATA splitter working:
</picture>
</div>
-### Problem the Third: A Case
+## Problem the Third: A Case
I could run this whole setup naked, strewn out across my desk, but I'm not doing that, so I'll need a case. Unfortunately, they don't make computer cases designed for this use case. I shall have to build my own.
@@ -145,11 +147,11 @@ I wanted to make some kind of fancy bespoke mount for the laptop, but that turne
IT'S ALIIIIIVE!!!
-## Software
+# Software
This post is mostly about my fucked up hardware, but I figured I should share my software setup too. It's TrueNAS. I went with it because it boasts a lot of fancy features and smooths out a lot of processes that I was intimidated by the idea of doing manually in the terminal. This is probably the most normal part of the build by far, and I think some of the jankiness of the hardware side has infected it. I tried to run Syncthing on it and it just... didn't take. I don't know how else to describe it. TrueNAS is pretty good though.
-## Postmortem
+# Postmortem
As of writing, I've been running this thing for a couple months now, and it's been pretty good. I haven't done a lot with it yet beyond some basic backups and a Jellyfin server that I have yet to make accessible from outside my LAN, but it's been mostly reliable so far. It even survived a power outage once with no issue, though I'm currently looking into UPS solutions to make sure that doesn't happen again. All that isn't to say I'm completely happy with it, though.