Setting up BTRFS subvolumes in Slackware
by tauka_usanake from LinuxQuestions.org on (#6EW7B)
Third question here on the forums, continuing my adventure with Slackware and got a decent system working so far. My next task at hand is setting up my BTRFS file system for snapshots. Unlike some other distros that set up subvolumes for directories/mount points by default, Slackware does not. I would like to set /home as a subvolume as well as maybe a few other points (/tmp is one so it's excluded from snapshots). Quick aside: I have my swap on a separate drive taking up the whole disk so I shouldn't have to include that as a subvolume?
I've read about BTRFS and others who have the same problem that I have, but I'm having trouble wrapping my head around the instructions being provided. They include making a snapshot of the BTRFS system, removing everything that's NOT what you want to turn into a subvolume, and then use that to make a subvolume? It doesn't make sense.
I'm wondering if I could just boot into root (or better yet the install disk) and mount my file system, rename my old /home to something like /home_old, create a subvolume /home, and then move everything into it. The same for /tmp, except I probably don't have to rename it and just nuke and build. I'm aware I'll have to edit my fstab file to account for the new subvolume mount points. I'd like to know if what I'm considering would work, or if there are easier instructions I could follow to get the result I want.
Aside two: I might just turn /tmp into a tmpfs and run it in RAM, but that's another experiment for later.
Please and thank you!
I've read about BTRFS and others who have the same problem that I have, but I'm having trouble wrapping my head around the instructions being provided. They include making a snapshot of the BTRFS system, removing everything that's NOT what you want to turn into a subvolume, and then use that to make a subvolume? It doesn't make sense.
I'm wondering if I could just boot into root (or better yet the install disk) and mount my file system, rename my old /home to something like /home_old, create a subvolume /home, and then move everything into it. The same for /tmp, except I probably don't have to rename it and just nuke and build. I'm aware I'll have to edit my fstab file to account for the new subvolume mount points. I'd like to know if what I'm considering would work, or if there are easier instructions I could follow to get the result I want.
Aside two: I might just turn /tmp into a tmpfs and run it in RAM, but that's another experiment for later.
Please and thank you!