Using cat, less, and more
The
cat
command has been with us for a long time and, returning to our previous discussion relating to hardware and the contents of the /proc
directory, you can use the cat
command to view detailed information about your server's CPU:
# cat /proc/cpuinfo
If you wish to know more about the server's memory, you can use:
# cat /proc/meminfo
Then, there is always the chance to learn more about your devices by typing:
# cat /proc/devices
As useful as cat
is, it is also known for providing a dump of the entire content on the screen, a condition that can seem a little unwieldy if the file is greater than 1,000 lines long. So, in these circumstances, the other option is to use the less
and more
commands in order to page through ...
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.