Ihsan Zaghmouth wrote:
> Hi Jeff,
> 
> Here is my 2 cents, after assuming that pkginfo should hold such an 
> information post installation.
> The */var/sadm/pkg/<pkgname>/pkginfo* file lists among other info the 
> *SUNW_PKG_ALLZONES*=true | false for the installed package.
> pkginfo should have an option to display that, I tried them all ... in 
> vain !
> 
> if you write a small script, you can display the 
> /var/sadm/pkg/<pkgname>/pkginfo, you should be able to distinguish:
> :
> cat /var/sadm/pkg/<pkgname>/pkginfo* | *grep SUNW_PKG_ALLZONES, and if:
> 
>    1. SUNW_PKG_ALLZONES=true  ... Then installed on all Zones
>    2. SUNW_PKG_ALLZONES=false ... *Only Global -G*
> 
> Ihsan
> 
Hi
ALLZONES is not the same as -G
-G is identical in behaviour to SUNW_PKG_THISZONE=true

So if a package does not define any of the zones variables including
SUNW_PKG_THISZONE
Adding said package with pkgadd -G will lead to identical behaviour as 
though the package had
SUNW_PKG_THISZONE=true defined, but it does not cause this variable to 
get defined in the pkginfo, rather a file
/var/sadm/install/gz-only-packages gets populated with this package

Now remember that one could have
SUNWfoo and SUNWfoor, so a simple grep fro SUNWfoo in said file is not 
sufficent, it might match SUNWfoor which is not what is wanted.

Also
pkgparam is what is used to display pkginfo variables

# pkgparam SUNWcsu SUNW_PKG_ALLZONES
true
#

Enda
> Jeff Victor wrote:
>> How can someone learn whether a package was installed in the global zone 
>> *with* -G - or without it?
>>
>> _______________________________________________
>> zones-discuss mailing list
>> zones-discuss@opensolaris.org
>>   
> 
> -- 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> zones-discuss mailing list
> zones-discuss@opensolaris.org

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

Reply via email to