网络连接配置

1.编辑网卡配置文件

nano /etc/network/interfaces

2.网络配置格式参考(interface 文件):

# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto ens10f0
iface ens10f0 inet static
address 172.17.69.139
netmask 255.255.192.0
gateway 172.17.70.222

# The primary network interface
auto ens10f1
iface ens10f1 inet static
address 192.168.1.139
netmask 255.255.255.0

# The primary network interface
auto ens10f2
iface ens10f2 inet static
address 192.168.2.100
netmask 255.255.255.0

# The primary network interface
auto ens10f3
iface ens10f3 inet static
address 192.168.3.100
netmask 255.255.255.0

 

posted @ 2025-01-08 16:04  BlackSnow  阅读(25)  评论(0)    收藏  举报