怎么在Linux发行版下列出所有安装了的包

怎么在Linux发行版下列出所有安装了的包

2014年9月15日1 次浏览来源:Linux中国阅读原文

列出所有安装了的包的方法取决于你用什么发行版以及包管理器。

在这个教程里,我们将提供主流发行版的命令。

注意: 你可以用管道筛选或者用重定向符(>)来把结果重定向到一个文件。例子如下。

example | less

example > installed_packages.txt

Red Hat/Fedora Core/CentOS Linux:

rpm -qa

Arch Linux:

pacman -Qq

Ubuntu / Debian / Linux Mint:

dpkg --get-selections

dpkg --list

dpkg -l

祝你一天好心情。

分享
Baike.dev

baike.dev helps you discover great languages, frameworks, databases, DevOps and cloud-native tools.

Quick links

About

Contribute

Found a great developer tool? Share it with the community.

Submit a tool
© 2026 baike.dev Developer EncyclopediaUpdated daily · Discover great developer tools