From: Bruno W. I. <br...@wo...> - 2005-01-12 05:27:48
|
On Wed, Jan 12, 2005 at 00:47:48 +0100, Zoltan Podlovics <zol...@gm...> wrote: > Perhaps I misunderstood something, but I'm unable to reallocate > offline_uncorrectable sectors with the method described > in badblockhowto. > > The disk currently is a member of a raid1 array. I have found the > "bad" blocks around the reported sector with the following command: > > export i=139735500 && while [ $i -lt 139735600 ]; do echo $i; dd > if=/dev/hdb of=/dev/null bs=512 count=1 skip=$i; let i+=1; done > > I have removed the partition (not the whole disk) from raid1 array > (raidsetfaulty && raidhotremove) and I have zeroed the sectors and > soon the whole partition (with sync!) but nothing had happened. I have > executed smartctl -t offline /dev/hdb when finished smartctl -t long > /dev/hdb but I still have errors when I executing the script that I > mentioned earlier: > > 139735510 > 1+0 records in > 1+0 records out > 139735511 > dd: reading `/dev/hdb': Input/output error > 0+0 records in > 0+0 records out > 139735512 > dd: reading `/dev/hdb': Input/output error > 0+0 records in > 0+0 records out > [..] The above suggests that the OS is handling blocks using a size larger than 512 bytes and that to write a partial block it is doing a read first which fails because of the bad sector. Try using a blocksize of 4096. You will need to divide the sector numbers by 8 when you do this. |