Library Table of Contents Index Previous Page (Alt-p) Next Page (Alt-n) Comments

Configuring aliases for an interface

About aliases  Top

An alias is an alternative IP address for an interface. An alias can be useful when you are changing the IP address of an interface to a new address, but also want to keep accepting packets addressed to the old IP address.

There are two alias options available for the ifconfig command:

Using the alias options  Top

You can use the alias option at the filer command line. However, the IP address configured using the alias option at the command line is lost if the filer reboots. If you want to make your changes persistent across reboots, include these changes in the /etc/rc file of the root volume.

You cannot set up an IP address and an alias for an interface with one ifconfig command; you must configure the IP address for the interface before setting up the alias.

The -alias option is useful when you want to stop using the IP address originally configured on an interface but do not want to reboot the filer.

Configuring and removing aliases  Top

To set or remove an alias for an interface, complete the following step.

Step

Action

1

Enter the following command:

ifconfig interface_name [alias | -alias] address [netmask 
mask]

Example

In the following example, the interface e0 (already configured with an IP address of 172.28.50.21) is set up with an alias IP address of 172.28.50.30:

ifconfig e0 alias 172.28.50.30 netmask 255.255.255.0 

Example

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

ifconfig e0 -alias 172.28.50.30

Library Table of Contents Index Previous Page (Alt-p) Next Page (Alt-n) Comments