Operating System - Linux
1847087 Members
5167 Online
110262 Solutions
New Discussion

DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

 
Dave Armbruster
Occasional Advisor

DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Good Day - I have a DL380/G2 with a hot plug 72Gb dat. The system posts and shows the tape drive as SCSI LU 04 on my 5i array controller. When Fedora boots it was not recognizing the tape so I found a scipt to engage the scsi. The system now sees the /dev/st0 device but it does not work correctly. It seems to find the drive as device LU 00 and any attempt to write to the drive fails. After the fail the system replies that there is no such device or address. Is there a way to get Fedora to see this drive correctly. Thanks!
16 REPLIES 16
Steven E. Protter
Exalted Contributor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Standard checklist:

Check the scsi id of the dat drive and make sure it does not conflict with any other. Seems you have done that, but check again.

Make sure the cables are good.

See if you can get the drive its own scsi controller. These drives don't meet their theoretical speeds when daisy chained with disk.

Fedora may not have this drive built into the kernel. That means you will need to get a Linux FC3 driver for it from the manufacturer. It thats HP, they take their time and test before releasing drivers. Thats good Q & A even if it inconveniences you.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Dave Armbruster
Occasional Advisor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

I probably should have added this was a functional tape drive when it was running Windows 2003 Server. It is in a hotplug slot so I don't think I can change controllers. Fedora sees the drive if you look in /proc/scsi/scsi, it just doesn't seem to talk the write lingo....
xyko_1
Esteemed Contributor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Dave,

did you have done some tests with mt utility ?

regards,
Xyko
Dave Armbruster
Occasional Advisor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Xyko - Yes, take a peek. It sees the drive and seems to return a status. I told it to erase and it kind of flips out and is no longer available. Any thoughts? Thanks!

[root@cserv /]# cat /proc/scsi/scsi
Attached devices:
Host: scsi0 Channel: 00 Id: 00 Lun: 00
Vendor: HP Model: C7438A Rev: V312
Type: Sequential-Access ANSI SCSI revision: 03
[root@cserv /]# ls -al /dev/st0
crw-rw---- 1 root disk 9, 0 Feb 1 11:41 /dev/st0
[root@cserv /]# mt -f /dev/st0 status
SCSI 2 tape drive:
File number=-1, block number=-1, partition=0.
Tape block size 0 bytes. Density code 0x47 (TR-5).
Soft error count since last status=0
General status bits on (1010000):
ONLINE IM_REP_EN
[root@cserv /]# mt -f /dev/st0 erase
/dev/st0: Input/output error
[root@cserv /]# mt -f /dev/st0 status
/dev/st0: No such device or address
[root@cserv /]#
xyko_1
Esteemed Contributor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Very strange Dave, I have never seen it before.

Any messages on /var/log/message or dmesg after mt erase ?

If you run engage script again the device becames available ?

regards,
Xyko
Dave Armbruster
Occasional Advisor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Good Point - Looking at the messages shows:

Feb 1 14:30:04 cserv kernel: cciss: cp 39c85280 timedout
Feb 1 14:30:07 cserv kernel: scsi: Device offlined - not ready after error reco
very: host 0 channel 0 id 0 lun 0
Feb 1 14:30:07 cserv kernel: scsi0 (0:0): rejecting I/O to offline device

It does not seem to allow the mt command to staus it even if I reengage the scsi. I'm almost positive the tape drive is on lun 04,
but Fedora never seems to pick that up. Is there a way to force it at the address? Thanks!
xyko_1
Esteemed Contributor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Dave,

I guess we are one step ahead now.

What is the script you are using to engage scsi ?
Are you using rescan_scsi_bus from
http://www.garloff.de/kurt/linux/rescan-scsi-bus.sh ??

You may force address using
scsi add-single-device host channel id lun

in your case as you say that the tape is lun 4 then
#scsi add-single-device 0 0 0 4

But if you are not using the rescan script, please try it first. Attention because there are many advices concerning the command scsi add and if you inform wrong parameters your server may hang or something worst.

regards,
Xyko

Dave Armbruster
Occasional Advisor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Xyko,
This was another one I found in a forum that is placed into the rc.local file for boot. It seems to do the trick.

##########################################
for x in /proc/driver/cciss/cciss[0-9]*
do
echo "engage scsi" > $x
done
##########################################

I tried the script you mentioned too. It produces the following:
########################################
[root@cserv brewster]# ./rescan-scsi-bus.sh
Host adapter 0 (cciss) found.
Scanning hosts 0 channels 0 for
SCSI target IDs 0 1 2 3 4 5 6 7 , LUNs 0
Scanning for device 0 0 0 0 ...
OLD: Host: scsi0 Channel: 00 Id: 00 Lun: 00
Vendor: HP Model: C7438A Rev: V312
Type: Sequential-Access ANSI SCSI revision: 03
0 new device(s) found.
0 device(s) removed.
########################################
The "scsi add-single-device 0 0 0 4" command runs but does not seem to have any effect. If you cat the /proc/scsi/scsi it still shows the 0 0 0 0. For some reason it does not seem to correctly ID the drive.....Maybe time for a different drive......Dave
xyko_1
Esteemed Contributor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Dave,

The command scsi add-single-device 0 0 0 4 doesn't work because your tape drive is allocated at lun 0, not lun 4 as you told in your first message ( The system posts and shows the tape drive as SCSI LU 04 on my 5i array controller ).

