This article is supplemental to a previous tech blog – How to create bonded interfaces on OnApp cloudboot compute nodes.
I wanted to offer additional information that will be useful if you plan to migrate your existing CentOS 6 cloudboot compute nodes to CentOS 7, or create a new installation with bonded interfaces.
In the article linked above, we provided information on how to create a storage bond using the following methods:
- By assigning two or more NICs to the SAN via the GUI at the Edit Devices page, and then selecting the SAN bonding mode while editing a compute resource.
- By adding five commands to the Custom config section while editing a compute resource, and in such a way create an appliance bond from two NICs.
However, it has been recently discovered that if both methods are used simultaneously on CentOS 7 KVM compute resources, the SAN bonding mode setting is not applied for a compute resource. It results in the MTU config bring set to 1500, not to the value you provide while editing a compute resource.
On the other hand, everything works as expected on CentOS 7 KVM compute resources with one NIC assigned to a storage network, or without bonds in the custom config.
So what is going on? The cause of the issue is related to the way OnApp creates onappstorebond interface, and it may cause incompatibilities while using the custom config bonding scripts.
As a workaround to overcome this issue, you can add the next delay in the top of your custom config, or before the user bonding scripts:
You can also face another issue if you used an example of custom config provided in the previous article. The following example is not applicable to CentOS 7 KVM compute resources due to a change in the usual ifconfig output:
nic0=`ifconfig -a | grep -i 00:0E:1E:45:95:74 | cut -f1 -d " " ` nic1=`ifconfig -a | grep -i 00:0E:1E:45:95:74 | cut -f1 -d " "
As a workaround to overcome this issue, you can change the custom config to the following:
nic0=`ifconfig -a | grep -i 00:0E:1E:45:95:74 -B1 | grep ^eth | cut -c -4` nic1=`ifconfig -a | grep -i 00:0E:1E:45:95:76 -B1 | grep ^eth | cut -c -4`
As a result, your overall custom config will look as follows:
sleep 30 nic0=`ifconfig -a | grep -i 00:0E:1E:45:95:74 -B1 | grep ^eth | cut -c -4` nic1=`ifconfig -a | grep -i 00:0E:1E:45:95:76 -B1 | grep ^eth | cut -c -4` echo -e 'DEVICE=appbond\nTYPE=BOND\nBONDING_OPTS="mode=4"'>/etc/sysconfig/network-scripts/ifcfg-appbond ifup appbond ifenslave appbond $nic0 $nic1
I hope you find this information useful. If you need more assistance with your OnApp cloud, open a support ticket and the cloud architecture team will be happy to help!