最近ubuntu空间告急,急需清理一下。
首先是apt的清理,apt中会留存很多的下载和安装文件,此时就需要:
先查看:
du -sh /var/cache/apt/archives
然后清理:
sudo apt-get clean
清理不需要的内核:
sudo apt-get autoremove --purge
删除不需要的软件:
sudo apt-get remove package-name1 package-name2
sudo apt-get autoremove
清楚conda中的文件:
conda clean -a
Remove index cache, lock files, unused cache packages, and tarballs
conda clean -p
移除未曾使用的安装包文件
conda clean -t
移除缓存下来的压缩文件(不一定局限于tar/bz2/zip,这里很多conda也算压缩文件)