2.5. IP Address Configuration

The first subsection below describes network interface and IP address issues that must be considered when planning a Linux FailSafe system. The second subsection gives an example of the configuration of network interfaces and IP addresses on a Linux FailSafe system. The third subsection explains the aspects of the configuration that must be specified for a Linux FailSafe configuration.

2.5.1. Planning Network Interface and IP Address Configuration

Follow these guidelines when planning the configuration of the interfaces to the private network between nodes in a cluster that can be used as a control network between nodes (this information is used when you define the nodes):

Follow these guidelines when planning the configuration of the node interfaces in a cluster to one or more public networks:

Follow the procedure below to determine whether re-MACing is required (see Section 1.8.2, for information about re-MACing). It requires the use of three nodes: node1, node2, and node3. node1 and node2 can be nodes of a Linux FailSafe cluster, but they need not be. They must be on the same subnet. node3 is a third node. If you need to verify that a router accepts gratuitous ARP packets (which means that re-MACing is not required), node3 must be on the other side of the router from node1 and node2.

  1. Configure an IP address on one of the interfaces of node1:

    # /sbin/ifconfig interface inet ip_address netmask netmask up

    interface is the interface to be used access the node. ip_address is an IP address for node1. This IP address is used throughout this procedure. netmask is the netmask of the IP address.

  2. From node3, ping the IP address used in Step 1 :

    # ping -c 2 ip_address
    PING 190.0.2.1 (190.0.2.1): 56 data bytes
    64 bytes from 190.0.2.1: icmp_seq=0 ttl=255 time=29 ms
    64 bytes from 190.0.2.1: icmp_seq=1 ttl=255 time=1 ms
    
    ----190.0.2.1 PING Statistics----
    2 packets transmitted, 2 packets received, 0% packet loss
    round-trip min/avg/max = 1/1/1 ms
  3. Enter this command on node1 to shut down the interface you configured in Step1 :

    # /sbin/ifconfig interface down
  4. On node2, enter this command to move the IP address to node2:

    # /sbin/ifconfig interface inet ip_address netmask netmask up
  5. From node3, ping the IP address:

    # ping -c 2 ip_address

    If the ping command fails, gratuitous ARP packets are not being accepted and re-MACing is needed to fail over the IP address.

2.5.2. Example IP Address Configuration

For this example, you are configuring an IP address of 192.26.50.1. This address has a network mask of 255.255.255.0, a broadcast address of 192.26.50.255, and it is configured on interface eth0.

In this example, you are also configuring an IP address of 192.26.50.2. This address also has a network mask of 255.255.255.0, a broadcast address of 192.26.50.255, and it is configured on interface eth1.

Table 2-3, shows the Linux FailSafe configuration parameters you specify for these IP addresses.

Table 2-3. IP Address Configuration Parameters

Resource Attribute

Resource Name: 192.26.50.1

Resource Name: 192.26.50.2

network mask

255.255.255.0

255.255.255.0

broadcast address

192.26.50.255

192.26.50.255

interface

eth0

eth1

2.5.3. Local Failover of IP Addresses

You can configure your system so that an IP address will fail over to a second interface within the same host, for example from eth0 to eth1 on a single node. A configuration example that shows the steps you must follow for this configuration is provided in Section 6.3