Solved

Encrypted Reiserfs Fails to Mount -- Reiserfsck Fails as Well

Posted on 2004-07-30
9
762 Views
Last Modified: 2013-12-15
This is rather sordid...

I formatted a reiserfs /Crypt directory (40GB of files that I would like to retrieve) with encryption (I'm using SuSE 8.2).

Booting the system gives the friendly output of:

fsck failed. Please repair maually and reboot. The root file system is currently mounted read-only. To remount it read-write do:
bash#mount -n -o remount,rw /

I've tried running fsck and reiserfsck, which says "reiserfs_open: neither new nor old reiserfs format found on /dev/hda4
reiserfsck: Cannot open filesystem on "/dev/hda4"

Just to be sure, I also checked it with e2fsck and jfs_fsck to no avail.

So, I need to be able to mount this system. What can I do?
0
Comment
Question by:AtomAntic
  • 6
  • 2
9 Comments
 

Author Comment

by:AtomAntic
Comment Utility
I used the SuSE install/rescue boot to run reiserfsck on /dev/hda2 (the / system) and it returned no bad blocks -- looked ok.

badblocks /dev/hda4 returned no bad blocks found...
Still can't run it on /dev/hda4, though.

one more thing...

boot logs show this as well:

reiserfsck: Cannot open filesystem on "/dev/hda4"
Warning... fsck.reiserfs for device /dev/hda4 exited with signal 6.
fsck.reiserfs /dev/hda4 failed (status 0x8). Run manually!

0
 

Author Comment

by:AtomAntic
Comment Utility
I also get this

# mount /Crypt

sh-2021: reiserfs_read_super: can not find reiserfs on ide0(3,4)
mount: wrong fs type, bad option, bad superblock on /dev/hda4, or too many mounted file systems
0
 
LVL 9

Expert Comment

by:e-tsik
Comment Utility
Hi :-)

It could be a problem that happens during the format process.
Can you post the output of
fdisk -l /dev/hda

Can you also post the exact command you use to format your partition and the output of it?
0
 

Author Comment

by:AtomAntic
Comment Utility
It has data on it and worked for a while after I formatted it.

The main problem is really not that the /Crypt partition won't mount but that the system itself won't boot.

I've run fsck on /dev/hda2 (the root partition) and it outputs fine in read-only mode. This doesn't change anything...
In read-write it uses reiserfsck to claim:

Partition /dev/hda2 is mounted w/ write permissions, cannot check it.
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 9

Expert Comment

by:e-tsik
Comment Utility
First, your problems with /dev/hda4 seem to be serious - data may have been erased.

You can have the /Crypt file system not automatically mounted by changing /etc/fstab
Look for the line representing /Crypt , change the mount options (4th column) from "defaults" to "noauto" .

This should prevent the startup problem.
0
 

Author Comment

by:AtomAntic
Comment Utility
OK,

New update:

I wiped the system (it wasn't important to keep that part anyhow)

Now I just want to get /dev/hda4 (the encrypted reiserfs) mounted.

(now that I have the system up and running, I can give you system outputs :)


so... System boots and from the terminal (expecting that it will ask for my password to access the encrypted filesystem--as it does on my laptop):

# mount /crypt

mount: wrong fs type, bad option, bad superblock on /dev/hda4,
       or too many mounted file systems

---------- So I try...

# fsck /dev/hda4
fsck 1.28 (31-Aug-2002)
reiserfsck 3.6.4 (2002 www.namesys.com)
Will read-only check consistency of the filesystem on /dev/hda4
Will put log info to 'stdout'

Do you want to run this program?[N/Yes] (note need to type Yes if you do):Yes
reiserfs_open: neither new nor old reiserfs format found on /dev/hda4

reiserfsck: Cannot not open filesystem on "/dev/hda4"
Warning... fsck.reiserfs for device /dev/hda4 exited with signal 6.
fsck.reiserfs /dev/hda4 failed (status 0x8). Run manually!

---------- So I try...

# reiserfsck /dev/hda4
reiserfsck 3.6.4 (2002 www.namesys.com)
Will read-only check consistency of the filesystem on /dev/hda4
Will put log info to 'stdout'

Do you want to run this program?[N/Yes] (note need to type Yes if you do):Yes
reiserfs_open: neither new nor old reiserfs format found on /dev/hda4

reiserfsck: Cannot not open filesystem on "/dev/hda4"


HERE'S WHERE I'M STUCK :~.



0
 

Author Comment

by:AtomAntic
Comment Utility
and...

# badblocks -v /dev/hda4
Checking for bad blocks in read-only mode
From block 0 to 43190752
Pass completed, 0 bad blocks found.
0
 
LVL 6

Accepted Solution

by:
de2Zotjes earned 500 total points
Comment Utility
you use mount /Crypt, can you tell what is in your /etc/fstab?

also you keep insisting that this is an encrypted filesystem, normally that would mean that you first run losetup to create a loop device and then mount the loop:

losetup -e <enc> /dev/loop0 /dev/hda4
(passwd asked)
mount -t reiserfs /dev/loop0 /Crypt
0
 

Author Comment

by:AtomAntic
Comment Utility
I figured it out, that was it...

I needed a /etc/cryptotab file with the loop devices.

:)
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
The purpose of this article is to demonstrate how we can use conditional statements using Python.
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now