Adding new HDD(hard disk) in Linux, detect it without rebooting - Experimented using Vmware

This is explained below :-

Im having Vmware 9 with CentOS 6.4 Up-Running. Im adding the hard disk :-
 

  1. Next>
    Create a new virtual disk
    SCSI
    maximum disk size (GB): 1GB // you can select as per your requirement
  2. Additional HDD added:-
  3.  
  4. select >>OK
  5.  Open clone session on SSH : select tail -f /var/log/messages
  6.  
  7. Keep scanning the host . And, get detected in fdisk as well in /dev/* directory: 
  8. echo "- - -" > /sys/class/scsi_host/host0/scan
  9. echo "- - -" > /sys/class/scsi_host/host1/scan
  10. echo "- - -" > /sys/class/scsi_host/host2/scan
  11. As in my case i had host0,host1,host2

     When the HDD is detected, in host2:-

    Remove the Added partition, using the following command:-
    i.e.,
    # echo 1 > /sys/block/devName/device/delete

    Example,in our case is "/dev/sdb
    # echo 1 > /sys/block/sdb/device/delete




    Comments

    Popular posts from this blog

    Xmanager RHEL 6 xclock :command not found -- Resolved

    Racktable on ubuntu installation

    RPM Tit-Bits ;-)