RHCSA Rapid Track
In this lab, you will edit network configuration files.
Outcomes
An additional network address added to each system.
Reset your serverX and desktopX systems.
As the root user, edit the
/etc/sysconfig/network-scripts/ifcfg-eth0on serverX to add an additional address of10.0..X.1/24Append an entry to the file to specify the IPv4 address.
[root@serverX ~]#echo "IPADDR1=10.0.X.1" >> /etc/sysconfig/network-scripts/ifcfg-eth0Append an entry to the file to specify the network prefix.
[root@serverX ~]#echo "PREFIX1=24" >> /etc/sysconfig/network-scripts/ifcfg-eth0
Activate the new address.
Reload the configuration changes.
[root@serverX ~]#nmcli con reloadRestart the connection with the new settings.
[root@serverX ~]#nmcli con up "System eth0"
As the root user, edit the
/etc/sysconfig/network-scripts/ifcfg-eth0on desktopX to add an additional address of10.0.and load the new configuration.X.2/24Modify 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-eth0Reload the configuration changes.
[root@desktopX ~]#nmcli con reloadBring up the connection with the new settings.
[root@desktopX ~]#nmcli con up "System eth0"
Test the connectivity using the new network addresses.
On serverX, verify the IP address.
[root@serverX ~]#ip addrOn serverX, ping the new address of desktopX.
[root@serverX ~]#ping 10.0.X.2On desktopX, verify the IP address.
[root@desktopX ~]#ip addrOn desktopX, ping the new address of serverX.
[root@desktopX ~]#ping 10.0.X.1