Product SiteDocumentation Site

Chapter 2. Configure Networking

2.1. Static and Dynamic Interface Settings
2.1.1. When to Use Static Network Interface Settings
2.1.2. When to Use Dynamic Interface Settings
2.1.3. Selecting Network Configuration Methods
2.2. Using NetworkManager with the GNOME Graphical User Interface
2.2.1. Connecting to a Network Using a GUI
2.2.2. Configuring New and Editing Existing Connections
2.2.3. Connecting to a Network Automatically
2.2.4. System-wide and Private Connection Profiles
2.2.5. Configuring a Wired (Ethernet) Connection
2.2.6. Configuring a Wi-Fi Connection
2.2.7. Establishing a VPN Connection
2.2.8. Establishing a Mobile Broadband Connection
2.2.9. Establishing a DSL Connection
2.2.10. Configuring Connection Settings
2.3. Using the Command Line Interface (CLI)
2.3.1. Configuring a Network Interface Using ifcfg Files
2.3.2. Configuring a Network Interface Using ip Commands
2.3.3. Static Routes and the Default Gateway
2.3.4. Configuring Static Routes in ifcfg files
2.3.5. Configuring IPv6 Tokenized Interface Identifiers
2.4. Using the NetworkManager Command Line Tool, nmcli
2.4.1. Understanding the nmcli Options
2.4.2. Connecting to a Network Using nmcli
2.4.3. Configuring Static Routes Using nmcli
2.5. Additional Resources
2.5.1. Installed Documentation
2.5.2. Online Documentation

2.1. Static and Dynamic Interface Settings

When to use static addressing and when to use dynamic addressing? These decisions are subjective, they depend on your accessed needs, your specific requirements. Having a policy, documenting it, and applying it consistently are usually more important than the specific decisions you make. In a traditional company LAN, this is an easier decision to make as you typically have fewer servers than other hosts. Provisioning and installation tools make providing static configurations to new hosts easy and using such tools will change your work flow and requirements. The following two sections are intended to provide guidance to those who have not already been through this decision-making process. For more information on automated configuration and management, see the OpenLMI section in the Fedora 25 System Administrator's Guide. The Fedora 25 System Installation Guide documents the use of kickstart which can also be used for automating the assignment of network settings.

2.1.1. When to Use Static Network Interface Settings

Use static IP addressing on those servers and devices whose network availability you want to ensure when automatic assignment methods, such as DHCP, fail. DHCP, DNS, and authentication servers are typical examples. Interfaces for out-of-band management devices are also worth configuring with static settings as these devices are supposed to work, as far as is possible, independently of other network infrastructure.
For hosts which are not considered vital, but for which static IP addressing is still considered desirable, use an automated provisioning method when possible. For example, DHCP servers can be configured to provide the same IP address to the same host every time. This method could be used for communal printers for example.
All the configuration tools listed in Section 2.1.3, “Selecting Network Configuration Methods” allow assigning static IP addresses manually. The nmcli tool is also suitable for use with scripted assignment of network configuration.

2.1.2. When to Use Dynamic Interface Settings

Enable and use dynamic assignment of IP addresses and other network information whenever there is no compelling reason not to. The time saved in planning and documenting manual settings can be better spent elsewhere. The dynamic host control protocol (DHCP) is a traditional method of dynamically assigning network configurations to hosts. See Section 9.1, “Why Use DHCP?” for more information on this subject.
NetworkManager will by default call the DHCP client, dhclient, when a profile has been set to obtain addresses automatically, or when an interface configuration file has BOOTPROTO set to dhcp. Where DHCP is required, an instance of dhclient is started for every Internet protocol, IPv4 and IPv6, on an interface. Where NetworkManager is not running, or not managing an interface, then the legacy network service will call instances of dhclient as required.

2.1.3. Selecting Network Configuration Methods