Disk IO check

You’ll need to get iostat for this.

yum install sysstat should get you what you need.

iostat -x 2 

This will give you a picture of your disk usage every two seconds. Adjust the number at the end to your liking. 

Here’s an example output:



Escaping SSH session

If you find yourself trapped inside a SSH session that is hung, while SSH’d into another machine? I have, often actually. Sometimes I’m connected and reading up on something and when I come back my session has loss its connection while I was ssh’d into another machine. Here’s how you can back out to the other machine:

In the shell type: ~.

that’s a period at the end of the tilde. This will terminate your connection and bring you back to the shell you where SSH’d into prior to that.  




scanning for scsi devices in CentOS 6




Recently I ran into a situation where passing the “- – -” values to iscsi_host/host#/scan didn’t work for me. I was sure that I had run this before on CentOS6, but to no avail I could not find a value in the /host portion.


So, this what I discovered! The friendly folks at Red Hat have created a script for dealing with this.


Do this:


1. yum install sg3_utils
2. run rescan-scsi-bus.sh (they added it to the path 😉 booyah!)


Now you should have your drive all discovered and ready for fdisk!


Here’s the original link for this info: https://access.redhat.com/site/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Storage_Administration_Guide/rescan-scsi-bus.html