6.6. Working with and Modifying Network Configuration

The Rocks database holds information that has been discovered about a host and in particular records network interface information including MAC addresses and local device modules. The Rocks command line has several tools to inspect and update entries in the database. Reinstallation of a node will apply the changes to a node. See the following section on Swapping Frontend Ethernet Interfaces.

For the following discussion, a frontend named "jeebs" will be used for illustation. To list the ethernet interfaces do the following:

# rocks list host interface jeebs

SUBNET  IFACE MAC               IP             NETMASK       MODULE NAME                    VLANID 
private eth0  00:0e:0c:a7:57:d7 10.1.1.1       255.0.0.0     e1000  jeebs                   ------ 
public  eth1  00:19:b9:21:b8:b6 172.19.119.241 255.255.255.0 tg3    jeebs.rocksclusters.org ------

This describes the two interfaces, eth0 and eth1. Suppose that it is desired to swap these two interfaces. That is we would want to associate the mac address 00:0e:0c:a7:57:d7 with eth1. To do this we must also associate the correct module. The following will change the information only in the database. This uses the rocks set host interface group of commands.

# rocks set host interface mac jeebs iface=eth1 mac=00:0e:0c:a7:57:d7
# rocks set host interface module jeebs iface=eth1 module=e1000

# rocks set host interface mac jeebs iface=eth0 mac=00:19:b9:21:b8:b6
# rocks set host interface module jeebs iface=eth0 module=tg3

Then the updated database configuration is as follows

# rocks list host interface jeebs
SUBNET  IFACE MAC               IP             NETMASK       MODULE NAME                    VLANID
private eth0  00:19:b9:21:b8:b6 10.1.1.1       255.0.0.0     tg3    jeebs                   ------ 
public  eth1  00:0e:0c:a7:57:d7 172.19.119.241 255.255.255.0 e1000  jeebs.rocksclusters.org ------

Note

After any such database change, always run rocks sync config. This will update service configuration files (like dhcpd).