Email - ifcfg-eth0, relay servers
Email Solution · Config document · referenced from Relay servers
The first network interface of a relay server: its address in the internal VLAN 1168, where the internal email servers reach it. It has a gateway and is explicitly not the default route.
| Item | Value |
|---|---|
| Path on the server | /etc/sysconfig/network-scripts/ifcfg-eth0 |
| Shown here | DC2-A-VCMSR001 (dc2-a-vcmsr001.adm.example.net) |
| Also on | DC2-B-VCMSR001, a differently written file with the same meaning, see below |
| Placeholder | <ETH0_HWADDR> stands for the hardware address; the UUID line is empty in the archive |
| Activated with | the network service; NM_CONTROLLED="no" keeps NetworkManager away |
The file
# Interface DEVICE="eth0" NAME="eth0" TYPE="Ethernet" BOOTPROTO="none" ONBOOT="yes" UUID="" HWADDR="<ETH0_HWADDR>" NM_CONTROLLED="no" # IPv4 IPADDR="10.12.19.34" NETMASK="255.255.255.240" GATEWAY="10.12.19.46" DEFROUTE="no" IPV4_FAILURE_FATAL="no" # IPv6 IPV6ADDR="2001:db8:a2:b6f::f:2/64" IPV6_DEFAULTGW="2001:db8:a2:b6f::1" IPV6INIT="yes" IPV6_AUTOCONF="no" IPV6_DEFROUTE="no" IPV6_FAILURE_FATAL="no" IPV6_ADDR_GEN_MODE="stable-privacy" IPV6_PRIVACY="no"
Differences on the second relay
The file of DC2-B-VCMSR001 is not a copy with other addresses. It has no comments, the values are mostly unquoted and the lines are in another order; it looks like the file the installer wrote, edited by hand. Compared by meaning, diff leaves these differences.
| Host | Line | Value |
|---|---|---|
DC2-A-VCMSR001 | IPADDR | 10.12.19.34 |
DC2-B-VCMSR001 | IPADDR | 10.12.19.35 |
DC2-A-VCMSR001 | IPV6ADDR | 2001:db8:a2:b6f::f:2/64 |
DC2-B-VCMSR001 | IPV6ADDR | 2001:db8:a2:b6f::f:3/64 |
DC2-A-VCMSR001 | HWADDR | present |
DC2-B-VCMSR001 | HWADDR | not present; the UUID line holds a value |
DC2-B-VCMSR001 | DOMAIN | "oob.example.net pc.example.net adm.example.net cimc.example.net mgmt.example.net", only on this host |
DC2-B-VCMSR001 | ZONE | public, only on this host |
DC2-B-VCMSR001 | PROXY_METHOD, BROWSER_ONLY | none and no, only on this host |
DC2-B-VCMSR001 | IPV4_FAILURE_FATAL, NM_CONTROLLED | each written twice, with the same value |
NETMASK, GATEWAY, DEFROUTE=no, BOOTPROTO=none, ONBOOT=yes and the other IPv6 lines are the same on both.
Checked against RHEL 10.2
| As built | Today |
|---|---|
ifcfg-* files read by the network service, NM_CONTROLLED="no" | The legacy network scripts were deprecated in RHEL 8; RHEL 9 does not contain the network-scripts package; in RHEL 10 support for the ifcfg format was removed |
One file per interface under /etc/sysconfig/network-scripts | NetworkManager keyfiles under /etc/NetworkManager/system-connections/; on RHEL 9 nmcli connection migrate converts ifcfg profiles to keyfiles |
route-eth0 with <prefix> via <gateway> lines | Static routes are properties of the connection, set for IPv4 with nmcli connection modify <connection> +ipv4.routes "<prefix> <gateway>" |
Red Hat's advice today is not to write these profiles by hand at all, but to use nmcli, the network system role or the nmstate API. RHEL 7 itself left maintenance on 2024-06-30.