Checking performance with iostat and lsof

Having already discovered how vmstat can be used to provide statistics related to memory management, when troubleshooting performance-related issues an overburdened CPU is yet another area of concern. For this purpose, we can use the iostat command like this:

# iostat

However, to display a more interactive CPU utilization report, you can use the –c option (and provide a numeric value measured in seconds, such as 5 seconds) like this:

# iostat –c 5

Most of the columns should be self-explanatory, but if the system is getting busy, you will see an increase in %iowait, which is used to report on an increase in waiting time for any I/O requests to be completed. Based on this, if the server is transferring or ...

Get Troubleshooting CentOS now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.