Re: THE FOLLOWING DISK SECTORS COULD NOT BE READ

2008-08-21 Thread Derek Ragona

At 08:24 AM 8/21/2008, Marcel Grandemange wrote:

On a different dilemma, I have a FreeBSD proxy server with what looks like a
failing drive.

The drive ONLY holds cache so is not critical for system operation however
id still like to try something.

It seem that no matter how many times I run fsck it still comes up with same
result, is there a way to isolate the bad sectors and use the replacement
ones on drive? Or even just isolate so that I can continue using the drive
for now.



su-2.05b# fsck -y /dev/ad1s1d

** /dev/ad1s1d

** Last Mounted on /mnt/cache

** Phase 1 - Check Blocks and Sizes



CANNOT READ BLK: 15430784

UNEXPECTED SOFT UPDATE INCONSISTENCY



CONTINUE? yes



THE FOLLOWING DISK SECTORS COULD NOT BE READ: 15430836, 15430837, 15430838,
1543  0839, 15430840, 15430841, 15430842,
15430843, 15430844, 15430845, 15430846, 1543
0847,

** Phase 2 - Check Pathnames

** Phase 3 - Check Connectivity

** Phase 4 - Check Reference Counts

** Phase 5 - Check Cyl groups

366612 files, 8044663 used, 1423024 free (125376 frags, 162206 blocks, 1.3%
frag  mentation)



* FILE SYSTEM STILL DIRTY *



* PLEASE RERUN FSCK *

su-2.05b# fsck -y /dev/ad1s1d

** /dev/ad1s1d

** Last Mounted on /mnt/cache

** Phase 1 - Check Blocks and Sizes



CANNOT READ BLK: 15430784

UNEXPECTED SOFT UPDATE INCONSISTENCY



CONTINUE? yes



THE FOLLOWING DISK SECTORS COULD NOT BE READ: 15430836, 15430837, 15430838,
1543  0839, 15430840, 15430841, 15430842,
15430843, 15430844, 15430845, 15430846, 1543
0847,

** Phase 2 - Check Pathnames

** Phase 3 - Check Connectivity

** Phase 4 - Check Reference Counts

** Phase 5 - Check Cyl groups

366612 files, 8044663 used, 1423024 free (125376 frags, 162206 blocks, 1.3%
frag  mentation)



* FILE SYSTEM STILL DIRTY *



* PLEASE RERUN FSCK *


Sounds like the media has failed.  You can try running diagnostics from the 
hard drive manufacturer and test the disk, but you likely need to replace it.


-Derek

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: THE FOLLOWING DISK SECTORS COULD NOT BE READ

2008-08-21 Thread Roland Smith
On Thu, Aug 21, 2008 at 03:24:30PM +0200, Marcel Grandemange wrote:
> On a different dilemma, I have a FreeBSD proxy server with what looks like a
> failing drive.

> It seem that no matter how many times I run fsck it still comes up with same
> result, is there a way to isolate the bad sectors and use the replacement
> ones on drive? 

The drive does that for you.

> Or even just isolate so that I can continue using the drive
> for now.

You could try badsect(8).

Roland
-- 
R.F.Smith   http://www.xs4all.nl/~rsmith/
[plain text _non-HTML_ PGP/GnuPG encrypted/signed email much appreciated]
pgp: 1A2B 477F 9970 BA3C 2914  B7CE 1277 EFB0 C321 A725 (KeyID: C321A725)


pgpHKZE2xMqhD.pgp
Description: PGP signature


Re: THE FOLLOWING DISK SECTORS COULD NOT BE READ

2008-08-21 Thread Oliver Fromme
Marcel Grandemange <> wrote:
 > On a different dilemma, I have a FreeBSD proxy server with what looks like a
 > failing drive.
 > 
 > The drive ONLY holds cache so is not critical for system operation however
 > id still like to try something.
 > 
 > It seem that no matter how many times I run fsck it still comes up with same
 > result, is there a way to isolate the bad sectors and use the replacement
 > ones on drive? Or even just isolate so that I can continue using the drive
 > for now.

The drive's firmware will only remap the bad sectors with
spare sectors when you _write_ to it.

When a read error is encountered while reading a sector,
the drive's firmware will record the sector number, but it
won't remap it yet because it doesn't have any "known good"
contents for that sector.  So it must report the failure to
the OS.

