#
355662 |
|
12-Dec-2019 |
kevans |
MFC r355460: libbe: fix build against sysutils/openzfs, part 1
This is the half of the changes required that work as-is with both in-tree ZFS and the new hotness, sysutils/openzfs. Highlights are less dependency on header pollution (from somewhere) and using 'mnttab' instead of 'extmnttab'. In the in-tree ZFS, the latter is a #define for the former, but in the port extmnttab is actually a distinct struct that's a super-set of mnttab. We really want mnttab here anyways, so just use it.
|
#
353784 |
|
20-Oct-2019 |
kevans |
MFC r353644, r353646, r353663: bectl(8) origin auto-destroy
r353644: libbe(3): add needed bits for be_destroy to auto-destroy some origins
New BEs can be created from either an existing snapshot or an existing BE. If an existing BE is chosen (either implicitly via 'bectl create' or explicitly via 'bectl create -e foo bar', for instance), then bectl will create a snapshot of the current BE or "foo" with be_snapshot, with a name formatted like: strftime("%F-%T") and a serial added to it.
This commit adds the needed bits for libbe or consumers to determine if a snapshot names matches one of these auto-created snapshots (with some light validation of the date/time/serial), and also a be_destroy flag to specify that the origin should be automatically destroyed if possible.
A future commit to bectl will specify BE_DESTROY_AUTOORIGIN by default so we clean up the origin in the most common case, non-user-managed snapshots.
r353646: bectl(8): destroy: use BE_DESTROY_AUTOORIGIN if -o is not specified
-o will force the origin to be destroyed unconditionally. BE_DESTROY_AUTOORIGIN, on the other hand, will only destroy the origin if it matches the format used by be_snapshot. This lets us clean up the snapshots that are clearly not user-managed (because we're creating them) while leaving user-created snapshots in place and warning that they're still around when the BE created goes away.
r353663: libbe(3): Fix destroy of imported BE w/ AUTOORIGIN
Imported BE, much like the activated BE, will not have an origin that we can fetch/examine for destruction. be_destroy should not return BE_ERR_NOORIGIN for failure to get the origin property for BE_DESTROY_AUTOORIGIN, because we don't really know going into it that there's even an origin to be destroyed.
BE_DESTROY_NEEDORIGIN has been renamed to BE_DESTROY_WANTORIGIN because only a subset of it *needs* the origin, so 'need' is too strong of verbiage.
This was caught by jenkins and the bectl tests, but kevans failed to run the bectl tests prior to commit.
|
#
346802 |
|
28-Apr-2019 |
kevans |
MFC r346545-r346546, r346680, r346700, r346705
r346545: libbe(3): allow creation of arbitrary depth boot environments
libbe currently only provides an API to create a recursive boot environment, without any formal support for intentionally limiting the depth. This changeset adds an API, be_create_depth, that may be used to arbitrarily restrict the depth of the new BE.
r346546: libbe(3): Add a test for be creation
r346680: libbe(3): Copy received properties as well
This was inherently broken on send|recv datasets.
r346700: libbe(3): Fix mis-application of patch (SHLIBDIR)
Rob's patch in D18564 cemented the SHLIBDIR because bsd.own.mk (included by src.opts.mk) sets it to /usr/lib. r346546 did somehow not apply this part of the patch, leaving it to get installed to the wrong place and subsequently removed via ObsoleteFiles.
r346705: libbe(3): Fix libcompat build
SHLIBDIR should still be optionally set, just before src.opts.mk is included so that libcompat can properly override it. This fixes lib32 failures reported by both Jenkins and Michael Butler.
|
#
346429 |
|
20-Apr-2019 |
kevans |
MFC bectl(8)/libbe(3): r337663-337664,337667,337697-337699,337800,337805, 337915-337918,337921,337924,337947,337993-337995,338221-338222,338303, 338417,339047,339972,339994,340334,340507-340508,340592-340594, 340635-340636,340722-340723,340974,342466,342849,342903,342911,343335, 343543,343977,343993-343994,344034,344067,344084,345302,345769, 345845-345846,345848,346082
There are simply too many small changes to enumerate; in summary:
bectl(8)/libbe(3) has been introduced from current state in -CURRENT and added to the stable/11 rescue build. bectl(8) is a tool for managing ZFS boot environments, largely inspired by beadm. It includes features such as being able to jail a boot environment or easily mount it for modification.
Relnotes: probably
|
#
342807 |
|
06-Jan-2019 |
kevans |
MFC r342362-r342363: config(8) duplicate option handling
r342362: config(8): Allow duplicate options to be specified
config(8)'s option handling has been written to allow duplicate options; if the value changes, then the latest value is used and an informative message is printed to stderr like so:
/usr/src/sys/amd64/conf/TEST: option "VERBOSE_SYSINIT" redefined from 0 to 1
Currently, this is only a possibility for cpu types, MAXUSERS, and MACHINE_ARCH. Anything else duplicated in a config file will use the first value set and error about duplicated options on subsequent appearances, which is arguably unfriendly since one could specify:
include GENERIC nooptions VERBOSE_SYSINIT options VERBOSE_SYSINIT
to redefine the value later anyways.
Reported by: mmacy
r342363: config(8): Remove all instances of an option when opting out
Quick follow-up to r342362: options can appear multiple times now, so clean up all of them as needed. For non-OPTIONS options, this has no effect since they're already de-duplicated.
|