[Mageia-discuss] software-induced hard disk sector reallocation problem

Tony Blackwell tablackwell at bigpond.com
Mon Nov 12 07:14:54 CET 2012

Greetings all,
I've stumbled on what seems like a really nasty problem, where after 
adding a new disk, a different perfectly good disk (as of a few minutes 
prior) comes to have a large number of reallocated sectors and the 
mageia 'smart' software is screaming at me that the disk is about to 
fail _now_ and to back it up.

mageia 1
7 sata disks.
bought a new (my first) 3TB disk, used gdisk to partition it, 'L' for 
partition types, chose the last option for MBR  (was this wrong?)  Next 
created an encrypted filesystem on this:

a)  modprobe dm-mod
/usr/local/bin/cryptsetup.sh -c aes -h ripemd160 -y -b `blockdev 
--getsize /dev/
sdg1` create cryptvol2 /dev/sdg1

b)  mke2fs -j /dev/mapper cryptvol2

c) after completion, dmsetup remove cryptvol2

d) mount the new filesystem with;

modprobe dm-mod
/usr/local/bin/cryptsetup.sh -c aes -h ripemd160 -y -b `blockdev 
--getsize /dev/
sdg1` create cryptvol2 /dev/sdg1
mount /dev/mapper/cryptvol2 /mnt/crypt2

All looked good, but there was a 'smart' warning icon about a disk about 
to fail.  The 3 TB disk I'd just done happened to be /dev/sdg.  The disk 
reporting errors was /dev/sdh, a 2TB disk.

Device: /dev/sdh
SMART status: enabled
Automatic Offline Data Collection status: enabled
ALERT: The drive is reporting that it will FAIL very soon.
Please back up as soon as possible!

I grumbled, thought it a strange coincidence that this just appeared, 
took out the 'faulty' disk, bought another 3TB disk to replace it, did 
it all again.  The new 3TB disk as again seen as /dev/sdg.  Did same 
stuff again, up came the same error message about yet _another_ disk.  
Having had zero reallocated sectors only a few minutes before, it now 
reports 3975 reallocated sectors, the identical number to the first 
'normal' disk, and same error messages.  The 'faulty' disk was again the 
one seen as /dev/sdg. This reallocation seems to have welded itself into 
the disk; persists after reboot.

Help!  I've no idea where to go next.  Looks like a major bug, but in what?

More information about the Mageia-discuss mailing list