Re: Default MBR boot "manager"
On 11/11/13 18:22, Julian Elischer wrote: On 11/11/13, 1:32 PM, Nathan Whitehorn wrote: On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. This patch looks good (I don't remember why it was boot0 in the first place). I think gpart automatically installs something like /boot/mbr by default, so I'd be interested to know if making the diff purely negative still works. On another note, I think we should move away from a selector. Right now, we have three kinds of boot code: 1. ZFS boot code 2. UFS boot code 3. boot0 you forget network booting. That isn't something written to disk, though (unless you are doing something really weird), so probably isn't relevant for a partitioning tool. -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On 11/11/13, 1:36 PM, Nathan Whitehorn wrote: On 11/11/13 15:35, Allan Jude wrote: On 2013-11-11 16:32, Nathan Whitehorn wrote: On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. This patch looks good (I don't remember why it was boot0 in the first place). I think gpart automatically installs something like /boot/mbr by default, so I'd be interested to know if making the diff purely negative still works. On another note, I think we should move away from a selector. Right now, we have three kinds of boot code: 1. ZFS boot code 2. UFS boot code 3. boot0 Unifying 1 and 2 would help a lot -- I don't know of any reason we need both except for tradition. #3 is probably best done as a post-install config step ("Install FreeBSD boot manager" or something), which also means it works for UFS systems. -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org" You have to do down right evil things to boot ZFS on MBR. dd'ing the 'remainder' of the boot loader into a reserved space at the head of the ZFS partition. The GPT boot code is 14k, and the code to boot ZFS is 40k, whereas the UFS stuff is 512 bytes and fits in the intended slot. for mbr/zfs , just declare a zfs-boot slice type, and put it in there sure it complicates it a bit but it is basically what happens in gpt right? We could just decide we won't support booting from ZFS on MBR. For GPT, there is no size limit, which simplifies everything. -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org" ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On 11/11/13, 1:32 PM, Nathan Whitehorn wrote: On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. This patch looks good (I don't remember why it was boot0 in the first place). I think gpart automatically installs something like /boot/mbr by default, so I'd be interested to know if making the diff purely negative still works. On another note, I think we should move away from a selector. Right now, we have three kinds of boot code: 1. ZFS boot code 2. UFS boot code 3. boot0 you forget network booting. Unifying 1 and 2 would help a lot -- I don't know of any reason we need both except for tradition. #3 is probably best done as a post-install config step ("Install FreeBSD boot manager" or something), which also means it works for UFS systems. -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org" ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On Nov 11, 2013, at 2:57 PM, Nathan Whitehorn wrote: > On 11/11/13 15:51, Teske, Devin wrote: >> On Nov 11, 2013, at 1:43 PM, Nathan Whitehorn wrote: >> >>> On 11/11/13 15:39, Teske, Devin wrote: On Nov 11, 2013, at 1:32 PM, Nathan Whitehorn wrote: > On 11/11/13 15:19, Teske, Devin wrote: >> Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... >> >> Should we do the quick patch to change the default >> from /boot/boot0 to /boot/mbr: >> >> Index: zfsboot >> === >> --- zfsboot (revision 258016) >> +++ zfsboot (working copy) >> @@ -764,7 +764,7 @@ zfs_create_diskpart() >> # >> f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk >> || >> return $FAILURE >> - f_eval_catch $funcname gpart "$GPART_BOOTCODE" >> /boot/boot0 \ >> + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr >> \ >> \$disk || return $FAILURE >> >> # >> >> That would fix things for Lenovo laptops for the next >> release until I finish up the bootcode selection menu. >> I'd like to take my time in making sure Allan and I design >> a worthy bootcode selection menu. > This patch looks good (I don't remember why it was boot0 in the first > place). I think gpart automatically installs something like /boot/mbr by > default, so I'd be interested to know if making the diff purely negative > still works. > > On another note, I think we should move away from a selector. Right now, > we have three kinds of boot code: > 1. ZFS boot code > 2. UFS boot code > 3. boot0 > > Unifying 1 and 2 would help a lot -- I don't know of any reason we need > both except for tradition. #3 is probably best done as a post-install > config step ("Install FreeBSD boot manager" or something), which also > means it works for UFS systems. Well, I'm sensitive to the fact that sysinstall offered "none" and even explained why in an F1 dialog that brought up "drives.hlp" to explain that you might want to keep whatever (alternate) boot manager you may be using already. In a proposed selector, the full breadth of options that I was envisioning was: GPT + gptboot GPT + none (use your existing boot manager... syslinux?) MBR + mbr MBR + boot0 MBR + none (again, BYOBM) Hadn't got around to zfsboot yet. Where would that go? at the top? GPT + zfsboot ? (and of course, this is x86 specific... I was gleaning from sysinstall that for systems like pc98, they call it an IPL and there's only two options... a standard IPL or bring your own boot manager, aka "none"). I imagine that there would be architectures that are like the ol' pc98, wherein they don't have all these options (is, for example? sparc64 GPT only?) >>> This would be super-unportable. SPARC uses VTOC8, for example, and doesn't >>> support GPT at all. PC98 has the differences you mentioned. PowerPC uses >>> MBR sometimes, sometimes APM, sometimes GPT. You never have a choice. No >>> platforms except x86 have any analog to boot0. Etc, etc. This is why I'd >>> like to pull ZFS into partedit, which already knows how to set up >>> everything and does the right thing everywhere. For the only system (x86) >>> where there is a real choice (do you want to replace whatever you have >>> already with boot0?), it makes sense to do this as a post-install config. >> Two migration paths before us, and I do rather like the idea of >> benefiting from all your work there. >> >> My biggest concern is how to maximize functionality in the >> migration of the ZFS stuff to partedit. >> >> You know the code better there better than I, ... have you given >> much thought to how you might integrate what we've done? > > Some, though not as much as it deserves. The general idea would be to treat > ZFS as a kind of partitioning. I don't think we can realistically expose all > ZFS features through the installer. > >> It's sad that we would be giving up i18n, X11, and discrete >> scripting (surely there are more parts to ZFS than what partedit >> supports now -- e.g., datasets, etc.). >> >> Naturally, the scripting can be solved. i18n is a bit harder to >> solve as it's a "start from the bottom" venture. And I fear X11 is >> a lost cause in its current state for partedit. > > This is a pity. I'm not sure what to do there. Would be nice to have > something libdialog-alike for X, but that leaves all these other issues too. No matter which way I look at it, that sounds like a lot of work. One way is that it would just fork-exec Xdialog and return the results. Another way would be interfacing with an actual
Re: Default MBR boot "manager"
On 11/11/13 15:51, Teske, Devin wrote: On Nov 11, 2013, at 1:43 PM, Nathan Whitehorn wrote: On 11/11/13 15:39, Teske, Devin wrote: On Nov 11, 2013, at 1:32 PM, Nathan Whitehorn wrote: On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. This patch looks good (I don't remember why it was boot0 in the first place). I think gpart automatically installs something like /boot/mbr by default, so I'd be interested to know if making the diff purely negative still works. On another note, I think we should move away from a selector. Right now, we have three kinds of boot code: 1. ZFS boot code 2. UFS boot code 3. boot0 Unifying 1 and 2 would help a lot -- I don't know of any reason we need both except for tradition. #3 is probably best done as a post-install config step ("Install FreeBSD boot manager" or something), which also means it works for UFS systems. Well, I'm sensitive to the fact that sysinstall offered "none" and even explained why in an F1 dialog that brought up "drives.hlp" to explain that you might want to keep whatever (alternate) boot manager you may be using already. In a proposed selector, the full breadth of options that I was envisioning was: GPT + gptboot GPT + none (use your existing boot manager... syslinux?) MBR + mbr MBR + boot0 MBR + none (again, BYOBM) Hadn't got around to zfsboot yet. Where would that go? at the top? GPT + zfsboot ? (and of course, this is x86 specific... I was gleaning from sysinstall that for systems like pc98, they call it an IPL and there's only two options... a standard IPL or bring your own boot manager, aka "none"). I imagine that there would be architectures that are like the ol' pc98, wherein they don't have all these options (is, for example? sparc64 GPT only?) This would be super-unportable. SPARC uses VTOC8, for example, and doesn't support GPT at all. PC98 has the differences you mentioned. PowerPC uses MBR sometimes, sometimes APM, sometimes GPT. You never have a choice. No platforms except x86 have any analog to boot0. Etc, etc. This is why I'd like to pull ZFS into partedit, which already knows how to set up everything and does the right thing everywhere. For the only system (x86) where there is a real choice (do you want to replace whatever you have already with boot0?), it makes sense to do this as a post-install config. Two migration paths before us, and I do rather like the idea of benefiting from all your work there. My biggest concern is how to maximize functionality in the migration of the ZFS stuff to partedit. You know the code better there better than I, ... have you given much thought to how you might integrate what we've done? Some, though not as much as it deserves. The general idea would be to treat ZFS as a kind of partitioning. I don't think we can realistically expose all ZFS features through the installer. It's sad that we would be giving up i18n, X11, and discrete scripting (surely there are more parts to ZFS than what partedit supports now -- e.g., datasets, etc.). Naturally, the scripting can be solved. i18n is a bit harder to solve as it's a "start from the bottom" venture. And I fear X11 is a lost cause in its current state for partedit. This is a pity. I'm not sure what to do there. Would be nice to have something libdialog-alike for X, but that leaves all these other issues too. One option would be to factor out the important bits of partedit longer-term, similar to the way to the scripting interface exists now (e.g. format this disk with these partitions, make the first one bootable, I don't care how it's done) and then call that from something prettier. Interactivity and the complexity of the things you can do with GEOM makes doing that fully hard, however (even the existing functionality ended up requiring kernel patches). -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On Nov 11, 2013, at 1:43 PM, Nathan Whitehorn wrote: > On 11/11/13 15:39, Teske, Devin wrote: >> On Nov 11, 2013, at 1:32 PM, Nathan Whitehorn wrote: >> >>> On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. >>> This patch looks good (I don't remember why it was boot0 in the first >>> place). I think gpart automatically installs something like /boot/mbr by >>> default, so I'd be interested to know if making the diff purely negative >>> still works. >>> >>> On another note, I think we should move away from a selector. Right now, we >>> have three kinds of boot code: >>> 1. ZFS boot code >>> 2. UFS boot code >>> 3. boot0 >>> >>> Unifying 1 and 2 would help a lot -- I don't know of any reason we need >>> both except for tradition. #3 is probably best done as a post-install >>> config step ("Install FreeBSD boot manager" or something), which also means >>> it works for UFS systems. >> Well, I'm sensitive to the fact that sysinstall offered "none" and >> even explained why in an F1 dialog that brought up "drives.hlp" >> to explain that you might want to keep whatever (alternate) boot >> manager you may be using already. >> >> In a proposed selector, the full breadth of options that I was >> envisioning was: >> >> GPT + gptboot >> GPT + none (use your existing boot manager... syslinux?) >> MBR + mbr >> MBR + boot0 >> MBR + none (again, BYOBM) >> >> Hadn't got around to zfsboot yet. Where would that go? at the top? >> >> GPT + zfsboot ? >> >> (and of course, this is x86 specific... I was gleaning from sysinstall >> that for systems like pc98, they call it an IPL and there's only two >> options... a standard IPL or bring your own boot manager, aka "none"). >> >> I imagine that there would be architectures that are like the ol' pc98, >> wherein they don't have all these options (is, for example? sparc64 >> GPT only?) > > This would be super-unportable. SPARC uses VTOC8, for example, and doesn't > support GPT at all. PC98 has the differences you mentioned. PowerPC uses MBR > sometimes, sometimes APM, sometimes GPT. You never have a choice. No > platforms except x86 have any analog to boot0. Etc, etc. This is why I'd like > to pull ZFS into partedit, which already knows how to set up everything and > does the right thing everywhere. For the only system (x86) where there is a > real choice (do you want to replace whatever you have already with boot0?), > it makes sense to do this as a post-install config. Two migration paths before us, and I do rather like the idea of benefiting from all your work there. My biggest concern is how to maximize functionality in the migration of the ZFS stuff to partedit. You know the code better there better than I, ... have you given much thought to how you might integrate what we've done? It's sad that we would be giving up i18n, X11, and discrete scripting (surely there are more parts to ZFS than what partedit supports now -- e.g., datasets, etc.). Naturally, the scripting can be solved. i18n is a bit harder to solve as it's a "start from the bottom" venture. And I fear X11 is a lost cause in its current state for partedit. -- Devin _ The information contained in this message is proprietary and/or confidential. If you are not the intended recipient, please: (i) delete the message and all copies; (ii) do not disclose, distribute or use the message in any manner; and (iii) notify the sender immediately. In addition, please be aware that any message addressed to our domain is subject to archiving and review by persons other than the intended recipient. Thank you. ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On 11/11/13 15:39, Teske, Devin wrote: On Nov 11, 2013, at 1:32 PM, Nathan Whitehorn wrote: On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. This patch looks good (I don't remember why it was boot0 in the first place). I think gpart automatically installs something like /boot/mbr by default, so I'd be interested to know if making the diff purely negative still works. On another note, I think we should move away from a selector. Right now, we have three kinds of boot code: 1. ZFS boot code 2. UFS boot code 3. boot0 Unifying 1 and 2 would help a lot -- I don't know of any reason we need both except for tradition. #3 is probably best done as a post-install config step ("Install FreeBSD boot manager" or something), which also means it works for UFS systems. Well, I'm sensitive to the fact that sysinstall offered "none" and even explained why in an F1 dialog that brought up "drives.hlp" to explain that you might want to keep whatever (alternate) boot manager you may be using already. In a proposed selector, the full breadth of options that I was envisioning was: GPT + gptboot GPT + none (use your existing boot manager... syslinux?) MBR + mbr MBR + boot0 MBR + none (again, BYOBM) Hadn't got around to zfsboot yet. Where would that go? at the top? GPT + zfsboot ? (and of course, this is x86 specific... I was gleaning from sysinstall that for systems like pc98, they call it an IPL and there's only two options... a standard IPL or bring your own boot manager, aka "none"). I imagine that there would be architectures that are like the ol' pc98, wherein they don't have all these options (is, for example? sparc64 GPT only?) This would be super-unportable. SPARC uses VTOC8, for example, and doesn't support GPT at all. PC98 has the differences you mentioned. PowerPC uses MBR sometimes, sometimes APM, sometimes GPT. You never have a choice. No platforms except x86 have any analog to boot0. Etc, etc. This is why I'd like to pull ZFS into partedit, which already knows how to set up everything and does the right thing everywhere. For the only system (x86) where there is a real choice (do you want to replace whatever you have already with boot0?), it makes sense to do this as a post-install config. -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On 2013-11-11 16:39, Teske, Devin wrote: > On Nov 11, 2013, at 1:32 PM, Nathan Whitehorn wrote: > >> On 11/11/13 15:19, Teske, Devin wrote: >>> Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... >>> >>> Should we do the quick patch to change the default >>> from /boot/boot0 to /boot/mbr: >>> >>> Index: zfsboot >>> === >>> --- zfsboot (revision 258016) >>> +++ zfsboot (working copy) >>> @@ -764,7 +764,7 @@ zfs_create_diskpart() >>> # >>> f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || >>> return $FAILURE >>> - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ >>> + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ >>> \$disk || return $FAILURE >>> >>> # >>> >>> That would fix things for Lenovo laptops for the next >>> release until I finish up the bootcode selection menu. >>> I'd like to take my time in making sure Allan and I design >>> a worthy bootcode selection menu. >> This patch looks good (I don't remember why it was boot0 in the first >> place). I think gpart automatically installs something like /boot/mbr by >> default, so I'd be interested to know if making the diff purely negative >> still works. >> >> On another note, I think we should move away from a selector. Right now, we >> have three kinds of boot code: >> 1. ZFS boot code >> 2. UFS boot code >> 3. boot0 >> >> Unifying 1 and 2 would help a lot -- I don't know of any reason we need both >> except for tradition. #3 is probably best done as a post-install config step >> ("Install FreeBSD boot manager" or something), which also means it works for >> UFS systems. > Well, I'm sensitive to the fact that sysinstall offered "none" and > even explained why in an F1 dialog that brought up "drives.hlp" > to explain that you might want to keep whatever (alternate) boot > manager you may be using already. > > In a proposed selector, the full breadth of options that I was > envisioning was: > > GPT + gptboot > GPT + none (use your existing boot manager... syslinux?) > MBR + mbr > MBR + boot0 > MBR + none (again, BYOBM) > > Hadn't got around to zfsboot yet. Where would that go? at the top? > > GPT + zfsboot ? > > (and of course, this is x86 specific... I was gleaning from sysinstall > that for systems like pc98, they call it an IPL and there's only two > options... a standard IPL or bring your own boot manager, aka "none"). > > I imagine that there would be architectures that are like the ol' pc98, > wherein they don't have all these options (is, for example? sparc64 > GPT only?) for ZFS on GPT It would be /boot/gptzfsboot /boot/zfsboot is the bits for MBR that get's DDd into the ZFS partition -- Allan Jude signature.asc Description: OpenPGP digital signature
Re: Default MBR boot "manager"
On Nov 11, 2013, at 1:32 PM, Nathan Whitehorn wrote: > On 11/11/13 15:19, Teske, Devin wrote: >> Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... >> >> Should we do the quick patch to change the default >> from /boot/boot0 to /boot/mbr: >> >> Index: zfsboot >> === >> --- zfsboot (revision 258016) >> +++ zfsboot (working copy) >> @@ -764,7 +764,7 @@ zfs_create_diskpart() >> # >> f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || >> return $FAILURE >> - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ >> + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ >> \$disk || return $FAILURE >> >> # >> >> That would fix things for Lenovo laptops for the next >> release until I finish up the bootcode selection menu. >> I'd like to take my time in making sure Allan and I design >> a worthy bootcode selection menu. > > This patch looks good (I don't remember why it was boot0 in the first place). > I think gpart automatically installs something like /boot/mbr by default, so > I'd be interested to know if making the diff purely negative still works. > > On another note, I think we should move away from a selector. Right now, we > have three kinds of boot code: > 1. ZFS boot code > 2. UFS boot code > 3. boot0 > > Unifying 1 and 2 would help a lot -- I don't know of any reason we need both > except for tradition. #3 is probably best done as a post-install config step > ("Install FreeBSD boot manager" or something), which also means it works for > UFS systems. Well, I'm sensitive to the fact that sysinstall offered "none" and even explained why in an F1 dialog that brought up "drives.hlp" to explain that you might want to keep whatever (alternate) boot manager you may be using already. In a proposed selector, the full breadth of options that I was envisioning was: GPT + gptboot GPT + none (use your existing boot manager... syslinux?) MBR + mbr MBR + boot0 MBR + none (again, BYOBM) Hadn't got around to zfsboot yet. Where would that go? at the top? GPT + zfsboot ? (and of course, this is x86 specific... I was gleaning from sysinstall that for systems like pc98, they call it an IPL and there's only two options... a standard IPL or bring your own boot manager, aka "none"). I imagine that there would be architectures that are like the ol' pc98, wherein they don't have all these options (is, for example? sparc64 GPT only?) -- Devin _ The information contained in this message is proprietary and/or confidential. If you are not the intended recipient, please: (i) delete the message and all copies; (ii) do not disclose, distribute or use the message in any manner; and (iii) notify the sender immediately. In addition, please be aware that any message addressed to our domain is subject to archiving and review by persons other than the intended recipient. Thank you. ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On 2013-11-11 16:36, Nathan Whitehorn wrote: > On 11/11/13 15:35, Allan Jude wrote: >> On 2013-11-11 16:32, Nathan Whitehorn wrote: >>> On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. >>> This patch looks good (I don't remember why it was boot0 in the first >>> place). I think gpart automatically installs something like /boot/mbr >>> by default, so I'd be interested to know if making the diff purely >>> negative still works. >>> >>> On another note, I think we should move away from a selector. Right >>> now, we have three kinds of boot code: >>> 1. ZFS boot code >>> 2. UFS boot code >>> 3. boot0 >>> >>> Unifying 1 and 2 would help a lot -- I don't know of any reason we >>> need both except for tradition. #3 is probably best done as a >>> post-install config step ("Install FreeBSD boot manager" or >>> something), which also means it works for UFS systems. >>> -Nathan >>> ___ >>> freebsd-current@freebsd.org mailing list >>> http://lists.freebsd.org/mailman/listinfo/freebsd-current >>> To unsubscribe, send any mail to >>> "freebsd-current-unsubscr...@freebsd.org" >> You have to do down right evil things to boot ZFS on MBR. dd'ing the >> 'remainder' of the boot loader into a reserved space at the head of the >> ZFS partition. The GPT boot code is 14k, and the code to boot ZFS is >> 40k, whereas the UFS stuff is 512 bytes and fits in the intended slot. >> > > We could just decide we won't support booting from ZFS on MBR. For > GPT, there is no size limit, which simplifies everything. > -Nathan > ___ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to > "freebsd-current-unsubscr...@freebsd.org" With GPT you just make a partition to put the boot code in, so, there can be a size limit, but the zfsboot script uses a generous 512kb (and aligns the first partition to 1mb) I had originally thought to just use GPT all the time, but there was significant demand for ZFS on MBR. Seems people don't want to replace their laptops just to get ZFS -- Allan Jude signature.asc Description: OpenPGP digital signature
Re: Default MBR boot "manager"
On 11/11/13 15:35, Allan Jude wrote: On 2013-11-11 16:32, Nathan Whitehorn wrote: On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. This patch looks good (I don't remember why it was boot0 in the first place). I think gpart automatically installs something like /boot/mbr by default, so I'd be interested to know if making the diff purely negative still works. On another note, I think we should move away from a selector. Right now, we have three kinds of boot code: 1. ZFS boot code 2. UFS boot code 3. boot0 Unifying 1 and 2 would help a lot -- I don't know of any reason we need both except for tradition. #3 is probably best done as a post-install config step ("Install FreeBSD boot manager" or something), which also means it works for UFS systems. -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org" You have to do down right evil things to boot ZFS on MBR. dd'ing the 'remainder' of the boot loader into a reserved space at the head of the ZFS partition. The GPT boot code is 14k, and the code to boot ZFS is 40k, whereas the UFS stuff is 512 bytes and fits in the intended slot. We could just decide we won't support booting from ZFS on MBR. For GPT, there is no size limit, which simplifies everything. -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On 2013-11-11 16:32, Nathan Whitehorn wrote: > On 11/11/13 15:19, Teske, Devin wrote: >> Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... >> >> Should we do the quick patch to change the default >> from /boot/boot0 to /boot/mbr: >> >> Index: zfsboot >> === >> --- zfsboot (revision 258016) >> +++ zfsboot (working copy) >> @@ -764,7 +764,7 @@ zfs_create_diskpart() >> # >> f_eval_catch $funcname gpart "$GPART_CREATE" mbr >> \$disk || >> return $FAILURE >> - f_eval_catch $funcname gpart "$GPART_BOOTCODE" >> /boot/boot0 \ >> + f_eval_catch $funcname gpart "$GPART_BOOTCODE" >> /boot/mbr \ >> \$disk || return $FAILURE >> >> # >> >> That would fix things for Lenovo laptops for the next >> release until I finish up the bootcode selection menu. >> I'd like to take my time in making sure Allan and I design >> a worthy bootcode selection menu. > > This patch looks good (I don't remember why it was boot0 in the first > place). I think gpart automatically installs something like /boot/mbr > by default, so I'd be interested to know if making the diff purely > negative still works. > > On another note, I think we should move away from a selector. Right > now, we have three kinds of boot code: > 1. ZFS boot code > 2. UFS boot code > 3. boot0 > > Unifying 1 and 2 would help a lot -- I don't know of any reason we > need both except for tradition. #3 is probably best done as a > post-install config step ("Install FreeBSD boot manager" or > something), which also means it works for UFS systems. > -Nathan > ___ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to > "freebsd-current-unsubscr...@freebsd.org" You have to do down right evil things to boot ZFS on MBR. dd'ing the 'remainder' of the boot loader into a reserved space at the head of the ZFS partition. The GPT boot code is 14k, and the code to boot ZFS is 40k, whereas the UFS stuff is 512 bytes and fits in the intended slot. -- Allan Jude signature.asc Description: OpenPGP digital signature
Re: Default MBR boot "manager"
On 11/11/13 15:19, Teske, Devin wrote: Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. This patch looks good (I don't remember why it was boot0 in the first place). I think gpart automatically installs something like /boot/mbr by default, so I'd be interested to know if making the diff purely negative still works. On another note, I think we should move away from a selector. Right now, we have three kinds of boot code: 1. ZFS boot code 2. UFS boot code 3. boot0 Unifying 1 and 2 would help a lot -- I don't know of any reason we need both except for tradition. #3 is probably best done as a post-install config step ("Install FreeBSD boot manager" or something), which also means it works for UFS systems. -Nathan ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"
Re: Default MBR boot "manager"
On 2013-11-11 16:19, Teske, Devin wrote: > Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... > > Should we do the quick patch to change the default > from /boot/boot0 to /boot/mbr: > > Index: zfsboot > === > --- zfsboot (revision 258016) > +++ zfsboot (working copy) > @@ -764,7 +764,7 @@ zfs_create_diskpart() > # > f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || > return $FAILURE > - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ > + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ > \$disk || return $FAILURE > > # > > That would fix things for Lenovo laptops for the next > release until I finish up the bootcode selection menu. > I'd like to take my time in making sure Allan and I design > a worthy bootcode selection menu. These seems like the best approach for now, based on the feedback I have gotten from people with BIOSs that won't boot GPT and often choke on the boot0 boot manager. -- Allan Jude signature.asc Description: OpenPGP digital signature
Default MBR boot "manager"
Topic: Lenovo Laptops and bsdinstall zfsboot with MBR layout... Should we do the quick patch to change the default from /boot/boot0 to /boot/mbr: Index: zfsboot === --- zfsboot (revision 258016) +++ zfsboot (working copy) @@ -764,7 +764,7 @@ zfs_create_diskpart() # f_eval_catch $funcname gpart "$GPART_CREATE" mbr \$disk || return $FAILURE - f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/boot0 \ + f_eval_catch $funcname gpart "$GPART_BOOTCODE" /boot/mbr \ \$disk || return $FAILURE # That would fix things for Lenovo laptops for the next release until I finish up the bootcode selection menu. I'd like to take my time in making sure Allan and I design a worthy bootcode selection menu. -- Devin _ The information contained in this message is proprietary and/or confidential. If you are not the intended recipient, please: (i) delete the message and all copies; (ii) do not disclose, distribute or use the message in any manner; and (iii) notify the sender immediately. In addition, please be aware that any message addressed to our domain is subject to archiving and review by persons other than the intended recipient. Thank you. ___ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"