- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Performing a linux rescan of newly added LUNS
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-19-2007 01:27 AM
тАО10-19-2007 01:27 AM
Performing a linux rescan of newly added LUNS
I have read a number of posts on the qlogic website and internet in general about getting newly added luns recognised without a reboot. I have tried running the hp_fibreutils hp_rescan / xpinfo / and found a decent post advising the following
Question
Can devices be rescanned in Linux OS without reloading the Linux driver?
A new LUN was added to the storage, but the LUN cannot be seen by the driver or the OS. Rebooting or reloading the driver would be too disruptive.
Answer
There is a procedure which forces the driver to rescan the targets to allow a new device to be added. This triggers the driver to initiate a LUN discovery process.
To force a rescan from the command line, type the following command:
# echo "scsi-qlascan" > /proc/scsi/
Where:
-
-
After executing this command, force the SCSI mid layer to do its own scan and build the device table entry for the new device by typing the following command:
# echo "scsi add-single-device 0 1 2 3" >/proc/scsi/scsi
Where:
- "0 1 2 3" = your "Host Channel ID LUN"
The scanning must be done in the above mentioned order: first the driver (qla2300/qla2200 driver, etc.), and then the Linux SCSI mid layer (i.e. OS scan).
Operating System
Linux Red Hat
Linux SUSE
I can try this but dont know how to find the HOST / Channel / ID / LUN
of the new luns.
The storage guys have added 4 new luns and /proc/scsi/scsi shows 77 disks, but /proc/scsi/qla2xxx/0 shows 73 so it seems the scsi layer sees them, but not the qlogic card correctly.
Im using the 2.6.9-11 kernel on redhat.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-19-2007 01:51 AM
тАО10-19-2007 01:51 AM
Re: Performing a linux rescan of newly added LUNS
Normally, hp_rescan should do the job.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-20-2007 11:37 PM
тАО10-20-2007 11:37 PM
Re: Performing a linux rescan of newly added LUNS
You may well be able to pick up the relevant information in the output of "dmesg"
Failing that, the commands "lssd" and "lssg" may be of use...
Hope this helps,
Regards,
Rob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-21-2007 10:51 PM
тАО10-21-2007 10:51 PM
Re: Performing a linux rescan of newly added LUNS
you can trigger a scsi-bus rescan by sending string "- - - " to the file named "scan" placed in /sys/class/scsi_host/hostX/
$ cd /sys/class/scsi_host/hostX/
# where hostX is your qla
# maybe file hostX/proc_name is helpful to # identify the correct one.
then:
$ echo "- - - " > scan
and
$ dmesg | tail
or
cat /proc/scsi/scsi
hope this helps.
rgds
HGH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-23-2007 07:12 AM
тАО10-23-2007 07:12 AM
Re: Performing a linux rescan of newly added LUNS
This script is a command utility, which will help to Perfom the followings
QLogic Linux LUN Scan Utility v2.3
To begin scanning the LUNs issue following command:
# /opt/local/unix/bin/qlun_disc.sh
Usage: /opt/local/unix/bin/qlun_disc.sh [OPTIONS]
-cl, --current-luns
Displays LUNS currently present
-h, --help, ?
Prints this help message
-i, --interactive
Use this option to use the menu driven program
-p, --proc
Use PROC file system for LUN scanning
-r, --refresh
To refresh, that is remove LUNs that are lost
use the options "-r|--refresh". This will
remove the LUNs which no more exist.
-s, --scan [-r|--refresh]
The QLogic LUN scan utility re-scans all the
devices connected to the QLogic HBA
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-24-2007 11:00 PM
тАО10-24-2007 11:00 PM
Re: Performing a linux rescan of newly added LUNS
>> echo "scsi-qlascan" > /proc/scsi/
>> echo "scsi add-single-device 0 1 2 3" >/proc/scsi/scsi
Theoritically above commands are safe. If involves Production Server, do consider carefully, worst scenario - Kernel Panic :)
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-25-2007 02:10 PM
тАО10-25-2007 02:10 PM
Re: Performing a linux rescan of newly added LUNS
>> echo "scsi-qlascan" > /proc/scsi/
>> echo "scsi add-single-device 0 1 2 3" >/proc/scsi/scsi
Try not to issue above command while SAN Backup (NetBackup, Data Protector) is running. There are possibilities that the SAN Backup could be interrupted.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-25-2007 07:25 PM
тАО10-25-2007 07:25 PM
Re: Performing a linux rescan of newly added LUNS
However, via SANsurfer we are using the following settings in /etc/modprobe.conf
options qla2xxx ConfigRequired=1 ql2xmaxqdepth=16 qlport_down_retry=30 ql2xlogi
nretrycount=16 ql2xfailover=1 ql2xlbType=1 ql2xautorestore=0x80
In order to get the Qlogic cards to register the new LUNS in SANsurfer I need to reboot. I am currently asking HP about this because if the LUNS are not visible in SANsurfer, if my primary fibre card failed and all luns used the failover card would the new LUNS be usable ?
Any thoughts ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-30-2007 07:49 AM
тАО10-30-2007 07:49 AM
Re: Performing a linux rescan of newly added LUNS
SAN surfer is a swicth manager s/w(if is understand right) and does not replace the path fail over s/w like power path module
What software do you use for path fail over facility?So what SANsurfer could not see is some thing different(asuume not related)to how the path management s/w responds to a fiber card failure.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-28-2007 05:34 PM
тАО12-28-2007 05:34 PM
Re: Performing a linux rescan of newly added LUNS
I noticed that when removing a scsi LUN from the array without rebooting, after rescan, it is still showing up in /proc/scsi/scsi, it this the correct Linux behavior or something to do with qla2xxx driver or a bug, is the driver supposing to inform scsi mid layer about this removal and scsi mid layer will update its own LUN list or not?
Thanks for the information.