天天看點

Debian 修改網絡配置

背景:下載下傳了Kali-Linux-2017.1-vm-amd64鏡像,在VM中打開後無法聯網

解決:

1. 修改IP配置檔案

vi /etc/network/interfaces

auto lo

iface lo inet loopback

auto eth0

iface eth0 inet static

pre-up ifconfig eth0 hw ether 00:0C:29:6D:59:32

address 192.168.1.116

netmask 255.255.255.0

gateway 192.168.1.1

注意:確定mac位址

2.修改dns

vi /etc/resolv.conf

nameserver 114.114.114.114

3.重新開機網絡服務

# sudo /etc/init.d/networking restart

--完成--

繼續閱讀