lspci

General support questions including new installations
zuzu
Posts: 29
Joined: 2011/12/22 11:03:59
Location: Sydney

Re: lspci

Post by zuzu » 2012/01/11 01:48:44

[quote]
TrevorH wrote:
[quote]
$ rpm -qf `which lspci`
pciutils-3.1.7-3.el5.x86_64

Sorry when I tried that one it came back with something along the lines of "which lspci not found"
[/quote]

Yes, well it was meant to show you which package supplied lspci utility that was already installed on my system so that you could `yum install ...` it. Now that you have, my command will work on your system too![/quote]

It has still come back with

"error: file /home/user/which lspci: no such file or directory"

r_hartman
Posts: 711
Joined: 2009/03/23 15:08:11
Location: Netherlands
Contact:

Re: lspci

Post by r_hartman » 2012/01/11 06:03:01

[quote]That command got the system to go off and load a whole bunch of stuff :S

I am confused as to what I actually did there. From what I figure it installed a whole bunch of stuff :S[/quote]
If you are referring to the yum command I gave you, that command did not install anything but showed you which package to install in order to get the 'lspci' command, similarly to what [b]TrevorH[/b] wrote. My command however would show you what to install from a system that has [i]not[/i] already got the package. Both methods were just meant to show you what you needed to install, and do a bit of education.

Then, a 'yum install pciutils' would actually install the package. Similar for 'yum install usbutils'.

[quote]It has still come back with

"error: file /home/user/which lspci: no such file or directory"[/quote]
You used single quotes ( ' ) instead of backticks ( ` ).
Using backticks or the alternative syntax
[code]$ rpm -qf $(which lspci)[/code]will work.

User avatar
AlanBartlett
Forum Moderator
Posts: 9345
Joined: 2007/10/22 11:30:09
Location: ~/Earth/UK/England/Suffolk
Contact:

Re: lspci

Post by AlanBartlett » 2012/01/11 09:59:59

Ahem! The path ([b]/sbin[/b]) and EL 5 . . .

natsuto
Posts: 2
Joined: 2012/01/31 08:31:10
Contact:

Re: lspci

Post by natsuto » 2012/02/02 01:51:48

Tell you what is yet to be installed a system package. These two methods just tell you that you need to install and do a bit of education.

zuzu88
Posts: 4
Joined: 2015/04/28 18:03:14

Re: lspci

Post by zuzu88 » 2015/06/03 06:15:41

try this
[root@localhost ~]# yum provides */lspci
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: centos.mirror.ndchost.com
* extras: mirror.thelinuxfix.com
* updates: mirror.rackspace.com
pciutils-3.2.1-4.el7.x86_64 : PCI bus related utilities
Repo : base
Matched from:
Filename : /usr/sbin/lspci
2)[root@localhost ~]# rpm -q pciutils
package pciutils is not installed
[root@localhost ~]# yum -y install pciutils
after it installed your lspci command should work

scottro
Forum Moderator
Posts: 2556
Joined: 2007/09/03 21:18:09
Location: NYC
Contact:

Re: lspci

Post by scottro » 2015/06/03 10:03:48

While most of us have done this, it may be worth pointing out that you're replying to a post that's about 3 years old. The yum provides option is a good one, of course, I've posted that solution often enough to have wound up making a little page on it.

http://srobb.net/yumprovides.html
New users should check the FAQ and Read Me First pages

Locked