Use the dladm show-link command to display both the physical and virtual datalinks on a system. A system has as many datalinks as there are installed NICs. You can use various options with this command to customize the information that is displayed.
When used with no additional options or arguments, the dladm show-link command displays the following information:
# dladm show-link LINK CLASS MTU STATE OVER net1 phys 1500 down -- net3 phys 1500 unknown -- net0 phys 1500 up -- net2 phys 1500 unknown -- net11 phys 1500 up -- net5 phys 1500 up -- net6 phys 1500 up --
In the previous output, the STATE column shows the current state of the virtual datalink. The state can be up, down, or unknown. For virtual datalinks, when a NIC is split up into multiple VNICs, a virtual switch is implicitly created internally. This creation of a virtual switch enables the VNICs and the primary datalink to communicate with each other, as long as they are on the same VLAN, even if the physical datalink has no connection to the external network. This relationship forms the virtual state of the datalink.
Use the –P option to display persistent configuration information about the datalinks. Based on the information that is provided by this command, you can proceed with further network configuration. For example, you can determine the number of NICs on the system, and you can select which datalink to use, over which you can configure IP interfaces. When you type the command, the information that is displayed is similar to the following example:
# dladm show-link -P LINK CLASS OVER net0 phys -- net1 phys -- net2 phys --
The previous example shows that the system has three datalinks that are directly associated with their corresponding physical NICs. No special datalinks exist, such as aggregations or virtual NICs, which are configured over the datalinks under the phys class.