Evan,

When I originally filed this bug, I wasn't thinking we were
going to be that strict all around.  For one, I was thinking we'd
just be a bit more informative about it.  e.g. 'list' could just
show 'unverified' or whatever, for the cases we find this:

# beadm list
BE                            Active Mountpoint Space   Policy Created
-----                             ------ ---------- -----   ------ -------
os-134 - - 29.74M static 2010-03-04 16:35
nv-135 (unverified)    -      -          26.41M  static 2010-03-24 08:09
os-135 - - 20.42M static 2010-03-26 14:01 os-136 - - 33.72M static 2010-04-05 08:14 os-136-xvm - - 65.0K static 2010-04-05 12:33 os-137 NR / 69.05G static 2010-04-15 17:09 os-137-xvm - - 66.0K static 2010-04-15 17:51


We've largely been able to implement the BE code with
no real metadata, so its nice to be able to take advantage
of that.

For example, be_mount - might be worth allowing this
without the validation.  Mounting doesn't cause any harm,
and it's nice to be able to mount a BE on a coexisting pool
that has S10 ZFS BEs on it.

Or someone could zfssend over a valid root dataset into the
current pool at <pool>/ROOT/foo, "beadm create -e foo newBE",
and newBE was in business.


Of all the subcommands, perhaps 'activate' and 'rename'
should hard fail, the rest maybe could be more lax.


nit:
be_utils.c - 2133 - maybe a name that's more indicative of the
fact that we're checking for a root?  be_valid_be_root()
perhaps?

Do the changes in be_list.c also address something else.


thanks,
-ethan


On 04/19/10 12:18, Evan Layton wrote:
I need reviewers for bug:
891 libbe needs to validate potential BE root datasets

The code makes a "best effort" to determine first if the BE has a
valid uuid. If the BE does not have a uuid it then checks the
contents of the BE to see of it appears to have at least some of
the expected files. The reason we couldn't just use the existance
of the uuid is that in the first release (2008.05) the BE's did not
contain a uuid.

Bug:
http://defect.opensolaris.org/bz/show_bug.cgi?id=891

Webrev:
http://cr.opensolaris.org/~evanl/891

Testing:
- This has been tested using the libbe stc test suite as well as
testing with invalid BE datasets created under rpool/ROOT.
- To sanity test the new library was also used when doing an
install.


Thanks!
-evan
_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss
_______________________________________________
caiman-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/caiman-discuss

Reply via email to