kali问题集(一)apt配源引发的一系列问题

本文记录了在Kali Linux中遇到的apt安装ncat时的问题,包括apt源配置错误、无法解析地址的错误以及网络连接问题。通过添加阿里云镜像源、检查网络连接和排查VMware虚拟网卡设置,最终解决了问题。同时,安装ncat时切换到中科大源顺利完成。

1、使用apt-get install ncat(安装新版nc)时报错了,提示如下:

Reading package lists… Done
Building dependency tree
Reading state information… Done
Package ncat is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package ‘ncat’ has no installation candidate

在这里插入图片描述
网上查解决办法,有ubuntu的网友给出了:
apt-get update
apt-get upgrade
然后再安装的解决方法,经试验,还是不行

后来请教QQ群大神,大神让用这个命令
grep -v ^# /etc/apt/sources.list
运行后无结果,判定为apt源为空需要配置源网站,所以要把以下内容添加至对应的文件内
文件名:/etc/apt/sources.list
添加内容:
deb https://mirrors.aliyun.com/kali kali-rolling main non-free contrib
deb-src https://mirrors.aliyun.com/kali kali-rolling main non-free contrib

2、添加完毕后运行adp update报错,无法解析地址
root@kali:/# apt update
Err:1 http://mirrors.aliy

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值