LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 01-06-2010, 07:00 PM   #1
neuplnost
LQ Newbie
 
Registered: Dec 2009
Posts: 6

Rep: Reputation: 0
Question can't find bad blocks list


Hi all!

I've got a new hard drive, formatted it to ext3, and made a check for bad blocks using e2fsck. It gave me this:

Quote:
kubuntu@Pocitac:~$ sudo e2fsck -f -c /dev/sdi1
e2fsck 1.41.9 (22-Aug-2009)
Checking for bad blocks (read-only test): done
/dev/sdi1: Updating bad block inode.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information

/dev/sdi1: ***** FILE SYSTEM WAS MODIFIED *****
/dev/sdi1: 11/91578368 files (0.0% non-contiguous), 5798288/366284000 blocks
I just would like to know where i can find how many bad blocks were found (perhaps one if it is using singular in sentence "Updating bad block inode."??), and what is/are the number(s) of located bad block(s).

Sorry if my question is stupid (seems so to me too), but i spent more than hour to find it out without any satisfying result.

Thank you.

Last edited by neuplnost; 01-07-2010 at 02:58 AM.
 
Old 01-06-2010, 09:09 PM   #2
nikhil760
LQ Newbie
 
Registered: Jan 2010
Distribution: Arch Linux
Posts: 2

Rep: Reputation: 0
Don't worry no bad blocks

You don't have any bad blocks, unless your harddrive is showing some weird size. I spent several hours trying to 'fix' badblocks on a flash drive which showed capacity of 3GB instead of its real size of 476MB.In case you are curious, use the command badblocks http://linux.die.net/man/8/badblocks, but it only apparently lists the badblocks and not fix it, which I don't think you need.And regarding /dev/sdi1, how many harddisks do you have 10?

Last edited by nikhil760; 01-06-2010 at 09:13 PM.
 
Old 01-07-2010, 02:56 AM   #3
neuplnost
LQ Newbie
 
Registered: Dec 2009
Posts: 6

Original Poster
Rep: Reputation: 0
Thanks for the reply nikhil760. This is my 5th harddisk. This one is external and intended only for backups of everything on the other disks.

I ran e2fsck with the option "-c", this should run badblocks program under the e2fsck.

First i ran e2fsck without "-c" option. It finished with exit code 0, which means that no errors were found. Then i ran e2fsck -c, and that finished with exit code 1, which means that there were some errors and have been corrected. This made me think that there are some bad blocks. I'm just curious if my conclusion is correct, and if yes, where i could see the list of bad blocks. The best would be to see it without need to run the test for bad blocks again, because it takes 13 hours.

If there are no bad blocks, why number "1" on exit code?

Could somebody bring more light to this please?

Thanks.

Last edited by neuplnost; 01-08-2010 at 08:18 AM.
 
Old 12-18-2010, 11:16 AM   #4
arizonafox
LQ Newbie
 
Registered: Dec 2010
Posts: 3

Rep: Reputation: 1
View bad blocks list

To view the bad blocks list on the ext2/3/4 file system, use the dumpe2fs command. From the manpage:

OPTIONS
-b print the blocks which are reserved as bad in the filesystem.

sudo dumpe2fs -b /dev/sdb1

When I ran this after running e2fsck -c -c /dev/sdb1, it showed that the file system had been modified, but no bad blocks were listed.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Bad blocks on reiserfs awilisch Linux - Hardware 1 01-25-2007 11:15 AM
Displaying bad blocks list on ext2/ext3 MikeBike Linux - Hardware 1 05-31-2006 03:55 PM
list known bad blocks. bruse Linux - Software 1 02-19-2006 08:50 AM
bad blocks bong.mau Linux - General 1 11-16-2005 02:17 PM
ReiserFS with bad blocks bruce ford Linux - Software 2 07-23-2005 04:15 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 03:26 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration