Linux網絡卡配置檔案引數詳解

2021-08-28 13:35:33 字數 617 閱讀 7241

device=eth0 #指出裝置名稱

nm_controlled=yes #network mamager的引數,實時生效,不需要重啟

onboot=yes #設定為yes,開機自動啟用網路連線

ipaddr=192.168.21.129 #ip位址

bootproto=none #設定為none禁止dhcp,設定為static啟用靜態ip位址,設定為dhcp開啟dhcp服務

netmask=255.255.255.0 #子網掩碼

dns1=8.8.8.8 #第乙個dns伺服器

type=ethernet #網路型別為:ethernet

gateway=192.168.21.2 #設定閘道器

dns2=8.8.4.4 #第二個dns伺服器

ipv6init=no #禁止ipv6

userctl=no #是否允許非root使用者控制該裝置,設定為no,只能用root使用者更改

hwaddr=00:0c:29:2c:e1:0f #網絡卡的mac位址

prefix=24

defroute=yes

ipv4_failure_fatal=yes

name="system eth0" #定義裝置名稱

linux網絡卡配置檔案引數

1.配置檔案位置 etc sysconfig network scripts ifcfg ens33 1.device ens33網絡卡的名字 2.hwaddr 00 0c 29 90 89 d9 hwaddr hardware address 硬體位址 mac位址 3.type ethernet ...

linux 網絡卡配置檔案詳解

配置檔案位置 etc sysconfig network scripts ifcfg eth0 1.device eth0 網絡卡的名字 2.hwaddr 00 0c 29 90 89 d9 hwaddr hardware address 硬體位址 mac位址 3.type ethernet 網路型...

網絡卡配置檔案內容詳解

linux網絡卡的配置檔案路徑為 etc sysconfig network scripts ifcfg eno16777736 這裡的名卡名eno16777736每個人的可能都不一樣,需注意自己真實的網絡卡名是什麼。type ethernet 網路型別 乙太網 bootproto static 1...