码迷,mamicode.com
首页 > 系统相关 > 详细

Kali Linux下设置静态IP

时间:2018-01-09 12:57:50      阅读:278      评论:0      收藏:0      [点我收藏+]

标签:pos   htm   com   配置dns   sys   init   mes   file   describes   

 

一、 在文件系统里找到/etc/network下的interfaces文件修改成如下

# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5)。
# The loopback network interface

auto eth0
iface eth0 inet static
address 192.168.18.128
netmask 255.255.255.0
gateway 192.168.18.1
auto lo
iface lo inet loopback
二,配置DNS,找到/etc/resolv.conf这个文件,然后替换内容

# Generated by NetworkManager
nameserver 114.114.114.114
nameserver 8.8.8.8

 

 

最后,/etc/init.d/networking restart重启网络

技术分享图片

 

Kali Linux下设置静态IP

标签:pos   htm   com   配置dns   sys   init   mes   file   describes   

原文地址:https://www.cnblogs.com/xxrens/p/8250808.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!