LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Closed Thread
 
Search this Thread
Old 07-07-2006, 07:17 AM   #1
Lenux78
Member
 
Registered: Jun 2006
Location: Venezuela
Distribution: A Lot
Posts: 40

Rep: Reputation: 15
Smile Detecting new Disk with Red Hat without reboot...


Hi...

I have a little question... I have RedHat Advance Server 3 Update 3 with kernel 2.4.21-40.ELsmp installed on a HP Lxr8500 Server...

This server is connected to a Disk Array VA 7400 through FiberChannel and with this disk Array a can create LUNs dinamically. When I reboot the server the Operating System shows me the device file of this disk: For example: /dev/sda, /dev/sdb, .....

how can i detect those disks without rebooting the server????

Is there an utility that detect and make the device files on the fly??

Please Help me...
 
Old 07-07-2006, 11:09 AM   #2
Lenux78
Member
 
Registered: Jun 2006
Location: Venezuela
Distribution: A Lot
Posts: 40

Original Poster
Rep: Reputation: 15
Hello everyone!!!.. I just discovered and I'm going to share with you to your knowledge....

My fiberchannel target is on the scsi2... so the first thing i did was see /proc/scsi/scsi this is the output...

Attached devices:
Host: scsi2 Channel: 00 Id: 00 Lun: 00
Vendor: HP Model: A6189A Rev: HP19
Type: Direct-Access ANSI SCSI revision: 03

Host: scsi4 Channel: 00 Id: 00 Lun: 00
Vendor: MegaRAID Model: LD0 RAID1 34731R Rev: H
Type: Direct-Access ANSI SCSI revision: 02


- As you see I have one Lun created and is 10GB of size.. So I create a new Luns of 2GB in the VirtualArray...

- After create the Lun.. I run this command:

echo "scsi remove-single-device 2 0 0 1" > /proc/scsi/scsi

This instruction tells the Operationg System to add an SCSI dinamically but instead of adding an Scsi drive i add a LUN... only what i need is Controller (2), Host ID (0), SCSI ID (0) and LUN ID (1)..

The Lun ID is 1 because is the new Lun that I'm going to add...

- I run dmesg to see the results. This is the output:

scsi singledevice 2 0 0 1
blk: queue f4220818, I/O limit 4294967295Mb (mask 0xffffffffffffffff)
Vendor: HP Model: A6189A Rev: HP19
Type: Direct-Access ANSI SCSI revision: 03
blk: queue f47dd018, I/O limit 4294967295Mb (mask 0xffffffffffffffff)
Attached scsi disk sdd at scsi2, channel 0, id 0, lun 1
SCSI device sdd: 4194304 512-byte hdwr sectors (2147 MB)
sdd: unknown partition table

As you see the new device file is /dev/sdd, As you observe is a 2GB disk.. and run cat/proc/scsi/scsi and see it

Attached devices:
Host: scsi2 Channel: 00 Id: 00 Lun: 00
Vendor: HP Model: A6189A Rev: HP19
Type: Direct-Access ANSI SCSI revision: 03
Host: scsi2 Channel: 00 Id: 00 Lun: 01
Vendor: HP Model: A6189A Rev: HP19
Type: Direct-Access ANSI SCSI revision: 03
Host: scsi4 Channel: 00 Id: 00 Lun: 00
Vendor: MegaRAID Model: LD0 RAID1 34731R Rev: H
Type: Direct-Access ANSI SCSI revision: 02


- And to finish you can do anything with that disk... and create Many disks without rebooting..

Greetings...

Lenux78
__________________
 
Old 07-08-2006, 05:44 PM   #3
XavierP
Moderator
 
Registered: Nov 2002
Location: Kent, England
Distribution: Lubuntu
Posts: 19,176
Blog Entries: 4

Rep: Reputation: 430Reputation: 430Reputation: 430Reputation: 430Reputation: 430
Thanks for posting the answer. I am closing this as it's the same as http://www.linuxquestions.org/questi...d.php?t=461814 which is more appropriately placed.
 
  


Closed Thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Red Hat 9 disk 2 HELP! 777JR Red Hat 12 01-04-2004 09:47 PM
Wanted: Halt/Reboot buttons in XDM. Red Hat 5 tmillard Linux - Software 3 11-30-2003 08:38 PM
Red Hat 9 Install hangs after detecting drives ecook280 Linux - Software 4 10-29-2003 07:11 PM
Red Hat Kernel does not update on reboot. Buckinator Linux - Software 4 08-23-2003 08:50 PM
red hat 8.0 disk 3 chrismiceli Linux - General 1 10-02-2002 05:15 PM


All times are GMT -5. The time now is 03:03 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration