How to Install Hwinfo on Fedora 19/20 and CentOS 5/6

By | May 25, 2023

Hwinfo - Hardware Information Tool

Hwinfo is a command line utility to probe and gather information about hardware components on a system in a easy to read format.

It was initially a OpenSuse specific tool that was later compiled for other systems like Debian, Fedora, Arch etc.

Hwinfo is not available in the Fedora repositories, and neither is it present in any of the popular 3rd party repositories like repoforge or rpmfusion.

Install Hwinfo on Fedora

Here we are going to install hwinfo on Fedora 20. The hwinfo rpm packages for Fedora are available on the opensuse site at the following hidden place

http://download.opensuse.org/repositories/home:/zhonghuaren/

Setup Repository

The repository file can be found here
http://download.opensuse.org/repositories/home:/zhonghuaren/Fedora_20/home:zhonghuaren.repo

The above repository needs to be added to Fedora in a repo file at the following location

/etc/yum.repos.d/rpm-sphere.repo

Use the wget command to download the repo file directly to the yum directory.

$ sudo wget http://download.opensuse.org/repositories/home:/zhonghuaren/Fedora_20/home:zhonghuaren.repo -O /etc/yum.repos.d/rpm-sphere.repo

Or manually create and fill /etc/yum.repos.d/rpm-sphere.repo with the following

[home_zhonghuaren]
name=RPM Sphere (Fedora_20)
type=rpm-md
baseurl=http://download.opensuse.org/repositories/home:/zhonghuaren/Fedora_20/
gpgcheck=1
gpgkey=http://download.opensuse.org/repositories/home:/zhonghuaren/Fedora_20/repodata/repomd.xml.key
enabled=1

Hwinfo rpms are also available in another repository found here
http://download.opensuse.org/repositories/home:/darkhado/

Update yum cache and install hwinfo

After adding the repository information, all that is left is to update the yum cache and install the package hwinfo.

$ yum list hwinfo
$ yum install hwinfo

Run hwinfo

After the installation completes, run and test the hwinfo command

$ hwinfo --short --cpu --usb
cpu:                                                            
                       Intel(R) Core(TM)2 Quad CPU    Q8400  @ 2.66GHz, 2638 MHz
                       Intel(R) Core(TM)2 Quad CPU    Q8400  @ 2.66GHz, 2638 MHz
mouse:
  /dev/input/mice      VirtualBox USB Tablet
hub:
                       Linux 3.12.8-300.fc20.x86_64 ohci_hcd OHCI PCI host controller

Install hwinfo on CentOS 5/6 or EL 5/6

CentOS or EL users need to install hwinfo from the GhettoForge repositories.

Instructions can be found here
http://ghettoforge.org/wiki/Packages

Setup Ghettoforge repos on centos 5/6

# CentOS 6
# rpm -Uvh http://mirror.symnds.com/distributions/gf/el/6/gf/x86_64/gf-release-6-6.gf.el6.noarch.rpm

# Centos 5
# rpm -Uvh http://mirror.symnds.com/distributions/gf/el/5/gf/x86_64/gf-release-5-6.gf.el5.noarch.rpm

Now install hwinfo

$ yum list hwinfo
$ yum install hwinfo

Run hwinfo

After the installation completes, run and test the hwinfo command

# hwinfo --short --cpu --netcard
cpu:                                                            
                       Intel(R) Core(TM)2 Quad CPU    Q8400  @ 2.66GHz, 2641 MHz
network:
  eth0                 Intel PRO/1000 MT Desktop Adapter

The output looks neat. Enjoy!!

Update

The repository mentioned for Fedora above is not available anymore. Try the follow repository:

https://copr.fedorainfracloud.org/coprs/baoboa/hwinfo/
About Silver Moon

A Tech Enthusiast, Blogger, Linux Fan and a Software Developer. Writes about Computer hardware, Linux and Open Source software and coding in Python, Php and Javascript. He can be reached at [email protected].

3 Comments

How to Install Hwinfo on Fedora 19/20 and CentOS 5/6

Leave a Reply

Your email address will not be published. Required fields are marked *