Ubuntu下手動配置IP的方法

/etc/network/interfaces 是網絡配置文件網絡

修改該文件:ide

  
  
           
  
  
  1. auto lo 
  2. iface lo inet loopback 
  3.  
  4. iface eth0 inet static 
  5. address 192.168.2.88 
  6. netmask 255.255.255.0 
  7. gateway 192.168.2.2 
  8. auto eth0 

即配置接口eth0的ip,配置後重啓網卡,oop

  sudo ifdown eth0spa

  sudo ifup eth0xml

輸入: ip a  查看eth0的信息接口

相關文章
相關標籤/搜索