LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Mount problem - Bad superblock (https://www.linuxquestions.org/questions/linux-general-1/mount-problem-bad-superblock-428070/)

stratogratte 03-24-2006 12:07 PM

Mount problem - Bad superblock
 
Hi
I have a big problem with my second HDD on my dedicated server.
When I try to mount the HDD to be able to read my files on it, I get the following error:

Quote:

mount /dev/sdb3 /backup -t ext3
mount: wrong fs type, bad option, bad superblock on /dev/sdb3,
missing codepage or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
In kern.log, here is the reported error:
Quote:

kernel: ext3: No journal on filesystem on sdb3
Do you have any idea of what I could do to fix this problem and to be able to read again my data?


Thank you for your help...

TigerOC 03-24-2006 12:11 PM

The command is incorrect;
mount -t ext3 /dev/sdb3 /backup
note /backup must be a valid directory under /

stratogratte 03-24-2006 12:16 PM

That's exactly the same command/same result.
And /backup directory exists and is a valid directory.

TigerOC 03-24-2006 12:21 PM

Quote:

Originally Posted by stratogratte
That's exactly the same command/same result.
And /backup directory exists and is a valid directory.

??? The commands are very different you failed to define the parameters for mounting the device. i.e. the parameters must be specified before the device -t ext3.

If the device is not a valid ext3 file system then do;

tune2fs -j /dev/sdb3

stratogratte 03-24-2006 12:24 PM

It seems like -t ext3 being before or after the device doesn't change anything for the command to work properly...

What exactly will do the "tune2fs -j /dev/sdb3" command?
(I am afraid of loosing all my data)

TigerOC 03-24-2006 12:31 PM

Quote:

Originally Posted by stratogratte
It seems like -t ext3 being before or after the device doesn't change anything for the command to work properly...

What exactly will do the "tune2fs -j /dev/sdb3" command?
(I am afraid of loosing all my data)

tune2fs -j will convert an ext2 file system into a journalised ext3 file system.

to explain mount -t ext3;
-t ext3 =file system type ext3
if you unsure of the file system type do cfdisk /dev/sdb and it will list the partitions on the drive with their file type.

stratogratte 03-24-2006 12:49 PM

I know perfectly ext3 is the filesystem type...
The problem isn't that sdb3 is ext2 type, the problem is the following error:
Quote:

kernel: ext3: No journal on filesystem on sdb3
What I presume means that the partition table of sdb3 is corrupted. Is it really the problem? What can I do the fix it?

EDIT:
Strange!!!! sdb3 is indeed an ext2 type O_O It should have been an ext3. What could have happened?
Is the tune2fs -j command secure to be applied?

EDIT2:
The problem is that if I mount sdb3 in ext2, there is no data at all. If I convert it in ext3, will my data be back?

stratogratte 03-24-2006 02:00 PM

So what should I do safely enough to no risk to lose my data? :)

TigerOC 03-24-2006 02:55 PM

Its telling you;
kernel: ext3: No journal on filesystem on sdb3

that's how I knew that it was probably ext2. To convert it do tune2fs -j /dev/sbd3. It does not affect the data but creates a journal. What this does is record the destination of writes every 5s. Are you certain that you have written data to this partition?

stratogratte 03-24-2006 03:16 PM

In fact the HDD partially crashed recently but was fixed. After it was fixed, I got all my data again, but since some hours now, I don't know how, I have these problems. My thought is that the table partition(the journal) has crashed, and so that the system think it is ext2, but it should be ext3...

TigerOC 03-24-2006 03:33 PM

Quote:

Originally Posted by stratogratte
In fact the HDD partially crashed recently but was fixed. After it was fixed, I got all my data again, but since some hours now, I don't know how, I have these problems. My thought is that the table partition(the journal) has crashed, and so that the system think it is ext2, but it should be ext3...

run a scan on the unmounted disk;

e2fsck /dev/sdb6

stratogratte 03-24-2006 03:41 PM

e2fsck /dev/sdb3
e2fsck 1.37 (21-Mar-2005)
/dev/sdb3: clean, 11/19464192 files, 610802/38925495 blocks

stratogratte 03-24-2006 04:17 PM

So what I still do the tune2fs -j /dev/sbd3 command?
What do you think about my e2fsck result?

TigerOC 03-25-2006 12:38 AM

Quote:

Originally Posted by stratogratte
So what I still do the tune2fs -j /dev/sbd3 command?
What do you think about my e2fsck result?

The scan indicates nothing wrong so go ahead and add the journal with tune2fs.

stratogratte 03-25-2006 10:54 AM

So the command will make my data come back? :/

stratogratte 03-25-2006 11:31 AM

I have found a backup of the superblock of my HDD, and I get this with e2fsck:
Quote:

e2fsck -b 32768 /dev/sdb3
e2fsck 1.37 (21-Mar-2005)
/dev/sdb3 was not cleanly unmounted, check forced.
Pass 1: Checking inodes, blocks, and sizes
Later, I get
Quote:

kernel: Disabling IRQ #11
And some errors like these appear:
Quote:

Error reading block 35127298 (Attempt to read block from filesystem resulted in short read) while doing inode scan. Ignore error?
What do you think about this?

TigerOC 03-25-2006 12:02 PM

You must run a repair with e2fsck. Its unclear what you are doing with the drive but what is clear is that the drive is not being unmounted cleanly and if you continue like this you will lose the data on it.

stratogratte 03-25-2006 12:17 PM

I haven't done anything else than what I said :/ As I said, I don't want to do anything dangerous to don't lose my data :(
So I should run this?
Quote:

e2fsck -p -b 32768 /dev/sdb3
How could IRQ 11 be disabled only in doing the "e2fsck -b 32768 /dev/sdb3" command?

Thanks for your help


All times are GMT -5. The time now is 05:11 PM.