chevybeef.com

A mainly OpenBSD focused collection of how to's.

Change to single partition post install

Posted on: 13 Jan 2024

You can change OpenBSD to run using a single partition after doing a default installation. You might rightly ask why on earth you would want to do this, after all the FAQ “encourages users to split their disk into a number of partitions”. Well it’s great if you have a large disk and in a secure implementation but what if you just want to run on a single partition to make better use of the disk or virtual disk space.

Requirements and disclaimer

Just because it can be done doesn't mean it should be done.

References

http://www.openbsd.org/faq/faq4.html#Partitioning
http://www.openbsd.org/faq/faq14.html

Basic Steps

    cd /home && tar cf – . | (cd /mnt/home && tar xpf – )
    cd /usr && tar cf – . | (cd /mnt/usr && tar xpf – )
    cd /var && tar cf – . | (cd /mnt/var && tar xpf – )
    mount /dev/wd1a /mnt and /dev/wd0a /mnt2
    cd /mnt && tar cf – . | (cd /mnt2 && tar xpf – )