User`s guide

Chapter I. Chelsio Unified Wire
Chelsio T5/T4 Unified Wire For Linux Page 44
5.2. Creating network-scripts
To spot the new interfaces, make sure the driver is unloaded first. To that point ifconfig -a |
grep HWaddr should display all non-chelsio interfaces whose drivers are loaded, whether the
interfaces are up or not.
[root@host]# ifconfig -a | grep HWaddr
eth0 Link encap:Ethernet HWaddr 00:30:48:32:6A:AA
Then load the driver using the modprobe cxgb4 command (for the moment it does not make
any difference whether we are using NIC-only or the TOE-enabling driver). The output of
ifconfig should display the T5/T4 interfaces as:
[root@host]# ifconfig -a | grep HWaddr
eth0 Link encap:Ethernet HWaddr 00:30:48:32:6A:AA
eth1 Link encap:Ethernet HWaddr 00:07:43:04:6B:E9
eth2 Link encap:Ethernet HWaddr 00:07:43:04:6B:F1
eth3 Link encap:Ethernet HWaddr 00:07:43:04:6B:F9
eth4 Link encap:Ethernet HWaddr 00:07:43:04:6C:01
For each interface you can write a configuration file in /etc/sysconfig/network-scripts.
The ifcfg-eth1 could look like:
# file: /etc/sysconfig/network-scripts/ifcfg-eth1
DEVICE="eth1"
HWADDR=00:07:43:04:6B:E9
ONBOOT="no"
NM_CONTROLLED="no"
BOOTPROTO="static"
IPADDR=10.192.167.112
NETMASK=255.255.240.0
From now on, the eth1 interface of the adapter can be brought up and down through the ifup
eth1 and ifdown eth1 commands respectively. Note that it is of course not compulsory to
create a configuration file for every interface if you are not planning to use them all.