1.1 #搜索已经安装的安装包,查找某个文件属于哪个包
dpkg -S `which bash`
1.2 #查看已安装包的详细信息
dpkg -s bash
2.1#查找未安装的安装包
apt-cache search dpkg
apt search mailx|grep -i mailx
apt search all |grep mailx
2.2 #查询安装包
apt install aptitude
aptitude search openjdk
2.3 #查询速度较慢
apt-file search mailx
apt-file find mailx