Have you tryied to use (mt) the tape after running the rescan script ? Does it work ? If not, did you see any new message at /var/log/message ?

Regards,
Xyko
Dave Armbruster
Occasional Advisor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Xyko,
I went ahead and removed the script in the rc.local startup file. I then rebooted and ran the script you pointed me to on the web site. Take a look. It claims there are no drives available!

[root@cserv brewster]# ./rescan-scsi-bus.sh
No SCSI host adapters found in sysfs

Even with a couple different options nothing shows. Is this a driver issue where it just doesn't see it correctly? Thanks for the help!!!

Dave
xyko_1
Esteemed Contributor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Dave,

Fedora Core 3 runs kernel 2.6 ?

When you run kernel 2.6 you must have sysfs (the "brother" of /proc in kernel 2.4) mounted, then the script will look for a directory called /sys/class/scsi_host/. If it doesn't find it the script aborts with the message that you received. That's the code :
-------------------------------------
findhosts_26 ()
{
hosts=
if test ! -e /sys/class/scsi_host/host*; then
echo "No SCSI host adapters found in sysfs"
exit 1;
#hosts=" 0"
#return
fi
for hostdir in /sys/class/scsi_host/host*; do
hostno=${hostdir#/sys/class/scsi_host/host}
hostname=`cat $hostdir/proc_name`
hosts="$hosts $hostno"
echo "Host adapter $hostno ($hostname) found."
done
}
-------------------------------------
So you must look if there is any problem with Fedora regarding the needs of that script.

It may be a problem that impacts the script itself and, who knows, the fully operation of your tape.

Let's continue our investigation.

If possible, attach a file with the output of dmesg and boot.log.

regards,
Xyko
Dave Armbruster
Occasional Advisor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Xyko,
Here are the files. I couldn't see anything weird in them other than smartd fails at boot, but I took that to be from the blank config file it had. See what you think....Thanks!....Dave
xyko_1
Esteemed Contributor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Hi Dave,

I found some forum threads that may help solve the problem. Have you ever seen those threads also ?

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=211833
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=657513

Attention for kernel configuration and hotplug packages.

But, the most important thing is that HP only refers linux distros with kernel 2.4 when talking about hotplug dat72 support and compatibility. I'm afraid that you will have problems to get this working well.

Unfortunately I guess I cannot help you anymore because it's beyond my knowledge. Sorry.

One more thing that you can try is to open a thread on a storage forum ( http://forums1.itrc.hp.com/service/forums/categoryhome.do?categoryId=198 . This is a more specific point of support.

I wish you solve your problem and, if possible, report your news to us.

Good Luck for you.

Xyko
Dave Armbruster
Occasional Advisor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Thanks Xyko! I saw these links. The second is where I got the little engage scsi script. I think at this point I will try a post on the Fedora site and see if anyone has the 2.6 driver for compaq or some kind of work around. Thanks for all your help and patience. Put yourself in for a cold beverage......Dave
xyko_1
Esteemed Contributor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

Dave,

Best wishes for you.

Here we are 2 days from Carnaval and I live in Rio de Janeiro so.......

I'll be out for four days taking some rest.

Regards,
Xyko
Umberto Nicoletti
Occasional Advisor

Re: DL380/G2 Hot plug 72G DAT drive not working on Fedora C3

About the device being offlined on i/o error (for instance when writing beyond tape capacity):

I have two proliant dl380 servers with SLES9 with one storage works dat40 each. The tape drive is detected with engage scsi command and works, but is offlined whenever the backup command tries to write a file that is larger than the tape capacity.

Also the scsi subsystem complain about scsi error handling missing (excerpt from dmesg):

ERROR: SCSI host `cciss' has no error handling
ERROR: This is not a safe way to run your SCSI host
ERROR: The error handling must be added to this driver
Call Trace:
[] scsi_host_alloc+0x2b1/0x2d0 [scsi_mod]
[] cciss_proc_write+0x1f3/0x2c0 [cciss]
[] do_page_fault+0x183/0x59a
[] __do_mmap_pgoff+0xf2/0x1a0
[] proc_file_write+0x2f/0x40
[] vfs_write+0xc6/0x160
[] do_mmap2+0xdd/0x170
[] sys_write+0x91/0xf0
[] sysenter_past_esp+0x52/0x71

scsi0 : cciss
Vendor: HP Model: C5683A Rev: P306
Type: Sequential-Access ANSI SCSI revision: 03
st: Version 20040318, fixed bufsize 32768, s/g segs 256
Attached scsi generic sg0 at scsi0, channel 0, id 0, lun 0, type 1
Attached scsi tape st0 at scsi0, channel 0, id 0, lun 0
st0: try direct i/o: yes (alignment 512 B), max page reachable by HBA
4294967295

Solution (?)
------------

I have found the following on good ol' google:

http://groups.google.com/group/fa.linux.kernel/browse_frm/thread/50734896bf39ced/d94e675c2443b855?lnk=st&q=&rnum=7&hl=it#d94e675c2443b855

and contacted Cameron who was kind enough to immediately report that the patch which *should* solve our problems will probably be in
release 2.6.10-13 of hp cciss driver (no guarantees, just a guess [we are now at 2.6.10.11]).
In the meanwhile we must upgrade the kernel to 2.6.15 to (probably) solve the issue.

Strangely enough the drive has error handling on RHEL3 without the hp cciss driver and works just fine.