Date: Sun, 29 Dec 2019 21:32:52 +0100 From: Johan Hendriks <joh.hendriks@gmail.com> To: freebsd-questions@freebsd.org Subject: Re: Moving root on ZFS on GELI so GELI is no longer used Message-ID: <c617d2e9-b849-98df-199e-1afa84ab48fd@gmail.com> In-Reply-To: <20191229173722.EB89680060@mailuser.nyi.internal> References: <20191204223149.A880630600A8@mailuser.nyi.internal> <alpine.BSF.2.21.99999.352.1912050759190.5621@enterprise.ximalas.info> <20191229173722.EB89680060@mailuser.nyi.internal>
next in thread | previous in thread | raw e-mail | index | archive | help
Op 29-12-2019 om 18:37 schreef Kralj Karlo: > Trond Endrestøl writes: >> man zfs, searching for zfs snapshot, zfs send, and zfs receive. >> >> My take usually is: >> >> 1. Make sure boot partitions are present and populated on the new disk(s). >> The same for any swap partitions. > Could you elaborate on this step or refer to relevant man pages? > This is the step I don't know how to do. > _______________________________________________ > freebsd-questions@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org" I think he ment to create the same partition schema on the new disk and copy the boot code to the boot partition. I always use a GPT schema and never MBR, so i think it works for both schema's but i am not sure. To copy the partition layout of your active disk you can use the backup and restore option from gpart. # /sbin/gpart backup ada0 | /sbin/gpart restore -F ada1 ada2 To copy the bootcode you can do that with the following command. If you use EFI use both commands, if you do not use EFI only the gpart code. In this example, the efifat file is copied to the second partition of disk ada1. The boot code to the first partition of disk ada1 # dd if=/boot/boot1.efifat of=/dev/ada1p2 # gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada1 Replace ada1 with the device name of your new disk also change -i 1 if your bootcode is on another partition. regards Johan
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?c617d2e9-b849-98df-199e-1afa84ab48fd>