Page MenuHomeFreeBSD

Colons in boot environment name
ClosedPublic

Authored by mav on Jun 29 2018, 7:08 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Apr 14, 12:03 AM
Unknown Object (File)
Mar 16 2024, 10:19 PM
Unknown Object (File)
Dec 18 2023, 6:53 PM
Unknown Object (File)
Nov 28 2023, 10:18 AM
Unknown Object (File)
Nov 28 2023, 10:18 AM
Unknown Object (File)
Nov 28 2023, 10:04 AM
Unknown Object (File)
Nov 28 2023, 9:38 AM
Unknown Object (File)
Sep 6 2023, 1:03 AM
Subscribers

Details

Summary

While migrating FreeNAS back from GRUB to BSD loader we noticed that the last can not boot from boot environments with colons in their name. The problem is in currdev variable, using colon as a field separator, and the code splitting dataset and path fields on second colon, that leads to trucating dataset name, if one includes colon. I don't know whether anybody have colon in kernel part, but FreeNAS sometimes uses them in boot environment names (time of creation).

Proposes one-line patch makes currdev dev and path fields for ZFS to be cut not on second colon, but on the last one, assuming that colon in dataset name is more important then in kernel path. Also kernel path is an optional parameter in the currdev variable, so in my understanding this change should not completely prevent booting kernels with colons, as bad it does now for boot environments.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable