Re: Looks like the arm 20220805 snapshots are still odd, so probably kern.geom.part.mbr.enforce_chs=0 was still in use
- Reply: Mark Millard : "Re: Looks like the arm 20220805 snapshots are still odd, so probably kern.geom.part.mbr.enforce_chs=0 was still in use"
- In reply to: Ed Maste : "Re: Looks like the arm 20220805 snapshots are still odd, so probably kern.geom.part.mbr.enforce_chs=0 was still in use"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 09 Aug 2022 18:15:13 UTC
On Tue, Aug 09, 2022 at 02:06:14PM -0400, Ed Maste wrote:
> On Sun, 7 Aug 2022 at 18:43, Glen Barber <gjb@freebsd.org> wrote:
> >
> > Will do. I’ll commit the suggested change to main tomorrow.
> >
> > Thank you for your vigilant investigation.
>
> Shall I commit the enforce_chs check now?
> ---
> commit 6ee7d69e6b526f35789b23ba570025f1c3b39c1a
> Author: Ed Maste <emaste@FreeBSD.org>
> Date: Tue Jul 19 16:47:49 2022 -0400
>
> release: ensure enforce_chs sysctl is 0
>
> We do not want CHS-based alignment for VM or SD card release images.
>
> Sponsored by: The FreeBSD Foundation
>
> diff --git a/release/tools/arm.subr b/release/tools/arm.subr
> index 6e4ae731a0b9..01c5303cd4e1 100644
> --- a/release/tools/arm.subr
> +++ b/release/tools/arm.subr
> @@ -62,6 +62,10 @@ umount_loop() {
> }
>
> arm_create_disk() {
> + if [ $(sysctl -n kern.geom.part.mbr.enforce_chs) != 0 ]; then
> + return 1
> + fi
> +
> # Create the target raw file and temporary work directory.
> chroot ${CHROOTDIR} gpart create -s ${PART_SCHEME} ${mddev}
> if [ "${PART_SCHEME}" = "GPT" ]; then
>
Good question. Do we still want to ensure it is set to '0'? I'm a bit
confused from the back-and-forth on the original thread.
If we do want to ensure it is set to '0', yes, please go ahead.
Glen