Zones and interfaces

Hello,
can someone please suggest if is possible to use different net interfaces
for non global zones ?

for example ,


bash-3.00# uname -srv
SunOS 5.10 Generic_137137-09


bash-3.00# ifconfig -a
lo0: flags=2001000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4,VIRTUAL> mtu 8232 index 1
        inet 127.0.0.1 netmask ff000000
e1000g0: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 2
        inet 148.198.188.20 netmask ffffff00 broadcast 148.198.188.255
        ether 0:21:28:27:e1:d2

but ,
i have three other unused interfaces

bash-3.00# dladm show-link
e1000g0         type: non-vlan  mtu: 1500       device: e1000g0
e1000g1         type: non-vlan  mtu: 1500       device: e1000g1
e1000g2         type: non-vlan  mtu: 1500       device: e1000g2
e1000g3         type: non-vlan  mtu: 1500       device: e1000g3

Is it possible to configure 2 non global zones on this system and
assign them for example for zone1 -> e1000g1 and for zone2-> e1000g2 ?

If you are using Solaris 10 8/07 or newer (cat /etc/release), the simplest way is to set-up exclusive IP non global zones.

1 Like

or..
with shared ip type:

zonecfg -z yourzonename
> create -b
> set zonepath=/zones/yourzonename
> set autoboot=true
> set ip-type=shared
> add net
> set address=10.0.0.10
> set defrouter=10.0.0.1
> set physical=e1000g1
> end
> verify
> commit
> exit
1 Like

Thanks,
it seems i will need to use already configured interface, e1000g0,
for the new two zones.
I have the IP adresses i should use for the zones,
but i am in doubt how to assing those adresses to the zones and to the e1000g0 interface..
Can someone give me a hint ?

Then you have no choice but using shared IP interfaces. Just do like styno suggested but specify

set physical=e1000g0
1 Like

ok thanks
Can you please tell me procedure how to create whole root zone with shared IP interfaces,
note that i am on zfs...
Also is there some requrenments to edit /etc/vfstab after of before creating the zones ?

First link from Google looks good: Create Full Root Solaris Zone

1 Like