lasdaybg

ubuntu环境修改IP地址方法和CentOS系统修改方法不太一样。ubuntu系统修改IP地址方法如下:

编辑/etc/network/interfaces,增加以下内容:

auto eth0
iface eth0 inet static
address 192.168.1.100
gateway 192.168.1.1
netmask 255.255.255.0

修改完之后执行以下命令重启网卡:

/etc/init.d/networking restart

或者执行这个命令也可以重启网卡:

systemctl restart networking

如果网卡重启失败,可以执行以下命令查看日志:

journalctl -xe

 

分类:

技术点:

相关文章:

  • 2021-11-05
  • 2022-01-02
  • 2022-01-21
  • 2022-12-23
  • 2021-11-24
  • 2022-12-23
  • 2021-12-02
猜你喜欢
  • 2021-10-15
  • 2021-05-12
  • 2021-09-19
  • 2021-12-28
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案