Table of ContentsLibraryView in Frames

Creating and removing aliases

You might need to create or remove an alias if you are changing the IP address of an interface. Use the alias command to create an alias IP address, and use the -alias command to remove an alias IP address.

Step

  1. Enter the following command: ifconfig interface_name [-]alias address

    Note: For IPv4, you can add an alias address only if a primary address for the interface exists. For IPv6, the link-local and autoconfigured addresses are automatically added as alias addresses even without a primary address configured for an interface.

Example

The following example gives the interface e0 (already configured with IP address 172.28.50.21) the alias IP address 172.28.50.30:

ifconfig e0 alias 172.28.50.30

The following example removes the 172.28.50.30 alias for the interface e0 specified in the previous example:

ifconfig e0 -alias 172.28.50.30