The VNIC connects the virtual network to the external network. Zones communicate through their VNIC's virtual switch. You must create a VNIC for every zone in the virtual network.
This task includes a step to provide names to the components you are creating. For guidelines on assigning names, see Rules for Valid Link Names in Configuring and Managing Network Components in Oracle Solaris 11.4.
Before You Begin
Ensure that your role has the appropriate rights profile to perform this procedure. See Using Rights Profiles to Perform Network Configuration.
$ dladm create-etherstub etherstub-name
Perform this step only if you are creating an isolated private virtual network. See also Use Case: Configuring a Private Virtual Network.
$ dladm create-vnic -l link VNIC
The name of the link over which the VNIC is configured. In the case of a private virtual network, you specify the name of the etherstub.
The name of the VNIC.
$ ipadm create-ip interface
interface refers to the VNIC you just created.
$ ipadm create-addr -a address interface
$ dladm show-link
This example shows how to configure vnic1 over the datalink net0.
$ dladm create-vnic -l net0 vnic1 $ ipadm create-ip vnic1 $ ipadm create-addr -a 192.0.2.10/24 vnic1 $ dladm show-link LINK CLASS MTU STATE OVER net0 phys 1500 up -- vnic1 vnic 1500 up net0Example 2 Configuring VNICs Over an Etherstub
This example shows how you can create an etherstub etherstub0 and configure VNICs vnic1 and vnic2 over the etherstub.
$ dladm create-etherstub etherstub0 $ dladm create-vnic -l etherstub0 vnic1 $ dladm create-vnic -l etherstub0 vnic2 $ ipadm create-ip vnic1 $ ipadm create-addr -a 192.0.2.20/24 vnic1 $ ipadm create-ip vnic2 $ ipadm create-addr -a 192.0.2.30/24 vnic2 $ dladm show-etherstub -o all LINK ZONE etherstub0 global $ dladm show-link LINK CLASS MTU STATE OVER net0 phys 1500 up -- etherstub0 etherstub 9000 unknown -- vnic1 vnic 9000 up etherstub0 vnic2 vnic 9000 up etherstub0