dropdown menu

Ethernet Adapter

Ethernet Adapter

When an adapter is added to the host a logical device is created in the ODM such as: ent0, ent1 (for ethernet adapters).
A corresponding network interface in the kernel allows TCP/IP to use an adapter. The network interface (a logical device) is created at the same time as the adapter device: en0, en1.., et0, et1...

Network Interface is the software layer between the TCP/IP protocols and the device driver. (It hides the differences between different types of adapters from TCP/IP)

Ethernet adapters can be configured to support either Ethernet Version 2 (en) or IEEE802.3 (et) network interface driver software. The difference between the two is in the packets header information. (On IEEE802.3, after Source Addres the length of the packet comes, however on Ethernet it shows the TYPE(TCP/IP...))


TCP/IP support in AIX is provided by a kernel extension called inet0. (A kernel extension is a separate entity from the kernel but runs in the kernel address space.) inet0 provides the IP, TCP, UDP functions. Configuration information for inet0 is stored in the ODM. The system defines a logical device in the ODM-inet0-which is related to hostname and routing information.


The notation ent0 is used to specify the hardware adapter. It has nothing to do with the TCP/IP address.

en0 represents the interface associated with hardware adapter ent0. The TCP/IP address is associated with this interface.

et0 represents the interface associated with hardware adapter ent0. The notation et0 is used for IEEE 802.3

it represents a network device (physically doesn't exists), keeps attributes, infos from the actual network settings (hostname, routes..)


Types of adapters:

TX (CX) - copper base
SX, LX  - fibre base


Maximum Transmission Unit
A piece of data traveling on a network is known a datagram. A datagram travels in network frames. Physical networks can place an upper limit, that can fit into a physical frame. This limit is known as the MTU IMaximum Transmission Unit)

Datagrams that are larger than the MTU size will be fragmented, thus the performance won't be optimum. (fragment, reassembly).
With the ifconfig or route command you can specify the MTU size:
-ifconfig enX mtu 1500
-route add -net -netmask -mtu 1500

Changing Network Interface Attributes:
chdev -l en0 -a tcp_recvspace=65536 -a tcp_sendspace=65536        <--change these attributes permanently (make changes in the ODM)
ifconfig en0 hostname tcp_recvspace 65536 tcp_sendspace 65536 tcp_nodelay 1 <--temporary changings, new settings are lost after reboot


netstat -i                      shows if an interface is up or not
netstat -v                      shows device driver information
netstat -v |grep Media          shows running speed (100Mbs..., Full duplex) (netstat -v | egrep 'ETH|Media|Link')

chdev -l en2 -a state=detach    detach a device (chdev -l en2 -a state=up will put it back)
ifconfig en3 detach             detach a device (mkdev -l en3 will put it back to online state, or if it was defined then puts to available state)

chdev - changes are effective immediately and across boots
ifconfig - changes are active immediately and are effective until reboot

Media Speed setting:
1. smitty inet -> change show -> detach     or    (chdev -l enX -a state=detach)    or    (ifconfig enX deatch)    or    (rmdev -l enX)   

2. smitty chgenet                           or     chdev -l entX -a media_speed=1000_Full_Duplex

3. smitty inet -> change show -> up        or    (chdev -l enX -a state=up)         or    (mkdev -l enX)        or    (cfgmgr)

lsattr -Rl ent0 -a media_speed    <--shows which values can be chosen for media_speed

after detaching an interface, routes can be lost from netstat -nr
"mkdev -l inet0" will put back. (if it was not before in the inet0 (odm) then I guess you should put back manually those)


CHANGING AN INTERFACE (en2) HOT PLUG: (per the book)

1. lsslot -c pci                 <--displays the hot plug slots (ifconfig -a, for checking enX, that it is in the list)
2. ifconfig enX down             <--bring the interface down
3. ifconfig enX detach           <--delete the network interface definition for the adapter (ifconfig -a: check it is not in the list)
4. rmdev -dl enX; rmdev -dl entX <--delete the network interface driver for the adapter
5. diag --> Task Slection --> Hot Plug Task --> PCI Hot Plug Manager
6. after replacement  --> go back PCI Hot Plug Manager --> Configure ... ???or cfgmgr???


if Link status is up, but ping does not work, try changing the speed settings. (Auto, 1000...)


ra said...

awesome post!

Anonymous said...

This is perfect article, thank you :)

aix said...


Anonymous said...

Excellent Information.....

aix said...


Unknown said...

How to know the % of nic utilization for Ethernet adapter..for ex:ent0

Anonymous said...

I understand that,"Changing Network Interface Attributes" can be done using ifconfig/chdev comamnd. That will make changes to the corresponding interface (en0/1)
But my question is i've seen the same parameters using "no" command.

I was trying to change the "tcp_recvspace tcp_sendspace " values on my LPAR.

when i ran "no -a" , it still showing the default values even after i changing the en0 using ifconfig. But "ifconfig -a" o/p showing the correct info.
i am kind of consfused here.

we can change the "tcp_recvspace tcp_sendspace" values using "no" comamnd as well as "ifconfig/chdev" commands. Can you please give me some idea on this ?


aix said...

Hi, I think at the beginning of this link you will get some explanataion: http://publib.boulder.ibm.com/infocenter/pseries/v5r3/index.jsp?topic=/com.ibm.aix.commadmn/doc/commadmndita/interfaces_options.htm

(Basically tcp_recvspace and tcp_sendspace variables exists twice. There is a system wide paramater with these names (you can check it with no command) there there is an interface specific parameter with these names (you can check it with ifconfig).

Hope this helps,

Fazil said...

Awsome BLog , Thank You For you Efforts

SKT said...

Hi........Thank you.........There is typo at command "ifconfig enX deatch" (detach) :)