1、修改sources.list源文件:
vim /etc/apt/sources.list
#aliyun 阿里云
deb http://mirrors.aliyun.com/kali kali-rolling main non-free contrib
deb-src http://mirrors.aliyun.com/kali kali-rolling main non-free contrib
#中科大源
deb http://mirrors.ustc.edu.cn/kali kali-rolling main non-free contrib
deb-src http://mirrors.ustc.edu.cn/kali kali-rolling main non-free contrib
#官方源
deb http://http.kali.org/kali kali-rolling main non-free contrib
deb-src http://http.kali.org/kali kali-rolling main non-free contrib
2、常用更新命令:
apt update # 检测可更新的软件
apt upgrade # 自动更新并安装软件
apt dist-upgrade # 检测并进行系统升级
3、清理安装包:
apt-get clean #删除所有已下载的包文件
apt-get autoclean #删除已下载的旧包文件
apt-get autoremove #卸载所有自动安装且不再使用的软件包