Re: [Hampshire] Laptop Hardrive

Top Page

Reply to this message
Author: James Courtier-Dutton
Date:  
To: lug, Hampshire LUG Discussion List
Subject: Re: [Hampshire] Laptop Hardrive
On 19 May 2010 12:03, James Courtier-Dutton <james.dutton@???> wrote:
> On 19 May 2010 11:46, Vic <lug@???> wrote:
>>
>>> reallocations appear in the Linux syslog
>>
>> Really? I've only ever seen summary information from smartmontools there.
>> I've also been unable to find anything in Google to support the idea that
>> actual reallocation map data goes into syslog; perhaps you'd post some
>> examples so we can all learn about it.
>>
> From the kernel sources:
> constants.c:    {0x0C01, "Write error - recovered with auto reallocation"},
> constants.c:    {0x0C02, "Write error - auto reallocation failed"},
> constants.c:    {0x1104, "Unrecovered read error - auto reallocate failed"},
> constants.c:    {0x1406, "Record not found - data auto-reallocated"},
> constants.c:    {0x1603, "Data sync error - data auto-reallocated"},
> constants.c:    {0x1706, "Recovered data without ECC - data auto-reallocated"},
> constants.c:    {0x1802, "Recovered data - data auto-reallocated"},
>
> Any of the above cases will produce a syslog entry, the logical sector
> number will also be included close by in the log.
>
>

Example of a syslog entry for one of the above:
Apr 27 11:26:42 quad kernel: [ 3821.830237] sd 2:0:0:0: [sde]
Unhandled sense code
Apr 27 11:26:42 quad kernel: [ 3821.830239] sd 2:0:0:0: [sde] Result:
hostbyte=DID_OK driverbyte=DRIVER_SENSE
Apr 27 11:26:42 quad kernel: [ 3821.830243] sd 2:0:0:0: [sde] Sense
Key : Medium Error [current] [descriptor]
Apr 27 11:26:42 quad kernel: [ 3821.830247] Descriptor sense data with
sense descriptors (in hex):
Apr 27 11:26:42 quad kernel: [ 3821.830249]         72 03 11 04 00 00
00 0c 00 0a 80 00 00 00 00 00
Apr 27 11:26:42 quad kernel: [ 3821.830258]         0f 4d 1b 23
Apr 27 11:26:42 quad kernel: [ 3821.830261] sd 2:0:0:0: [sde] Add.
Sense: Unrecovered read error - auto reallocate failed
Apr 27 11:26:42 quad kernel: [ 3821.830266] sd 2:0:0:0: [sde] CDB:
Read(10): 28 00 0f 4d 1b 20 00 00 08 00
Apr 27 11:26:42 quad kernel: [ 3821.830274] end_request: I/O error,
dev sde, sector 256711459


So, here it is trying to reallocate the sector due to a read fault,
but failed to do so.
In smartctl, the drive only had 2 reallocated sectors so the
reallocate should have succeeded as there were spare sectors left for
reallocation.
I suspect a firmware bug. The drive was replaced with a different model.