On Mon, Oct 20, 2025 at 09:20:00PM -0400, Scott Vargovich wrote:
> I would like to know if the
> default partitioning scheme puts /home on its own partition so I don't lose
> what I have in /home if the system crashes and I need to reinstall.  Would
> that even be an issue I need to be concerned about?

The quick answer here is that it probably isn't an issue to be concerned
about - as long as you understand how OpenBSD differs from a typical Linux
installation in terms of partitioning.

If you have a lot of Linux experience, there may be the temptation to try to
apply that knowledge to OpenBSD, and disk partitioning is one area where doing
that might trip you up.

Unless you are installing OpenBSD in a very constrained amount of disk space,
then the installer will, by default, put /home on a separate _disklabel_
partition.

This means that you can freely overwrite other disklabel partitions without
touching the data on /home.

However, if you re-install OpenBSD on the same disk and accept the defaults,
then the installer _will overwrite_ that separate /home partition, (and create
a new one of the same size and in the same place, but empty).

So if your question was really more like, "does having /home on a separate
disklabel partition allow me to freely re-install OpenBSD and preserve user
data", then the answer is NO.

If you want to have that flexibility, there are ways of doing it.

The easiest way, if this is a desktop machine, is to install a second physical
disk and put /home on that.  Since it's a separate volume with it's own
disklabel, if you later re-install the system on the primary disk, then the
installer doesn't even need to know that /home exists on the second disk.
You could just re-install without defining a /home partition and then add it
to the fstab once the install is completed and you reboot in to the new
system.

There are ways of doing it on a single disk.  I wouldn't recommend any of
those at this point for your first real non-VM OpenBSD machine, because they
add complexity and create a system that is more easily screwed up by simple
errors.

At the end of the day, the better way to achieve what you want to do,
(facilitate re-installs without having to do excessive backup and restores),
on an OpenBSD system is to either:

* Put /home on a separate physical disk.

or

* Create a small /home for user configuration files and work in progress, and
  put your precious unchanging data elsewhere.

And of course, if you care about your data, you should have: BACKUPS.

Reply via email to