Categories
Learning Linux

check hard disk rpm or rotation speed

Lot of times you want to check the disk rpm, especially on the servers to check if it is 7.2K or 10K or 15K rpm disk. How do you do this from linux terminal. Here it is :

 

sginfo -g /dev/<device>

Note that sginfo comes from sg3-utils.

Categories
Learning

ionice – renice you IO activity for the process.

ionice is utility provided by the package util-linux. Description of util-linux:

Description : The util-linux package contains a large variety of low-level system
: utilities that are necessary for a Linux system to function. Among
: others, Util-linux contains the fdisk configuration tool and the login
: program.

 

With the help of this utility, you can set the scheduler priority for your IO scheduling upto RealTime, but be careful that can make other process sluggish. Example use:

ionice -c 1 -n 7 $(pgrep
Categories
bash Fedora

List all the rpms by size – quick way to find out what is eating your disk space in root partition

Here is a quick command to check the list of installed packages by their size in reverse order. Very useful if you want to remove unwanted rpms just to clean up some space on your disk:

1
rpm -q -a --qf "%10{SIZE}\t%{NAME}\n" | sort -k1,1nr |more

Sample output:

78070452    kernel
78060477    kernel
50708634    jre
50316408    libgcj
48581593    wireshark
47778643    gimp
47674675    jre
47303084    qt-x11
45838912    otrs
45657248    chromium-libs
42070128    wxPython