Debian10配置静态ip
查看网卡:ip addr修改网卡网络地址配置:vim /etc/network/interfaces配置模板:auto ${网卡名}iface ${网卡名} inet ${static}address ${IP}netmask ${netmask}gateway ${gateway}auto ens37iface ens37 inet staticaddress 10.10.100.31netma
·
查看网卡:ip addr
修改网卡网络地址配置:vim /etc/network/interfaces
配置模板:
auto ${网卡名}
iface ${网卡名} inet ${static}
address ${IP}
netmask ${netmask}
gateway ${gateway}
auto ens37
iface ens37 inet static
address 10.10.100.31
netmask 255.255.255.0
gateway 10.10.100.2
然后重启网卡:systemctl restart networking或者/etc/init.d/networking restart
或重启设备(重启网卡报错就重启设备):reboot
更多推荐
已为社区贡献3条内容
所有评论(0)