Bart Smaalders wrote:
Following up on a thread from several months ago....
Currently, the pkg command deals rather simplistically with boot
environments; it always creates a new boot environent when doing an
image update or change-variant, and never does one on pkg install. We
recently enhanced pkg install and uninstall to prevent operation on
the live image if doing so would modify files tagged with
reboot-needed=true. However, it would be nice if pkg(1) could be a
little more malleable.
We can add the following option to install, uninstall, image-update
and change-variant and change-facet:
--new-be=[always, if-needed, never]
Could I suggest --be-create or --be-creation so that the options both
start with --be (for ease of finding and remembering them when
considering the existing --be-name option and forthcoming
--be-description option)?
Also, as Dave suggested, this seems like a good item to have as an image
policy (property). Of course that could be a later enhancement...
which would do as the names suggest: always create a new BE, create
one only if a file tagged w/ reboot-needed is being modified or
removed, or never create one respectively. In the latter case, the
operation will fail if a file tagged w/ reboot-needed would be
affected.
I'm happy with this assuming that the error message for the never case
makes it clear how to proceed (i.e. if they provided --be-create=never,
tell them not to, if it was via the image property then suggest they
provide --be-create=if-needed?).
Also, as Joanie suggested, maybe we should always create a snapshot for
the if-needed / never cases? The only concern about that is how people
feel about snapshots that just sit around. The only way I see out of
that is variations on if-needed and never that exclude the snapshot
behaviour.
Speaking of snapshots, we also need a better naming pattern for them, I
think. Or some way to be able to make it more obvious to the user that
the packaging system created them so that it is easier for them to
manage them (this applies even today for failed snapshots). This is
also likely a separate issue.
...
Alternatively, we can leave install and uninstall the way they
are today, with the default being --new-be=never. I would like
to make the rest of the commands if-needed, since this will
improve usability significantly for common operations.
I think the if-needed behaviour is going to be preferable. However,
that just means that we need to make it clearer what exactly is happening.
On multiple occasions, there seems to have been confusion among users
about what exactly a boot environment is, or how those actually work.
Another item is that we currently don't warn the user that any
configuration changes made after the package operation has completed
will not affect the new boot environment; only the current one.
Cheers,
--
Shawn Walker
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss