HowTo: RPM List Files

本文介绍如何使用rpm命令来列出rpm包内的文件列表。包括未安装的rpm包文件查看方式及已安装软件包文件的查看方法。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

HowTo: RPM List Files


How do I list file stored inside a rpm file?


rpm command example
You need to use the rpm command as follows:

The syntax is as follows for .rpm file:
# rpm -qpl file.rpm
In this example, list rpm files stored inside httpd-2.2.3-31.el5_4.2.x86_64.rpm, enter:
# rpm -qlp httpd-2.2.3-31.el5_4.2.x86_64.rpm
Sample outputs:

/etc/httpd
/etc/httpd/conf
/etc/httpd/conf.d
/etc/httpd/conf.d/README
/etc/httpd/conf.d/proxy_ajp.conf
/etc/httpd/conf.d/welcome.conf
/etc/httpd/conf/httpd.conf
/etc/httpd/conf/magic
/etc/httpd/logs
/etc/httpd/modules
/etc/httpd/run
/etc/logrotate.d/httpd
....
..
..
/var/www/icons/uu.png
/var/www/icons/uuencoded.gif
/var/www/icons/uuencoded.png
/var/www/icons/world1.gif
/var/www/icons/world1.png
/var/www/icons/world2.gif
/var/www/icons/world2.png

How Do I List Files For Installed Package?

You need to use rpm command as follows:
# rpm -ql packageName
# rpm -ql samba
# rpm -ql httpd
http://www.cyberciti.biz/faq/howto-rpm-list-files/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值