System Administration Guide: Network Interfaces and Network Virtualization

ProcedureHow to Add or Remove IP Addresses

You use the ifconfig addif syntax to add addresses or the ifconfig removeif command to remove addresses from interfaces. In the current IPMP implementation, test addresses are hosted on the underlying IP interface, while data addresses are assigned to the IPMP interface. The following procedures describes how to add or remove IP addresses that are either test addresses or data addresses.

  1. Assume the role of Primary Administrator, or become superuser.

    The Primary Administrator role includes the Primary Administrator profile. To create the role and assign the role to a user, see Chapter 2, Working With the Solaris Management Console (Tasks), in System Administration Guide: Basic Administration.

  2. Add or remove data addresses.

    • To add data addresses to the IPMP group, type the following command:


      # ifconfig ipmp-interface addif ip-address up
      
    • To remove an address from the IPMP group, type the following command:


      # ifconfig ipmp-interface removeif ip-address
      
  3. Add or remove test addresses.

    • To assign a test address to an underlying interface of the IPMP group, type the following command:


      # ifconfig interface addif -failover ip-address up
      
    • To remove a test address from an underlying interface of the IPMP group, type the following command:


      # ifconfig interface removeif ip-address
      

Example 8–5 Removing a Test Address From an Interface

The following example uses the configuration of itops0 in Example 8–2. The step removes the test address from the interface subitops0.


# ipmpstat -t
INTERFACE      MODE     TESTADDR        TARGETS
subitops0      routes   192.168.10.30   192.168.10.1

# ifconfig subitops0 removeif 192.168.85.30