Linux——Kali配置静态ip以及配置apt源
配置Kali的eth0为静态ip⚠️ 在配置前Vmware提前为该虚拟机设置了桥接模式配置步骤:配置eth0的网卡配置(/etc/network/interfaces)#This is ethes propertiesauto eth0allow-hotplug eth0iface eth0 inet staticaddress 192.168.0.99netmask 255.255.255.0g
·
👨🏻🎓博主介绍:大家好,我是芝士味的椒盐,一名在校大学生,热爱分享知识,很高兴在这里认识大家🌟
🌈擅长领域:Java、大数据、运维、电子
🙏🏻如果本文章各位小伙伴们有帮助的话,🍭关注+👍🏻点赞+🗣评论+📦收藏,相应的有空了我也会回访,互助!!!
🤝另本人水平有限,旨在创作简单易懂的文章,在文章描述时如有错,恳请各位大佬指正,在此感谢!!!
配置Kali的eth0为静态ip
- ⚠️ 在配置前Vmware提前为该虚拟机设置了桥接模式
- 配置步骤:
-
配置eth0的网卡配置(/etc/network/interfaces)
#This is ethes properties auto eth0 allow-hotplug eth0 iface eth0 inet static address 192.168.0.99 netmask 255.255.255.0 gateway 192.168.0.1
-
配置DNS解析(/etc/resolv.conf)
nameserver 192.168.0.1 nameserver 114.114.114.114
-
systemctl restart networking 重启网卡加载配置
-
配置kali的apt源
- 配置步骤
-
先将原来的apt源文件备份(/etc/apt/sources.list)
cp sources.list sources.list.copy
-
将准备好的源替换原本的源
deb <http://mirrors.aliyun.com/ubuntu/> bionic main restricted universe multiverse deb <http://mirrors.aliyun.com/ubuntu/> bionic-security main restricted universe multiverse deb <http://mirrors.aliyun.com/ubuntu/> bionic-updates main restricted universe multiverse deb <http://mirrors.aliyun.com/ubuntu/> bionic-proposed main restricted universe multiverse deb <http://mirrors.aliyun.com/ubuntu/> bionic-backports main restricted universe multiverse deb-src <http://mirrors.aliyun.com/ubuntu/> bionic main restricted universe multiverse deb-src <http://mirrors.aliyun.com/ubuntu/> bionic-security main restricted universe multiverse deb-src <http://mirrors.aliyun.com/ubuntu/> bionic-updates main restricted universe multiverse deb-src <http://mirrors.aliyun.com/ubuntu/> bionic-proposed main restricted universe multiverse deb-src <http://mirrors.aliyun.com/ubuntu/> bionic-backports main restricted universe multiverse
# > 表示两个文件间的替换 >> 表示将一个文件的内容追加到另一个文件中 cat list.txt > /etc/apt/sources.list
-
替换源之后使用
apt-get update
更新源可能会出现“由于没有公钥,无法验证下列签名 ***”问题,解决如下:方法比较简单就是下载公钥,导入下载的key即可:
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 6AF0E1940624A220 #此处6AF0E1940624A220需要是错误提示的key
-
更多推荐
已为社区贡献3条内容
所有评论(0)