LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 06-26-2008, 07:38 PM   #1
Nick_S_
LQ Newbie
 
Registered: Oct 2006
Posts: 14

Rep: Reputation: 0
FSCK: Duplicate or bad block in use!


Hi,

I recently re-installed slackware 12.0. I formatted the / partition and installed the OS there. I left my /home partition alone so I could preserve my data.

The installation went fine and I created a new user called nick and gave the user my "old" home dir location of /home/nick

I logged in as nick and started up KDE with the command "startx". Everything went fine but the system hung badly when loading up the desktop portion of the KDE startup process. I had to reboot because of it. I guessed that something on my desktop from my old installation was causing the problem so I deleted all the .desktop files from my /home/nick/Desktop directory with the exception of Home, Trash and System. KDE loaded up fine this time.

Now to the problem after this bit of history. I was configuring my sound card in alsamixer, exited the program and rebooted the computer. Upon bootup FSCK was run on the home directory because it saw that there were some errors. How those errors appeared after a clean shutdown I don't know. FSCK then reports a message about 60% of the way through: "Duplicate or bad block in use!"

I don't like the way that sounds and I can't find much on google about what it means. It stops right at that message. Some forums have suggested that the hard drive has crapped out but I am hoping that is not the case here.

Any advice is greatly appreciated. I have most of my data backed up but I would love to save it all.

Nick
 
Old 06-26-2008, 09:48 PM   #2
Mr. C.
Senior Member
 
Registered: Jun 2008
Posts: 2,529

Rep: Reputation: 63
You're not likely going to discover what caused the file system corruption.

fsck doesn't run because it finds errors - rather, the system runs fsck at startup. The disk can be marked as clean, but that is only a flag indicating to the next fsck run that it can likely skip the check. As long as the system keeps resetting the flag upon unmounting the disk on reboot, fsck will skip checking the disk. To mitigate long term problems with this shortcut, the system will periodically (eg. every 30 days, 30 reboots, etc.) do a full check.

So, you'll likely not discover when or how the file system became corrupt. All you can do now is let fsck "fix" the problem, run disk diagnostics, and possibly reinstall lost files/directories as necessary.

A system with bad RAM of course can cause bad data to be written out to disk, as could a bad disk controller. But these hardware problems will likely manifest themselves in many different ways, so you'll catch onto them soon enough.
 
Old 06-26-2008, 11:00 PM   #3
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,925
Blog Entries: 44

Rep: Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159
Hi,

I would suggest that you run 'fsck' as a single user on the filesystem in question. You can use your install cd1 to boot and run fsck or you could just pass the 'single' parameter at boot to the kernel.
 
Old 06-27-2008, 08:17 AM   #4
Nick_S_
LQ Newbie
 
Registered: Oct 2006
Posts: 14

Original Poster
Rep: Reputation: 0
Waited a bit longer

Hi,

Thanks for the responses. After I posted my question I decided to load up Linux again. FSCK printed out the same "Duplicate or bad block in use" message again but I decided to wait a bit longer to see if another message would come or if it indeed had hung. I removed the cover on my computer to listen to the hard drive(it runs pretty quiet) and to my surprise it was still making noise as if it was being accessed. About 3 to 5 minutes later FSCK printed out some more message telling me to run FSCK manually then took me to the login prompt.

So I guess not all hope is lost. I shutdown and unplugged for the night since about this time a lightening storm was moving in and I decided I had had enough fun for the night.

Nick
 
Old 06-27-2008, 11:05 AM   #5
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,925
Blog Entries: 44

Rep: Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159
Hi,

The command is 'fsck' not 'FSCK'.

As I stated you should be running 'fsck' as a single user to insure no one is mounting or a mounted volume is in use that you may be attempting to do a 'fsck' on.
 
Old 06-27-2008, 08:18 PM   #6
Woodsman
Senior Member
 
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482

Rep: Reputation: 546Reputation: 546Reputation: 546Reputation: 546Reputation: 546Reputation: 546
Hopefully fsck solved the problem. If not, perhaps this thread might help:

Smartmontools Tid Bits. In that thread I linked to a how-to discussing bad blocks.
 
Old 09-05-2008, 05:34 AM   #7
harryhaller
Member
 
Registered: Sep 2004
Distribution: Slackware-14.2
Posts: 468

