Podcast
Questions and Answers
Where should the interface name be placed in relation to the word 'auto'?
Where should the interface name be placed in relation to the word 'auto'?
What is the purpose of the 'iface' configuration line?
What is the purpose of the 'iface' configuration line?
What is the purpose of the 'auto' keyword in an interface configuration file?
What is the purpose of the 'auto' keyword in an interface configuration file?
What is the address family used for TCP/IP networking?
What is the address family used for TCP/IP networking?
Signup and view all the answers
What is the purpose of the 'dhcp' method in an interface configuration file?
What is the purpose of the 'dhcp' method in an interface configuration file?
Signup and view all the answers
Study Notes
Interface Naming Convention
- Linux uses a predictable naming convention for network interfaces to identify which device and port corresponds to which interface.
- The naming convention starts with a two-character prefix indicating the interface type:
- en: Ethernet
- ib: InfiniBand
- sl: Serial line IP (slip)
- wl: Wireless local area network (WLAN)
- ww: Wireless wide area network (WWAN)
- The naming convention follows a priority order:
- Naming after the BIOS or firmware index (e.g., eno1)
- Naming after the PCI express slot index (e.g., ens1)
- Naming after the bus address (e.g., enp3s5)
- Naming after the MAC address (e.g., enx78e7d1ea46da)
- Naming using the legacy convention (e.g., eth0)
Configuration Files
- Configuration files for network interfaces are stored in
/etc/systemd/network
and/lib/systemd/network
. - Files with different suffixes have different purposes:
-
.netdev
: creates virtual network devices (e.g., bridge or tun devices) -
.link
: sets low-level configurations for network interfaces -
.network
: sets up network addresses and routes
-
- The name of the file determines the order in which it is processed.
- The
[Match]
section in the file defines the network interface to which the configuration applies.
Network Interface Configuration
- The
[Network]
section in the file defines the settings for the device. - The interface name should follow the word
auto
on the same line. - Interfaces marked
auto
are brought up at boot time in the order they are listed. - The
iface
line specifies the interface name, address family, and method used to configure the interface. - Examples of address families and methods:
-
inet
for TCP/IP networking -
ipx
for IPX networking -
inet6
for IPv6 networking -
loopback
for loopback interfaces -
dhcp
for using IP settings from a DHCP server
-
Studying That Suits You
Use AI to generate personalized quizzes and flashcards to suit your learning preferences.
Related Documents
Description
Learn about the evolution of Linux network interface naming conventions, from eth0 to the current system, and how it clarifies device and port identification.