When the sector is written to by the OS, the firmware will
remember that it had a read error, and now it knows the
(new) contents of the sector, so it will make a remapping
entry, use the new sector and report success to the OS.

Therefore, the easiest way to enforce remapping is to first
read the whole disk with dd (so all bad blocks are known to
the firmware), and then write to the whole disk so the
actual remapping will occur:

# dd if=/dev/ad1 of=/dev/null bs=512 conv=sync,noerror
# dd if=/dev/zero of=/dev/ad1 bs=1m

Note that this will take a long time, possibly several
hours, depending on the size of the disk.  You can press
Ctrl-T to see a progress report on the dd(1) command.
Note that "bs=512 conv=sync,noerror" is important for
the first pass, in order to make sure that dd(1) handles
every single sector and continues correctly on errors.

Needless to say, that will ERASE all data on the disk.
You will have to fdisk + bsdlabel + newfs afterwards.

If you have done all of that and you _still_ continue to
get bad sector messages, it most probably means that the
disk drive has run out of spare sectors.  In that case
you should replace the drive immediately.

Remember that disks are pretty cheap these days, and it
might not be worth going through all that hassle in the
first place.  I'd recommend you buy a new drive and
save you some hours of work, a bunch of hairs turning
grey, and some swearing.

Best regards
   Oliver

-- 
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing b. M.
Handelsregister: Registergericht Muenchen, HRA 74606,  Geschäftsfuehrung:
secnetix Verwaltungsgesellsch. mbH, Handelsregister: Registergericht Mün-
chen, HRB 125758,  Geschäftsführer: Maik Bachmann, Olaf Erb, Ralf Gebhart

FreeBSD-Dienstleistungen, -Produkte und mehr:  http://www.secnetix.de/bsd

"In My Egoistical Opinion, most people's C programs should be indented
six feet downward and covered with dirt."
-- Blair P. Houghton
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


THE FOLLOWING DISK SECTORS COULD NOT BE READ

2008-08-21 Thread Marcel Grandemange
On a different dilemma, I have a FreeBSD proxy server with what looks like a
failing drive.

The drive ONLY holds cache so is not critical for system operation however
id still like to try something.

It seem that no matter how many times I run fsck it still comes up with same
result, is there a way to isolate the bad sectors and use the replacement
ones on drive? Or even just isolate so that I can continue using the drive
for now.

 

su-2.05b# fsck -y /dev/ad1s1d

** /dev/ad1s1d

** Last Mounted on /mnt/cache

** Phase 1 - Check Blocks and Sizes

 

CANNOT READ BLK: 15430784

UNEXPECTED SOFT UPDATE INCONSISTENCY

 

CONTINUE? yes

 

THE FOLLOWING DISK SECTORS COULD NOT BE READ: 15430836, 15430837, 15430838,
1543  0839, 15430840, 15430841, 15430842,
15430843, 15430844, 15430845, 15430846, 1543
0847,

** Phase 2 - Check Pathnames

** Phase 3 - Check Connectivity

** Phase 4 - Check Reference Counts

** Phase 5 - Check Cyl groups

366612 files, 8044663 used, 1423024 free (125376 frags, 162206 blocks, 1.3%
frag  mentation)

 

* FILE SYSTEM STILL DIRTY *

 

* PLEASE RERUN FSCK *

su-2.05b# fsck -y /dev/ad1s1d

** /dev/ad1s1d

** Last Mounted on /mnt/cache

** Phase 1 - Check Blocks and Sizes

 

CANNOT READ BLK: 15430784

UNEXPECTED SOFT UPDATE INCONSISTENCY

 

CONTINUE? yes

 

THE FOLLOWING DISK SECTORS COULD NOT BE READ: 15430836, 15430837, 15430838,
1543  0839, 15430840, 15430841, 15430842,
15430843, 15430844, 15430845, 15430846, 1543
0847,

** Phase 2 - Check Pathnames

** Phase 3 - Check Connectivity

** Phase 4 - Check Reference Counts

** Phase 5 - Check Cyl groups

366612 files, 8044663 used, 1423024 free (125376 frags, 162206 blocks, 1.3%
frag  mentation)

 

* FILE SYSTEM STILL DIRTY *

 

* PLEASE RERUN FSCK *

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"