this post was submitted on 26 Jul 2023
10 points (91.7% liked)

Selfhosted

40041 readers
594 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

I’m looking to re-purpose an old desktop into a multi-purpose home server. I’m looking for some advise on how to set things up in a way that won’t bite me in the ass later. I’m a confident Linux user, but have limited docker experience. I’m looking at using TrueNAS scale for: straight cloud storage, syncthings, home assistant, and tailscale to access it. If things go swimmingly, I might add jellyfin or *arr apps.

Here’s the hardware I already have:

  • i7 6700
  • 32 GB DDR4 (non-ECC)
  • GTX 1060
  • Storage:
    • 1 TB NVME SSD
    • 250 GB SATA SSD
    • 4x 4 TB WD Black HDD

So, here are my noob questions:

  • Is this system capable enough to handle the things I want to do?
  • My first pass at research says I should use TrueCharts for Tailscale. For Home Assistant, should I also install through TrueCharts? I was reading that you can’t install community docker plugins for home assistant, but I’m not sure if that’s something I’ll need. I also don’t know if I that’s something I need. The alternative is a separate VM, but that seems a lot more complicated.
  • How should I set up my drives? Should the 1 TB NVME drive be the boot drive, is that better used for something else. I’ve done some basic reading on vdevs/pools, but I’m not sure how syncthings/home assistant/other apps fit into the picture. Any good resources you could point me to for understanding this better?
you are viewing a single comment's thread
view the rest of the comments
[–] surfrock66@lemmy.world 3 points 1 year ago* (last edited 1 year ago)

I'm not an expert, but I've been using TrueNas Scale since I cut over from TrueNAS core, and before that Freenas, since about 2010. I have a bunch of lessons and assumptions, but someone can correct me if these are misguided, they're my tl;dr of knowledge.

  1. Your data drives should be in sets of 3 for a raidz1, or 5+ (I use 6) for a raidz2. While technically the minimum is 2 or 4 respectively, best performance and protection comes in sets of 3. This is a good synopses: https://superuser.com/a/1058545 In that case he points out that a 3-way mirror also works but then you lose a lot of the data integrity checking that comes with ZFS. I keep an offline spare; in your situation putting 3 drives in with a RAIDZ1 and keeping one in the drawer would give you ~8TB of capacity protected against bit flipping and drive failure. This is a better description of the raid levels: https://calomel.org/zfs_raid_speed_capacity.html
  2. In terms of just storage, that system will be fine, though ideally you get ECC RAM; that's often a bigger swap, so if you can't change that, so be it. It does matter in terms of integrity checking. The more containers you run, the tougher it gets to spec out. I have a separate proxmox hypervisor and routinely have 4+ jellyfin streams going at a time, so it wouldn't be enough in my case, but you'll have to experiment and scale. I will say, even though a separate proxmox box comes with a lot of headaches, it was more important than any schooling I ever did in terms of my IT career. Networking, monitoring, access control, suddenly I have a solution to every IT problem I encounter and I have experience with it.
  3. Personally, I do a 2-disk mirror for the OS, and then multiple 3 or 6 disk vdevs for data. If you lose the OS drive and it's just 1, that's fine if you have backups to just restore, but I find swapping in a cheap ssd is better. I use cheap-as-dirt 64G SSD's as the boot drives, and if one dies, you can swap it and replace it in the UI, no problem. You can technically use 2 mis-matched sized disks, but it'll fuss at you.
  4. Start with TrueNAS Scale as just a storage device; ideally that needs to be close to the hardware and not virtualized. In the beginning, especially since you're likely dealing with 1 pool, just make 1 vdev for everything. You can make folders in there, or datasets, and play with partitioning data, sharing data to other computers, etc. I use NFS sharing AND iscsi luns to my proxmox, and ultimately I'm in 1 big dataset with multiple vdevs in it. Add your things like homeassistant one at a time; going through it will show you how you sort storage, how you provision it, etc. Over time, things grow; this will not be your final configuration, most people expand over time. You may decide "I want bulk storage in one vdev, I want containers and vm's in another." When you expand, that's when you split things off and make more nuanced decisions. That will come from better assessing your needs.

You mention Jellyfin...my struggles with that were never storage. My struggles there were networking; it was a big part of why I decided to upgrade my server networking to 10G, which supported running Jellyfin on another hypervisor and having all that go over the network.