Configuring a Network Interface
Listing Network Interfaces
To list all network interfaces:
Run the following command:
ifconfig
Configuring a Static IP Address for a Network Interface
To configure a static IP address for a network interface:
1 In nmtui, navigate to Edit a connection and press Enter.
The following window opens, displaying all network adapters attached to the CTERA Portal server.
2 Navigate to the network adapter for which you want to set a static IP address and press Enter.
The Edit connection window is displayed.
3 Navigate to Automatic next to IPv4 CONFIGURATION, press Enter, and then select Manual.
4 Navigate to Show next to IPv4 CONFIGURATION and press Enter.
Additional fields are displayed.
5 Navigate to Add next to Addresses and press Enter.
6 Type the static IP address.
To specify a subnet mask, use the classless inter-domain routing (CIDR) notation. For example:
To set a class C subnet mask [255.255.255.0], use:
IP_Address/24, for example, 192.168.93.204/24
To set a class B subnet mask [255.255.0.0], use:
IP_Address/16, for example, 192.168.93.204/16
7 To configure a default gateway for the current network interface, navigate to Gateway, and then type the IP address of the default gateway.
8 To configure a DNS server, navigate to Add next to DNS servers, press Enter, and then enter the IP address of the DNS server.
Note: You can add multiple DNS servers if desired, by repeating this step.
In the following example, the network interface named eth0 has the static IP address 192.168.98.204, the default gateway address 192.168.90.1, and the two DNS servers 192.168.88.20 and 192.168.88.21.
9 Navigate to OK and press Enter.
10 Navigate to Quit and press Enter to exit nmtui.
11 Restart the network service by typing the command: service network restart
Your changes take effect.
Enabling DHCP for a Network Interface
If you want to use DHCP, for example, for a demo, and you are configured to use a static IP, you can change to DHCP using nmtui.
To enable DHCP for a network interface:
1 In nmtui, navigate to Edit a connection and press Enter.
The following screen opens, displaying all network adapters attached to the CTERA Portal server.
2 Navigate to the network adapter for which you want to enable DHCP, and then press Enter.
The Edit connection screen is displayed.
3 Navigate to Manual next to IPv4 CONFIGURATION, press Enter, and then select Automatic.
4 Navigate to OK and press Enter.
5 Navigate to Quit and press Enter to exit nmtui.
6 Restart the network service, by entering the command: service network restart
Your changes take effect.
Deactivating a Network Interface
To deactivate a network interface:
1 In nmtui, navigate to Activate a connection and press Enter.
The following screen opens, displaying all network adapters attached to the CTERA Portal server.
The asterisk (*) to the left of a network adapter's name indicates that the network adapter is activated.
2 Navigate to the activated network adapter you want to deactivate, a network adapter with an asterisk, and press Enter.
3 Navigate to Quit and press Enter to exit nmtui.
The network adapter is deactivated.
Activating a Network Interface
To activate a network interface
1 In nmtui, navigate to Activate a connection and press Enter.
The following screen opens, displaying all network adapters attached to the portal server:
2 Navigate to the deactivated network adapter you want to activate, a network adapter without an asterisk, and press Enter.
3 Navigate to Quit and press Enter to exit nmtui.
The network adapter is deactivated.
The asterisk (*) to the left of a network adapter's name indicates that the network adapter is activated.