Bookmark this page

Guided Exercise: Editing Network Configuration Files

In this lab, you will edit network configuration files.

Outcomes

An additional network address added to each system.

Reset your serverX and desktopX systems.

  1. As the root user, edit the /etc/sysconfig/network-scripts/ifcfg-eth0 on serverX to add an additional address of 10.0.X.1/24.

    1. Append an entry to the file to specify the IPv4 address.

      [root@serverX ~]# echo "IPADDR1=10.0.X.1" >> /etc/sysconfig/network-scripts/ifcfg-eth0
      
    2. Append an entry to the file to specify the network prefix.

      [root@serverX ~]# echo "PREFIX1=24" >> /etc/sysconfig/network-scripts/ifcfg-eth0
      
  2. Activate the new address.

    1. Reload the configuration changes.

      [root@serverX ~]# nmcli con reload
      
    2. Restart the connection with the new settings.

      [root@serverX ~]# nmcli con up "System eth0"
      
  3. As the root user, edit the /etc/sysconfig/network-scripts/ifcfg-eth0 on desktopX to add an additional address of 10.0.X.2/24 and load the new configuration.

    1. Modify the file to add the IPv4 and network prefix.

      [root@desktopX ~]# echo "IPADDR1=10.0.X.2" >> /etc/sysconfig/network-scripts/ifcfg-eth0
      [root@desktopX ~]# echo "PREFIX1=24" >> /etc/sysconfig/network-scripts/ifcfg-eth0
      
    2. Reload the configuration changes.

      [root@desktopX ~]# nmcli con reload
      
    3. Bring up the connection with the new settings.

      [root@desktopX ~]# nmcli con up "System eth0"
      
  4. Test the connectivity using the new network addresses.

    1. On serverX, verify the IP address.

      [root@serverX ~]# ip addr
      
    2. On serverX, ping the new address of desktopX.

      [root@serverX ~]# ping 10.0.X.2
      
    3. On desktopX, verify the IP address.

      [root@desktopX ~]# ip addr
      
    4. On desktopX, ping the new address of serverX.

      [root@desktopX ~]# ping 10.0.X.1
      
Revision: rh124-7-1b00421