Solaris10 zones: Create and Install Non-Global Zones

For this example, we will use /dev/dsk/c0t1d0s0 and /dev/dsk/c0t1d0s3 for the root and data areas respectively.

# newfs /dev/rdsk/c0t1d0s0
# newfs /dev/rdsk/c0t1d0s3

Next add an entry as follows for the root area in your vfstab:

/dev/dsk/c0t1d0s0  /dev/rdsk/c0t1d0s0 /export/zone1 ufs   1   yes  –

Next mount the filesytem and ensure correct permissions:

# mkdir /export/zone1
# chown root:root /export
# mount /export/zone1
# chmod 700 /export/zone1

Now we can create the zone configuration.

# zonecfg -z zone1
zone1: No such zone configured
Use ‘create’ to begin configuring a new zone.
zonecfg:zone1> create
zonecfg:zone1> set zonepath=/export/zone1
zonecfg:zone1> set autoboot=true
zonecfg:zone1> add fs
zonecfg:zone1:fs> set dir=/dir1
zonecfg:zone1:fs> set special=/dev/dsk/c0t1d0s3
zonecfg:zone1:fs> set raw=/dev/rdsk/c0t1d0s3
zonecfg:zone1:fs> set
zonecfg:zone1:fs> end
zonecfg:zone1> add net
zonecfg:zone1:net> set physical=eri0
zonecfg:zone1:net> set address=
zonecfg:zone1:net> end
zonecfg:zone1> add attr
zonecfg:zone1:attr> set
zonecfg:zone1:attr> set
zonecfg:zone1:attr> set value=”zone one”
zonecfg:zone1:attr> end
zonecfg:zone1> verify
zonecfg:zone1> commit
zonecfg:zone1> info
zonecfg:zone1> exit

You can use this procedure for multiple zones making sure that the filesystem, network, and attribute configurations are appropriately modified. I have created an additional zone in this manner called zone2 as you will see in the following zoneadm command outputs.

# zoneadm list -i

Notice that your new zone does not show up. It isn’t installed yet, it is just configured. Next we will install it.

# zoneadm -z zone1 install

Once complete, you can see the zones are installed:

# zoneadm list -iv
ID NAME             STATUS         PATH
0 global           running        /
– zone1            installed      /export/zone1
– zone2            installed      /export/zone2

# zoneadm -z zone1 boot

# zoneadm list -iv
ID NAME             STATUS         PATH
0 global           running        /
5 zone1            running        /export/zone1
– zone2            installed      /export/zone2

To log into a running zone use the zlogin command.

# zlogin -C zone1
[Connected to zone ‘zone1’ console]

With a brand new zone, you will go through the typical sysidcfg interactions (Language, Locale, Terminal, Hostname,kerberos, Name service,Timezone, and password settings) that you would normally do with a new Solaris install.

The zone will reboot and ready for general use.

If the zone install fails, check the install.log for further errors. The install.log is located in the zone’s home path. In this example, the install.log would be located at: /export/zone1/root/var/sadm/system/logs/install.log





I have started ( aka in 2009 as my own personal reference blog, and later sometime i have realized that my leanings might be helpful for other unixadmins if I manage my knowledge-base in more user friendly format. And the result is today's' You can connect me at -

14 Responses

  1. Pradeep says:

    Hi…Hi This is Pradeep, I don’t about Zone Migration And Zone Cloning? If you know send me the procedure for this ………. I faced this question in my client round interview. But i have configuration knowledge only.

  2. Pradeep says:

    Hi ..
    Thanks for information this site very help full for my solaris friends


  3. Naresh says:


    I need information regarding LDOMS.Like Creation of LDOMS…etc….

    pls post the info.


  4. Yogesh Raheja says:

    @Naresh, we are working on LDOMS documentation and will try to provide the info on LDOM’s very soon.

  5. Naresh says:

    hi yogesh,

    thnks fr da reply. will b waiting fr da info regarding LDOMS.


  6. samiulla says:

    Hi sir

    Thank you very much for your valuable time to share your knowledge for us and for free.

    in this zone tut.  good but for new persons it’s hard to understand. So please make the tuts as details as possible.  thanks for everything 

    • Ramdev Ramdev says:

      Hi Sami, We are trying to avoid the complexity of each topic as much as we can. But Still there are some challenges to understand some concepts in text format. For sure, we do our best to make our posts simple.

  7. says:

    after reading zones i have still issue with what is diff bet ZONES & CONTAINER (IN DEEPLY). & what about “resource management”. is it CONTAINER mean RM…
    pls explain us that diff & pls sahre any link or docs for the same…..

  8. Ramdev Ramdev says:

    in simple terms,   Initially when you create a virtual machine in solaris, it is just called as zone and once you start using resource management for the zone that zone will be treated as container ( zone + RM). 

  9. says:

    Hello Sir,

    what is diff bet solaris 10 ZONE & solaris 11 ZONE.

    Also now which PDF is good to read now 10 or 11…

  10. Ramdev Ramdev says:

    Chetan – please go through the document

  11. says:

    Hi Sir,Thanks 4 reply & PDF link… currently for RM i reading same PDF, that mean i am on correct track. in case any help i want thn
    gurkulindia ZINDABAAD….

  1. September 16, 2015

    […] Read – Create and Install Non-Global Zones […]

  2. September 22, 2015

    […] Read – Create and Install Non-Global Zones […]

What is in your mind, about this post ? Leave a Reply

  Our next learning article is ready, subscribe it in your email

What is your Learning Goal for Next Six Months ? Talk to us