Where to mount a storage volume?

I am currently exploring FreedomBox in a VM. I want to write about it for The Register; I am planning an article on how to remove or reduce cloud dependencies.

I installed it using the Debian “Blend”. It’s running fine.

What I can’t find in the docs or anywhere is this: where does Freedombox store the users’ data?

I plan to install it on an old spare HP Microserver I have here. This has a removable drive for the OS, and a roughly 1TB disk array in Linux mdraid RAID-5.

So my plan is to install Debian and Freedombox on the USB boot drive, and mount the RAID somewhere so that Freedombox keeps my files there.

Where should I mount the volume?

/var/lib/containerstorage?

/var as a whole?

Welcome @lproven!

Generally FreedomBox apps store user data under /var/lib in a folder for the app such as /var/lib/minidlna

If you want to have the intended FreedomBox experience then consider just putting all your storage into a BTRFS root partition. The reason for this is that the original target systems for FreedomBox were small plug servers, maybe with a single SD card for storage such as the FreedomBox Pioneer, where storage economy was necessary.

I am running FreedomBox on a PC and I didn’t agonize over filesystem layout at all. All disks are part of a BTRFS RAID-1 mounted on /, and I don’t use md. This way has made me happy, but I had to break my sysadmin conditioning (“the users would fill up / and break the server!”) It will actually be fine.

2 Likes

Generally FreedomBox apps store user data under /var/lib in a folder for the app such as /var/lib/minidlna

Aha. OK. So would it be plausible to mount the existing RAID at /var/lib and just capture all the dynamic/changeable stuff that way?

If you want to have the intended FreedomBox experience

Well, TBH, I am still trying to work out what that is. The docs are somewhat inadequate, IMHO. (I speak as a former docs person at Red Hat and SUSE.)

then consider just putting all your storage into a BTRFS root partition.

Oh $deity no!

As I said: former SUSE member of staff. I ran openSUSE as my daily driver for 4 years. In 30+ years of using Linux I have never seen any filesystem self-destruct as often or as badly as Btrfs. I will never trust it again. Btrfs RAID even less so.

2 Likes

That’s basically what I said to myself as I committed to this course of action years ago. If I don’t like it, I said, I can always reinstall it. It’s not Best PracticeTM, I said. Here I am after years without data loss. I’ve had a disk fail, I snagged a disk carriage with a network cable and disconnected it before leaving town for weeks. It’s all good. Better than my experience with some of the “reliable” filesystems in point of fact. I have not had a / full disaster. I have not had to resize partitions. The results speak for themselves.

I learned about FreedomBox because I pay attention to Eben Moglen from time to time. I chose FreedomBox because I wanted to replace my rubbish ISP router - I needed something reliable. I continue using FreedomBox because it’s a little box in the corner that I just ignore and it continues to soldier on with little intervention. For me the integrated applications were a bonus. As you are looking at the state of cloud replacement the FreedomBox integrated app I most appreciate now is BePasty where I can share a private document with no cloud intermediary and keep it encrypted in transit.

Regards

3 Likes

Fair enough, and thanks!

I have little truck with “best practice” myself. I’ve been in this business nearly 40 years and the designs I trust are ones where the person can explain them, not invoke some higher power. “Best practice” to me means “it’s traditional, don’t ask me why.” :wink:

Snag is, as I said, the box I have in mind has 4 identical HDDs in a RAID and there’s nowhere to install an OS – or, importantly, to put swap. It only has 3 GB RAM.

And yes, I pay attention to Mr Moglen too. One smart cookie.

Thank you for the feedback and the info!

3 Likes

@lproven Thank you for today’s article about FreedomBox in The Register.

With the availability of hardware with multiple hard drives we started to pay attention to setting up and managing RAID with simplified user interface. This will be software RAID based on mdadm (with likely btrfs on top). In addition to this, we are focusing on changing data storage locations for all the major applications to a configurable location (some applications already allow this). These features are expected in first half of 2026.

In general, we had good results with btrfs so far. There were no reports of filesystem corruptions from users who’s hardware was intact. With the snapshots feature (managed by snapper), FreedomBox automatically takes snapshots according to a schedule and whenever new software is installed or upgraded. This allows bad software updates and some manual misconfigurations to be reverted.

For your setup, mounting /var/lib as the RAID partition is a possibility. Don’t use the filesystem snapshot/revert feature in this case as it may do what we expect (as snapshots don’t work across filesystems).

2 Likes

Sorry for the slow reply – been busy visiting FOSDEM and things.

Thank you for today’s article about FreedomBox in The Register.

:slight_smile: Well spotted. Yes, that’s me. I have not yet deployed it on hardware – given the limitations of the RAID support right now, I am wondering what I can productively do with it.

we started to pay attention to setting up and managing RAID with simplified user interface

There are of course some existing tools for this; Webmin has some quite good ones in the general direction. Sadly, for now, Gparted and its kin do not, AFAIK.

This will be software RAID based on mdadm

Fine: sensible, pragmatic, works.

(with likely btrfs on top)

Not fine, not sensible, not pragmatic; I would strongly advise against this. I have written at length on the Reg about the problems with Btrfs and after seeing more total-data-loss incidents on Btrfs in 4 years working at SUSE than in the previous 20 years using ext2/ext3/ext4 I would never trust Btrfs again.

Ars nailed it:

“Perpetually half-finished”. That was 5Y ago and it is not materially better in any way.

I’d prefer to trust Bcachefs or ZFS as an external module than Btrfs.

Snapper increases its fragility by several orders of magnitude. Fedora only gets away with Btrfs because it has no snapshots. This is the worst combination.

1 Like

I’m in agreement with reducing and controlling the quantity of snapshots and I advocate for using BTRFSmaintenance to automate scrub, defrag for mechanical disk, and trim to deactivate unused cells in solid state devices.

That was a nice article, I think of FreedomBox as the “small” solution and I was pleased to read your thoughts on the overall level of functionality and quality. I don’t think of it as a compromise at all after reading. :+1: