17
submitted 1 year ago by Aarkon@feddit.de to c/linux@lemmy.ml

I've got a reoccurring issue with all of the home servers I've ever had and because it happened again just today, now the pain is big enough to ask publicly about it.
As of now, I'm running some Intel NUC ripoff with a JBOD attatched via USB 3, spinning a ZFS sort of-RAID. It's nothing that special tbh. In the past I had several other configurations with external drives, wired via fstab to Raspberry Pis and the like. All of those shared a similar issue: I can't recall exactly when, but I figure most of the time after updates to the kernel or docker, the computer(s) become stuck at boot. I had to unplug the external drives just to get the respective machine up, after which varying issues occurred with drives not being recognized anymore and such.

With my current setup, I run several docker containers which have their volumes on subdirectories/datasets on the /tank mountpoint, and when booting the machine without the drives, some of the containers create new directories at that destination, which now lives on my main drive /dev/sda.
It's not only painful to go through the manual process with the drives, I only have access the machine when I'm home, which I'm not all the time. Also, it's kind of time consuming as I'm backup up data that I fear might become inconsistent along the way. Every time I see a big kernel update, I fear that the computer will get stuck in such a situation once again and I'm reluctant to do a proper reboot.

I know that external drives are not best practice when it comes to handling "critical" data, but I don't want to run another machine just in order to provide access to the disks via network. Any ideas where these issues stem from and how to avoid them in the future?

you are viewing a single comment's thread
view the rest of the comments
[-] qwesx@kbin.social 6 points 1 year ago* (last edited 1 year ago)

Do you mount the drives using their /dev/sdX entries or via UUID? Because it sounds like you're using /dev/sdX entries (which you really shouldn't, because their names can randomly change, by design). Use /dev/disk/by-id/... directly for mounting or, alternatively, fill /etc/zfs/vdev_id.conf (see example below) and define the pool using their aliases.

alias Bay1 /dev/disk/by-id/ata-XXXXXXXXXXX1-YYYYY1_ZZZZZZZ4
alias Bay2 /dev/disk/by-id/ata-XXXXXXXXXXX2-YYYYY2_ZZZZZZZ4
alias Bay3 /dev/disk/by-id/ata-XXXXXXXXXXX3-YYYYY3_ZZZZZZZ4
alias Bay4 /dev/disk/by-id/ata-XXXXXXXXXXX4-YYYYY3_ZZZZZZZ4

[-] Aarkon@feddit.de 1 points 1 year ago

I use the ZFS mechanism exclusively today, so I'll have a look at the vdev_id.conf file as soon as I find the time, thank you!

Also, sorry for not responding earlier, I've had some busy days.

this post was submitted on 01 Nov 2023
17 points (90.5% liked)

Linux

48224 readers
654 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS