From 47d08f83df9ba39dbb87bfb2457dfa10cc6db9ef Mon Sep 17 00:00:00 2001 From: des Date: Fri, 13 Jan 2012 12:40:33 +0000 Subject: Provide a better explanation for the sizing of the boot partition, and reduce the size of the partition in the example from 128 blocks to 94 blocks so it will end on a 128-block boundary. Also remove the -b option from the next example. MFC after: 3 weeks --- sbin/geom/class/part/gpart.8 | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) (limited to 'sbin/geom') diff --git a/sbin/geom/class/part/gpart.8 b/sbin/geom/class/part/gpart.8 index a9c0cff..d8bf62a 100644 --- a/sbin/geom/class/part/gpart.8 +++ b/sbin/geom/class/part/gpart.8 @@ -960,17 +960,21 @@ partition that can boot from a .Cm freebsd-ufs partition, and install bootstrap code into it. -This partition must be larger than -.Pa /boot/gptboot , -or the GPT boot you are planning to write, but smaller than 545 KB. -A size of 15 blocks (7680 bytes) would be sufficient for -booting from UFS but 128 blocks (64 KB) is used in -this example to reserve some space for potential -future need (e.g.\& a larger +This partition must be larger than the bootstrap code +.Po +usually either +.Pa /boot/gptboot +or .Pa /boot/gptzfsboot -for booting from a ZFS partition). +.Pc , +but smaller than 545 kB since the first-stage loader will load the +entire partition into memory during boot, regardless of how much data +it actually contains. +This example uses 94 blocks (47 kB) so the next partition will be +aligned on a 64 kB boundary without the need to specify an explicit +offset or alignment. .Bd -literal -offset indent -/sbin/gpart add -b 34 -s 128 -t freebsd-boot ad0 +/sbin/gpart add -b 34 -s 94 -t freebsd-boot ad0 /sbin/gpart bootcode -p /boot/gptboot -i 1 ad0 .Ed .Pp @@ -978,7 +982,7 @@ Create a 512MB-sized .Cm freebsd-ufs partition to contain a UFS filesystem from which the system can boot. .Bd -literal -offset indent -/sbin/gpart add -b 162 -s 1048576 -t freebsd-ufs ad0 +/sbin/gpart add -s 512M -t freebsd-ufs ad0 .Ed .Pp Create an MBR scheme on -- cgit v1.1