Gentoo Archives: gentoo-user

From: meino.cramer@×××.de
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] [OT] Badblocks on my harddisk
Date: Sat, 26 Jul 2014 10:24:08
Message-Id: 20140726102353.GC3835@solfire
In Reply to: Re: [gentoo-user] [OT] Badblocks on my harddisk by Mick
1 Mick <michaelkintzios@×××××.com> [14-07-26 11:28]:
2 > On Saturday 26 Jul 2014 02:49:15 meino.cramer@×××.de wrote:
3 > > Hi,
4 > >
5 > > After running smartctl for an extended offline test I got
6 > > a badblock (information extracted from the report):
7 > >
8 > > SMART Self-test log structure revision number 1
9 > > Num Test_Description Status Remaining LifeTime(hours)
10 > > LBA_of_first_error # 1 Extended offline Completed: read failure
11 > > 90% 14460 4288352511 197 Current_Pending_Sector 0x0032 200
12 > > 200 000 Old_age Always - 1
13 > >
14 > > I found a explanation to map the LBA to a partition here:
15 > > http://smartmontools.sourceforge.net/badblockhowto.html
16 > >
17 > > My partition layout is:
18 > > #> sudo fdisk -lu /dev/sda
19 > >
20 > > Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
21 > > Units: sectors of 1 * 512 = 512 bytes
22 > > Sector size (logical/physical): 512 bytes / 512 bytes
23 > > I/O size (minimum/optimal): 512 bytes / 512 bytes
24 > > Disklabel type: dos
25 > > Disk identifier: 0x07ec16a2
26 > >
27 > > Device Boot Start End Blocks Id System
28 > > /dev/sda1 * 2048 104447 51200 83 Linux
29 > > /dev/sda2 104448 12687359 6291456 82 Linux swap / Solaris
30 > > /dev/sda3 12687360 222402559 104857600 83 Linux
31 > > /dev/sda4 222402560 1953525167 865561304 5 Extended
32 > > /dev/sda5 222404608 232890367 5242880 83 Linux
33 > > /dev/sda6 232892416 442607615 104857600 83 Linux
34 > > /dev/sda7 442609664 652324863 104857600 83 Linux
35 > > /dev/sda8 652326912 862042111 104857600 83 Linux
36 > > /dev/sda9 862044160 1071759359 104857600 83 Linux
37 > > /dev/sda10 1071761408 1281476607 104857600 83 Linux
38 > > /dev/sda11 1281478656 1491193855 104857600 83 Linux
39 > > /dev/sda12 1491195904 1953525167 231164632 83 Linux
40 > > 4288352511 <<< The number reported by smartctl
41 > >
42 > >
43 > > Following the linked document...
44 > > It seems the bad LBA is not on the checked harddisk.
45 > >
46 > > Or (more obvious) I did something wrong...
47 >
48 > You are probably comparing different units. The Start and End of fdisk are
49 > reporting sectors, each sector being 512 bytes. Therefore if the LBA is
50 > reported by smartctl in bytes, you have:
51 >
52 > 4,288,352,511 ÷ 512 = 8,375,688.5
53 >
54 > which would place it within your swap partition.
55 >
56 > I would do this:
57 >
58 > swapoff /dev/sda2
59 >
60 > dd if=/dev/zero of=/dev/sda2 bs=512 conv=notrunc
61 >
62 > mkswap -L swap -c /dev/sda2
63 >
64 > swapon /dev/sda2
65 >
66 > and hopefully the problem will be gone when you run the next smartctl test.
67 >
68 > --
69 > Regards,
70 > Mick
71
72 Hi Mick,
73
74 got this:
75
76 #> /root>mkswap -L swap -c /dev/sda2
77 1 bad page
78 Setting up swapspace version 1, size = 6291448 KiB
79 LABEL=swap, UUID=71686035-fad3-427c-a3a5-c86ac6aefa2f
80
81
82 ...so the dd-command hasn't triggered the remapping?
83
84 What do you suggest how to proceed?
85 New harddrive?
86 Or?
87
88 Best regards,
89 mcc