Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Feb 1999 00:24:10 -0700 (MST)
From:      "Kenneth D. Merry" <ken@plutotech.com>
To:        khang@hero.clerk.leon.fl.us (Khang Trang)
Cc:        freebsd-scsi@FreeBSD.ORG, freebsd-questions@FreeBSD.ORG
Subject:   Re: trouble with a seagate ST39140N 1206
Message-ID:  <199902170724.AAA67341@panzer.plutotech.com>
In-Reply-To: <Pine.BSF.4.05.9902170139220.2120-100000@hero.clerk.leon.fl.us> from Khang Trang at "Feb 17, 1999  1:59:52 am"

next in thread | previous in thread | raw e-mail | index | archive | help
Khang Trang wrote...
> 
> help!
> 
> i'm having some problems with an adaptec 2940 and two seagate ST39140N
> 1206 drives running on a ppro200 with fbsd 3.0-release.
> 
> history:
> the machine was formerly a redhat 5.1 linux machine and the two seagate
> drives were formatted ext2fs. switched to fbsd 3.0 ... formatted the 8 gig
> ibm ide drive and installed fbsd 3.0.  fbsd loads up and runs great.  
> 
> everything worked great.  i was able to mount_ext2fs the two scsi seagate
> drives, but then the system got rebooted a few times (without my
> knowledge) and the seagate drives got corrupt (superblock was missing).
> tried fsck -b with an alternate superblock to no avail.  i figured might
> as well format and setup the hds as fbsd drives so i do:
> 
> camcontrol cmd -v -n da -u 0 -c "4 0 0 0 0 0" 
> 
> following the examples from a post to the fbsd mail archives.

Well, there's just one problem with that...

> when i ran camcontrol it gave some sort of error saying could not send
> command or soemthing to that extent.  no biggie i figured.

What probably happened is that the command timed out.  Low-level formatting
generally takes a long time to complete.  (up to a couple of hours)

Here's how to specify a timeout in seconds:

camcontrol cmd -v -t 10800 -n da -u 0 -c "4 0 0 0 0 0"

That sets the timeout to 3 hours.

It's generally *not* a good idea to low-level format a drive as your first
resort.  The things you're trying below are much better.  It's much better
to just to disklabel the disk, newfs it, etc.

> look through
> the fbsd handbook and found:
> 
> dd if=/dev/zero of=/dev/foo bs=1K count=1
> disklabel etc etc etc
> 
> tried that but got this error message:
> 
> dd: /dev/rda0: Input/output error
> 
> checking dmesg there are these errors:
> 
> (da0:ahc0:0:0:0): READ(06). CDB: 8 0 0 0 1 0 
> (da0:ahc0:0:0:0): MEDIUM ERROR asc:31,0
> (da0:ahc0:0:0:0): Medium format corrupted
> da0: error reading primary partition table reading fsbn 0
> 
> now i can't fdisk, fsck, disklabel, or anything on that drive.

What has most likely happened is that since the format was stopped when it
was only partially completed, the disk has more or less lost its brain.

> camcontrol devlist shows the following:
> <SEAGATE ST39140N 1206>            at scbus0 target 0 lun 0 (pass0,da0)
> <YAMAHA CDR100 1.11>               at scbus0 target 1 lun 0 (pass1,cd0)
> <TOSHIBA CD-ROM XM-5701TA 0167>    at scbus0 target 3 lun 0 (pass2,cd1)
> <SEAGATE ST39140N 1206>            at scbus0 target 4 lun 0 (pass3,da1)
> 
> HELP!
> i'm not worried about losing the data (ha! that's probably already done)
> but from what i've managed to find out from teh mail archives i'm under
> the impression that i'm screwed.  i haven't tried looking at the firmware
> in the scsi controller (suggested to me) or a low level format (can
> someone tell me how in fbsd 3.0?).  any help would be appreciated.  as
> long as teh drives aren't now paperweigths i'm happy.
> 
> would it help if i took the drives out, put them in a dos machine and
> format them, then put them back in and mount_msdos them? i'm considering
> this route if it works.
> 
>  if you need more info please email me back.  (btw the machine is up
> and running with fbsd 3.0 just don't have the two drives mounted which i
> really really would like to do.  so PLEASE DON'T TELL ME THE DRIVES ARE
> PAPERWEIGHTS AND I SHOULD BUY NEW ONES :(.)

I don't think they're paperweights at all.  The "Medium format corrupted"
errors can generally be fixed by low-level formatting the disk.  This is
one of the few instances where low-level formatting is actually the right
thing to do.  As I mentioned above, here's how to low-level format da0:

camcontrol cmd -v -t 10800 -n da -u 0 -c "4 0 0 0 0 0"

I think 3 hours should be enough, but I haven't low-level formatted a drive
in a couple of years.  If you don't think 3 hours will be enough, you can
increase the timeout.  (If you get a timeout type error, you'll know to
increase the timeout.)

Good luck,

Ken
-- 
Kenneth Merry
ken@plutotech.com


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199902170724.AAA67341>