By virtual interfaces in Virtual NIC mode, activation and deactivation are performed in conjunction with the network service of the operating system. Therefore, virtual interfaces keep the active state even when restarting GLS by the resethanet command.
In Virtual NIC mode, define the settings of IP addresses in the interface setting file (/etc/sysconfig/network-scripts/ifcfg-shaX) same as for usual NICs. As in other communication modes, it is not required to set IP addresses by using the hanetconfig command.
The Virtual NIC mode cannot be used if the tagged VLAN interfaces are set for the physical interfaces.
In Virtual NIC mode, the interface setting file of a virtual interface (/etc/sysconfig/network-scripts/ifcfg-shaX) is created and deleted at the following timing:
For creation: when a virtual interface is set by using the "hanetconfig create" command.
For deletion: when a virtual interface is deleted by using the "hanetconfig delete" command.
For RHEL7 or later, when the libvirtd service is started by starting OS, NIC (for example: 10G NIC) which supports LRO (large-receive-offload) function may link down temporally. In this case, GLS detects a link down of NIC and an error message may be output to the system log.
To prevent a link down, perform one of the following actions:
Set "1" to "net.ipv4.ip_forward = "in the /etc/sysctl.conf file.
Disable the libvirtd service. (when the virtual machine function is not used.)
For details, refer to "Linux documentation".
When the physical NIC settings are changed by using the ethtool command, the physical NIC driver is occasionally reset. At that time, the virtual interface detects a link down temporarily.
When modifying the length of MTU for an interface, set the same value for the configuration file (ifcfg-ethX) of the primary interface and the secondary interface, and for the virtual interface configuration file (ifcfg-shaX). The changed value is valid after a system reboot.
# cat /etc/sysconfig/network-scripts/ifcfg-eth1 DEVICE=eth1 (...) MTU=9000 # cat /etc/sysconfig/network-scripts/ifcfg-eth2 DEVICE=eth2 (...) MTU=9000 # cat /etc/sysconfig/network-scripts/ifcfg-sha0 DEVICE=sha0 (...) MTU=9000 |
The interface created by SR-IOV cannot be used.
The physical interface name that starts with capital or lower-case "a" - "r" can be used in the virtual NIC mode.
When modifying MTU, make sure to set 1280 or more.
For the configuration where the virtual bridge is connected with the virtual interface of the Virtual NIC mode, the following message may be output on the system log when activating the virtual interface or dynamically adding or deleting the interface. Ignore this message.
kernel: brX: received packet on shaX with own address as source address |
For the multiple configurations where the virtual bridge is connected with the virtual interface of the Virtual NIC mode,the following message may be output on the system log during communication. Ignore this message.
kernel: shaX: received packet with own address as source address |
If the firewalld service is enabled, the virtual interface works in the default zone after the OS is restarted, depending on the OS version.
Check the zone where the virtual interface works by using the firewall-cmd --get-active-zones command.
If the LLDP (Link Layer Discovery Protocol) function of the physical interface is enabled, set the MAC address or "auto" to SHAMACADDR.
If the following kernel parameters were set when using the Virtual NIC mode, delete the settings from the kernel parameters configuration files. Otherwise, the kernel parameters set by GLS are overwritten and GLS may not operate properly.
net.ipv6.conf.all.disable_ipv6 = X net.ipv6.conf.default.disable_ipv6 = X net.ipv6.conf.<dev>.disable_ipv6 = X |
X: value
<dev>: NIC bundled by the virtual interface of GLS
Kernel parameters configuration files that the target value is set are as follows.
OS | Kernel parameters configuration files |
---|---|
RHEL7 | /etc/sysctl.conf |
RHEL8 | /etc/sysctl.conf |