Re: [zones-discuss] inherit-pkg-dir after zone-install?

2006-07-27 Thread Enda o'Connor - Sun Microsystems Ireland - Software Engineer



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.



Jeff,

The code currently disallows this.  See add_resource() in
usr/src/cmd/zonecfg/zonecfg.c.

http://cvs.opensolaris.org/source/xref/on/usr/src/cmd/zonecfg/zonecfg.c
currently at line 1587.

Jerry
___
zones-discuss mailing list
zones-discuss@opensolaris.org


Hi
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.

So thats partly the reason for not allowing it, i.e. introduce 
instability to the installed zone in many forms.


Enda

___
zones-discuss mailing list
zones-discuss@opensolaris.org


Re: [zones-discuss] inherit-pkg-dir after zone-install?

2006-07-27 Thread Enda o'Connor - Sun Microsystems Ireland - Software Engineer



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.



Jeff,

The code currently disallows this.  See add_resource() in
usr/src/cmd/zonecfg/zonecfg.c.

http://cvs.opensolaris.org/source/xref/on/usr/src/cmd/zonecfg/zonecfg.c
currently at line 1587.



Hi
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.


Just curious.

-- 

Jeff VICTOR  Sun Microsystemsjeff.victor @ 
sun.com

OS AmbassadorSr. Technical Specialist
Solaris 10 Zones FAQ:
http://www.opensolaris.org/os/community/zones/faq
-- 


___
zones-discuss mailing list
zones-discuss@opensolaris.org


Hi
It woudl be possible to add a new inherit-pkg-dir, but considering the 
risks one woudl have to be very careful to amke sure that the new 
inherit-pkg-dir did not intersect with any already installed software 
etc in the zone.


Personally if I install software in the global ( say a complier )and 
want to make it available selectively to a non-global zone I would do an 
add fs to the zonecfg and boot the zone, or if I wanted to avoid zone 
reboot do the mounting manually and later add the fs to the zonecfg to 
keep everything in sync.



But one would have to be very careful with allowing new inherit-pkg-dir 
to an already installed zone in order to avoid the pitfalls.


Enda

___
zones-discuss mailing list
zones-discuss@opensolaris.org


Re: [zones-discuss] inherit-pkg-dir after zone-install?

2006-07-27 Thread Enda o'Connor - Sun Microsystems Ireland - Software Engineer



Paul Kraus wrote:


On 7/27/06, Enda o'Connor - Sun Microsystems Ireland - Software
Engineer [EMAIL PROTECTED] wrote:


It woudl be possible to add a new inherit-pkg-dir, but considering the
risks one woudl have to be very careful to amke sure that the new
inherit-pkg-dir did not intersect with any already installed software
etc in the zone.

Personally if I install software in the global ( say a complier )and
want to make it available selectively to a non-global zone I would do an
add fs to the zonecfg and boot the zone, or if I wanted to avoid zone
reboot do the mounting manually and later add the fs to the zonecfg to
keep everything in sync.



I thought that the inherit-pkg-dir did more than just an lofs mount of
the underlying FS into the sparse zone.


Hi
Well yes,  it not simply a mount operation, the package maintenance 
needs to also occur etc as part of zoneadm install.
I'm just explaining that there are pitfalls involved in this proposal, 
it's possibly doable ( the zones developers would be better placed to 
comment ) but might be risky


Enda

___
zones-discuss mailing list
zones-discuss@opensolaris.org