Experience in administering a Solaris Unix box made me think changing the speed of a network interface can be a simple execution of a series of commands -- but not in AIX. My experience was not so simple.
Recently while trying to change the speed of a NIC in an AIX box, I got into errors. Errors which I discovered to be a common discussion among system administrators in the web. The error is below:
Method error (/usr/lib/methods/chgent):
0514-062 Cannot perform the requested function because the
specified device is busy.
This was after the interface was "down"-ed and "detach"-ed, executing "chdev -l ent0 -a media_speed=1000_Full_Duplex". Being an AIX sysad amateur myself, I came to consult a colleague who has more in-depth knowledge and experience in AIX. I am grateful for his insight into the matter and here is the outline of what he did.
Here is a brief background of our objective -- change the NIC speed from Auto_Negotiation to 1000_Full_Duplex in an AIX box. And the workplan in place is:
[1] ifconfig en0 down detach
[2] chdev -l ent0 -a state=detach
[3] chdev -l ent0 -a media_speed=1000_Full_Duplex
[4] smit chinet >> (select interface) and change Current STATE to "up"
(NOTE: using "ifconfig en0 up" here sometimes assigns IP address of 0.0.0.0, so use smit instead)
[5] mkdev -l en0
I never got to execute beyond step [3] due to the error. So I sought for help.
What we did was to modify step [3] and inserted another step in the procedure : rmdev -l ent0. Which when executed outputs:
# rmdev -l ent0
ent0 Defined
After which, succeeding steps in the procedure above went smoothly.
To verify the change, execute entstat on the interface:
# entstat -d ent0 | grep Speed
Media Speed Selected: 1000 Mbps / 1 Gbps, Full Duplex
Media Speed Running: 1000 Mbps / 1 Gbps, Full Duplex
Another remarkable point to note here is that in step [4] of the original procedure, executing ifconfig to change the state of the device to "up" sometimes assigns it an IP address of 0.0.0.0.
As a Solaris sysad, this change in AIX was very much new to me. But hey, it is not bad to learn something new. And I hope that by sharing the inserted step in the above procedure, this little experience might be able to help other sysads stuck in the same error.