Partitioning an OpenBSD disk

Special partitions

  • a: must be created on the root disk and used for the root filesystem (/).
  • b: must be created on the root disk and used as swap space.
  • c: represents the entire disk and must not be altered. (Just ignore it.)

Minimum sizes for a full installation

(root)	60MB
/usr	420MB (no X) or 550MB (with X)
/var	25MB
/tmp	50MB
swap	32MB

Considerations

  • It's a good idea to put user-writeable directories such as /home and /var/www in a separate partition. This helps if you want to set quotas and prevents problems with a user fills a partition.
  • More space in /var for internet facing machines. (Remember logs are kept in /var/log.)
  • Keep enough space in /usr/src if you expect to build lots of source code (eg. when rebuilding the system).
  • /tmp is used for building some software

Sizes that work for me

Below are sizes that worked fine for a machine with at least 115GB hard drive space. This should leave more than enough room to handle most tasks for the kind of servers I need. Space is left unallocated to leave room for expansion.

Partition	Filesystem	Size
a		(root)		200MB
g		/usr		10GB
e		/var		10GB
d		/tmp		1GB
b		swap		512MB
h		/home		50G

Resources