Rep: Reputation: Disabled
superblock could not be read or does not describe a correct ext2

I, too, have a problem with fsck and e2fsck.

I bought a one terabyte external usb drive last week. During start up it brings me the following message:

Quote:

/sbin/e2fsck: No such file or directory while trying to open /dev/sda1 /dev/sda1:
The superblock could not be read or does not describe a correct ext2 filesystem.
If the device is valid and it really contains an ext2 filesystem (and not swap or ufs or something else), then the superblock is corrupt, and you might try running e2fsck with an alternate superblock:
e2fsck -b 8193 <device>
The "-b 8193" parameter is incorrect (it's just an example I suppose) so I ran mke2fs -n /dev/sda1 to get the superblocks and I then ran e2fsck -b 4096000 /dev/sda1 which bought me the following message:

Quote:
e2fsck 1.40.8 (13-Mar-2008)
e2fsck: Device or resource busy while trying to open /dev/sda1
Filesystem mounted or opened exclusively by another program?
I ran this again after going down to telinit 1 and got the same result.

However - if I run e2fsck /dev/sda1 I get the following message:
Quote:
e2fsck 1.40.8 (13-Mar-2008)
/dev/sda1: clean, 11/6111232 files, 398825/24414775 blocks
According to that I have NO problems!

Since the drive is new, I have only test files on it so went and rebuilt the file systems while in telinit 1 - the results were the same when I rebooted.

Can anyone help me to get rid of these error messages and/or explain why e2fsck thinks the device is busy when I check it with the superblock parameter?
 
Old 09-05-2008, 08:57 AM   #8
harryhaller
Member
 
Registered: Sep 2004
Distribution: Slackware-14.2
Posts: 468

Rep: Reputation: Disabled
UPDATE - I have completely rebuilt the disk, using fdisk to partition it and so far so good.
 
Old 09-06-2008, 05:08 AM   #9
harryhaller
Member
 
Registered: Sep 2004
Distribution: Slackware-14.2
Posts: 468

Rep: Reputation: Disabled
Solution?

Unfortunately, the "problem" has re-appeared - and then again disappeared.

This sporadic appearance and disappearance of the problem seems to be related to whether the external drive has been powered down.

Yesterday I wrote the previous post after having set up the new partitions and file systems. and having rebooted with no errors because the drive was mounted for the first time since creating of the fs.

Later on I rebooted - and the problem re-appeared. Very depressing.

This morning, after the machine had been off all night, there was no problem. I had noticed before that disconnecting the drive, which is a crude reset, got rid of the problems (but I forgot about it).

This would seem a logical explantion why the system thinks that superblock is bad and why, when one tries to run fsck it complains that the superblock is still in use or that some application has exclusive use of it.

The solution is to disconnect the power to disk drive when rebooting - not an elegant solution.
 
Old 09-06-2008, 06:23 AM   #10
keefaz
LQ Guru
 
Registered: Mar 2004
Distribution: Slackware
Posts: 6,552

Rep: Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872Reputation: 872
use 0 0, for 5th and 6th fields in /etc/fstab for /dev/sda1 maybe ?
(so it won't check /dev/sda1 at boot, theorically)
 
Old 09-06-2008, 07:52 AM   #11
harryhaller
Member
 
Registered: Sep 2004
Distribution: Slackware-14.2
Posts: 468

Rep: Reputation: Disabled
Wink

Quote:
Originally Posted by keefaz View Post
use 0 0, for 5th and 6th fields in /etc/fstab for /dev/sda1 maybe ?
(so it won't check /dev/sda1 at boot, theorically)
Works wonderfully. Thanks Keefaz.
 
  


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Slackware 10.2 hda2 error on boot (Bad or Duplicate Block) PastorFrederick Linux - Newbie 2 10-08-2005 08:37 AM
duplicate/bad blocks well scanning on home dir... only1gameguru Linux - General 3 08-28-2004 03:28 AM
block drivers... holy fsck??!!! infamous41md Programming 4 05-14-2004 09:32 PM
fsck many bad blocks mjolnir *BSD 5 01-13-2004 06:35 AM
duplicate/bad IP error on new RedHat 9 install nbcthreat Linux - Networking 2 08-13-2003 03:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 09:44 AM.

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