Sponsored Content
Operating Systems Solaris How to know the global zonename from non-global zone? Post 302268425 by reborg on Monday 15th of December 2008 05:46:15 PM
Old 12-15-2008
Why would you take this route? If the zone is frozen than you won't be able to access it. On the other have if you can examine /etc/zones, aren't you already in the global zone?

If you need the information within the zone, then just provision the hostname of the global zone in /etc/hosts in the NGZ as part of your zone creation routine.
 

9 More Discussions You Might Find Interesting

1. Solaris

[b]How to mount a folder from global zone to non global zone??

Hi All There is one folder in global zone I just want to share the same folder innon global zone. How can i do it? pls send me script for this. (2 Replies)
Discussion started by: vijaysachin
2 Replies

2. Solaris

How can we copy a directory from Global to Non-global zone?

Hi All, How can we copy a directory from global zone to non-global zone using SCP command? (8 Replies)
Discussion started by: vijaysachin
8 Replies

3. Solaris

Is there two different kernel`s running in global and non global zone?

Hi All, I want to know for non global zone there will be different kernal running? (1 Reply)
Discussion started by: vijaysachin
1 Replies

4. Solaris

How to access ENV variables of non global zones in global zone???

Hi Guys, My requirement is I have file called /opt/orahome/.profile in non global zone. PATH=/usr/bin:/usr/ucb:/etc:/usr/sbin:/usr/local/bin:/usr/openwin/bin:. export PATH PS1="\${ORACLE_SID}:`hostname`:\$PWD$ " export PS1 EDITOR=vi export EDITOR ENV=/opt/orahome/.kshrc export ENV... (1 Reply)
Discussion started by: vijaysachin
1 Replies

5. Solaris

how to add a default gateway in a zone of different VLAN of global zone

Hi Greetings... I have an issue in connecting the zone from outside the network and it is because of default gateway. I can ping default gateway from inside the zone and not able to ping from global zone due to different VLAN issue. If i add two different gateways and restart network services,... (2 Replies)
Discussion started by: vvpotugunta
2 Replies

6. Solaris

showing 2 different time zones in global zone and nonglobal zone

can some one help me out as it is showing 2 different time zones in global zone and nonglobal zone .In global zone it is showing in GMT while in nonglobal zone i it showing as PDT. System in running with solaris 10 (3 Replies)
Discussion started by: ravijanjanam12
3 Replies

7. Solaris

Global and non-global zone resource sharing - tricky

hi all, Just a simple question but i cant get the answers in the book - In my globalzone , assuming i have 4 cpus (psrinfo -pv = 0-3), if i set dedicated-cpu (ncpus=2) for my local zone Is my globalzone left with 2 cpus or still 4 cpus ? Does localzone "resource reservation.e.g. cpu in... (6 Replies)
Discussion started by: javanoob
6 Replies

8. Solaris

Date and time change in global and non global zone

Hi, If I change date and time in global zone, then it will affect in non global zones. During this process what files will get affect in non global zones and which mechanism it's using to change. gloabl zone:Solaris 11.3 X86 TIA (1 Reply)
Discussion started by: Sumanthsv
1 Replies

9. Solaris

Solaris 11 zone has no external network access (except to Global Zone)

Hi, hoping someone can help, its been a while since I used Solaris. After creating a NGZ (non global zone), the NGZ can access the GZ (Global Zone) and the GZ can access the NGZ (using ssh, zlogin) However, the NGZ cannot access any other netwqork devices, it can't even see the default router ... (2 Replies)
Discussion started by: GazinLincoln
2 Replies
getzonelabelbyid(3TSOL) 			       Trusted Extensions Library Functions				   getzonelabelbyid(3TSOL)

NAME
getzonelabelbyid, getzonelabelbyname, getzoneidbylabel - map between zones and labels SYNOPSIS
cc [flags...] file... -ltsol [library...] #include <tsol/label.h> m_label_t *getzonelabelbyid(zoneid_t zoneid); m_label_t *getzonelabelbyname(const char *zonename); zoneid_t *getzoneidbylabel(const m_label_t *label); DESCRIPTION
The getzonelabelbyid() function returns the mandatory access control (MAC) label of zoneid. The getzonelabelbyname() function returns the MAC label of the zone whose name is zonename. The getzoneidbylabel() function returns the zone ID of the zone whose label is label. All of these functions require that the specified zone's state is at least ZONE_IS_READY. The zone of the calling process must dominate the specified zone's label, or the calling process must be in the global zone. RETURN VALUES
On successful completion, the getzonelabelbyid() and getzonelabelbyname() functions return a pointer to a sensitivity label that is allo- cated within these functions. To free the storage, use m_label_free(3TSOL). If the zone does not exist, NULL is returned. On successful completion, the getzoneidbylabel() function returns the zone ID with the matching label. If there is no matching zone, the function returns -1. ERRORS
The getzonelabelbyid() and getzonelabelbyname() functions will fail if: ENOENT The specified zone does not exist. The getzonelabelbyid() function will fail if: ENOENT No zone corresponds to the specified label. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Interface Stability |Committed | +-----------------------------+-----------------------------+ |MT-Level |Safe | +-----------------------------+-----------------------------+ SEE ALSO
Intro(2), getzonenamebyid(3C), getzoneidbyname(3C), libtsol(3LIB), m_label_free(3TSOL), attributes(5), labels(5) NOTES
The functionality described on this manual page is available only if the system is configured with Trusted Extensions. SunOS 5.11 20 Jul 2007 getzonelabelbyid(3TSOL)
All times are GMT -4. The time now is 05:37 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy