Jeff Victor wrote:
Enda o'Connor - Sun Microsystems Ireland - Software Engineer wrote:
Jerry Jelinek wrote:
Jeff Victor wrote:
Is it possible to add an inherit-pkg-dir to a zone's config after
"zoneadm ... install"? I'm confident the answer is 'no' but just
had to ask.
The man page and docs.sun.com are a little vague on this. They both
say "Such resources [those pkgs] are not modifiable or removable
once a zone has been installed with zoneadm." But if you interpret
"such resources" as "the ones that have already been inherited" then
the possibility of adding new ones is not mentioned.
The code currently disallows this. See add_resource() in
currently at line 1587.
Basically if say /lib was a local copy in the zone, then adding
inherit-pkg-dir=/lib would mean replacing it with a lofs mount, which
could possibly destabilise the system and so on, and would also have
implications for patches already installed ( basically any installed
patch that touched files in /lib would no longer be removable, as the
undo would try and restore files back to a lofs mount ).
Also the contents DB in the zone etc would need to be synced and son on.
That is a very good reason to not allow:
1) Removing an inherit-pkg-dir
2) The addition of an inherit-pkg-dir which is related to other pkg-dir's.
So thats partly the reason for not allowing it, i.e. introduce
instability to the installed zone in many forms.
Understood. For the future: are there reasons that we should *not* add
the ability to add a pkg-dir that is not part of Solaris? This would
allow someone to add access to a 3rd party package which is already
installed in the zone. It would require modifying the zone's pkg db, etc.
There are obviously cases where this could be ok. As Enda points out, there
are also cases where it can cause problems. It would be a reasonable RFE
to file, the trick will be correctly figuring when it is ok and when it is not.
zones-discuss mailing list