Wednesday, May 29, 2013

How to add virtual IP in AIX

Adding virtual IP address to an existing network interface is pretty easy.

You can try doing it with smitty - I've found two ways in getting to the required screen:
smitty tcpip --> Further configuration -->Network interface -->Network interface selection -->Configure alias --> Add an IPV4 Network Alias 
Here select the available interface  and press enter and the Next screen, we need to insert an IP address and the relative subnet mask and press enter.

Second way:
smitty netinterface -> Network Interface Selection -> Configure Aliases

You can also do it directly from the command line:
chdev -l en0 -a alias4=,

and remove this alias using:
chdev -l en0 -a delalias4=,

Once configured this alias will be persistent over reboots.
You can add multiple aliases to one network interface.
To verify if alias was setup correctly run:
# ifconfig -a
        inet netmask 0xffffff00 broadcast
        inet netmask 0xffffff00 broadcast
         tcp_sendspace 131072 tcp_recvspace 65536 rfc1323 0
        inet netmask 0xff000000 broadcast
        inet6 ::1/0

         tcp_sendspace 131072 tcp_recvspace 131072 rfc1323 1

No comments:

Post a Comment