Managing Network Virtualization and Network Resources in Oracle® Solaris 11.2

Exit Print View

Updated: September 2014
 
 

How to Assign a VXLAN to a Zone

  1. Become an administrator.

    For more information, see Using Your Assigned Administrative Rights in Securing Users and Processes in Oracle Solaris 11.2 .

  2. Determine the available IP addresses on the system.
    # ipadm show-addr
    
  3. Create the VXLAN by specifying the IP address.
    # dladm create-vxlan -p prop=value VXLAN-LINK
  4. Verify the VXLAN that you created.
    # dladm show-vxlan
  5. Configure the zone by assigning the VXLAN that you created as the underlying link for the zone's anet.
    global# zonecfg -z zone 
    zonecfg:zone2> add anet
    zonecfg:zone2:net> set linkname=datalink
    zonecfg:zone2:net> set lower-link=VXLAN-LINK
    zonecfg:zone2:net> end
    zonecfg:zone2> verify
    zonecfg:zone2> commit
    zonecfg:zone2> exit
    global# zoneadm -z zone reboot

    VXLAN is assigned as the underlying link for the zone's anet.

Example 3-3  Assigning a VXLAN to a Zone's anet
# ipadm show-addr net4
ADDROBJ   TYPE   STATE   ADDR 
net4/v4   static ok      10.10.11.1/24 2
# dladm create-vxlan -p addr=10.10.11.1,vni=10 vxlan1
# dladm show-vxlan
LINK   ADDR       VNI  MGROUP
vxlan1 10.10.11.1 10   224.0.0.1

Because you have not specified a multicast address, this VXLAN segment uses the All Host multicast address, which addresses all the hosts on the same network segment.

# dladm show-link vxlan1
LINK   CLASS MTU  STATE OVER 
vxlan1 vxlan 1440 up    -- 

vxlan1 is created and the link state is up.

global# zonecfg -z zone2 
zonecfg:zone2> add anet
zonecfg:zone2:net> set linkname=net1
zonecfg:zone2:net> set lower-link=vxlan1
zonecfg:zone2:net> end
zonecfg:zone2> verify
zonecfg:zone2> commit
zonecfg:zone2> exit
global# zoneadm -z zone2 reboot

vxlan1 is assigned as the underlying link for the zone's anet.

When the zone boots up, net1 is created in zone2 over vxlan1.