Re: reiserfs3 rebuild-tree successful but no files
Use ftp://80.133.138.104:12121 sorry, but I get 'no route to host' every time. 80.133.138.104 is owned by the 'Deutsche Telekom AG' (An ISP in Germany). Looks like a dynamic IP, currently not in use - No route -- Adrian
Re: reiserfs3 rebuild-tree successful but no files - SOLVED
On Friday 11 February 2005 08:54, you wrote: Hello On Fri, 2005-02-11 at 10:38, Christian Placzek wrote: On Thursday 10 February 2005 16:25, you wrote: On Thursday 10 February 2005 18:02, Christian Placzek wrote: what if you zero the first 64K with dd conv=notrunc if=/dev/zero of=device bs=4096 count=16 can you mount it now? (rebuild-tree should already complete by the mount time). Hurray, this is the trick! I don't understand why, but I can see hundreds of directories and thousends of files. Thanks a lot!!! do you have anything related in the syslog about the mount time? This is the first time 'dmesg' gives an output: ReiserFS: sdc5: found reiserfs format 3.6 with standard journal ReiserFS: sdc5: using ordered data mode ReiserFS: sdc5: journal params: device sdc5, size 8192, journal first block 18, max trans len 1024, max batch 900, max commit age 30, max trans age 30 ReiserFS: sdc5: checking transaction log (sdc5) ReiserFS: sdc5: Using r5 hash to sort names Could you give me a technical describtion why this worked? am I correct that mount /dev/sdc5 /mnt mounted it as ext mount /dev/sdc5 /mnt -t reiserfs refused to mount with mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems and after dd conv=notrunc if=/dev/zero of=/dev/sdc5 bs=4096 count=16 mount /dev/sdc5 /mnt mounts reiserfs? Yes, you are right. Thanks Kris
Re: reiserfs3 rebuild-tree successful but no files
after rebuilding the tree, does 'reiserfsck --check device' see these files? Yes, see my original email from 08.02.2005 23:21. The original output has a length of about 13000 lines. A extract looks like this: ... rebuild_semantic_pass: The entry [741258 1025777] (www.firstname.de.ico) in directory [296134 741258] points to nowhere - is removed rewrite_file: 2 items of file [741258 1041142] moved to [741258 93475] The entry [741258 1041142] (deltab.de.ico) in directory [296134 741258] updated to point to [741258 93475] rewrite_file: 2 items of file [741258 1041137] moved to [741258 93569] The entry [741258 1041137] (www.bild.t-online.de.ico) in directory [296134 741258] updated to point to [741258 93569] ... The last lines: ... Flushing..finished Objects without names 18403 Empty lost dirs removed 384 Dirs linked to /lost+found: 2174 Dirs without stat data found 83 Files linked to /lost+found 16229 Objects having used objectids: 49 files fixed 47 dirs fixed 2 Pass 4 - finished done 1476, 37 /sec Deleted unreachable items 716 Flushing..finished Syncing..finished ### reiserfsck finished at Tue Feb 8 17:40:05 2005 ... Most of the files were removed by 'reiserfsck --check device'. besides the journal replay reiserfsck --check does not change anything on the partition, RO checks only. do you have a reiserfs support in the kernel? Sure, one of my data partition is reiserfs: ... [EMAIL PROTECTED]:~ 0$ # debugreiserfs -J /dev/hda7 debugreiserfs 3.6.19 (2003 www.namesys.com) Filesystem state: consistency is not checked after last mounting Reiserfs super block in block 16 on 0x307 of format 3.6 with standard journal Count of blocks on the device: 4393769 ... what if you zero the first 64K with dd conv=notrunc if=/dev/zero of=device bs=4096 count=16 can you mount it now? (rebuild-tree should already complete by the mount time). Hurray, this is the trick! I don't understand why, but I can see hundreds of directories and thousends of files. Thanks a lot!!! do you have anything related in the syslog about the mount time? This is the first time 'dmesg' gives an output: ReiserFS: sdc5: found reiserfs format 3.6 with standard journal ReiserFS: sdc5: using ordered data mode ReiserFS: sdc5: journal params: device sdc5, size 8192, journal first block 18, max trans len 1024, max batch 900, max commit age 30, max trans age 30 ReiserFS: sdc5: checking transaction log (sdc5) ReiserFS: sdc5: Using r5 hash to sort names Could you give me a technical describtion why this worked? the kernel found an ext2 magic somewhere in the first 64K, reiserfs keeps the super block on 64K offset, so ext2 one was not overwritten by rebuild-sb. this is why it was mounted as ext2. but why the kernel refused to mount as reiserfs when was explicitely specified -- this is a bug. -- Thanks, Vitaly Fertman
Re: reiserfs3 rebuild-tree successful but no files
Hello On Thu, 2005-02-10 at 09:54, Christian Placzek wrote: On Wednesday 09 February 2005 13:01, Vladimir Saveliev wrote: Hello On Wed, 2005-02-09 at 12:04, Christian Placzek wrote: On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. can you do debugreiserfs -p -S /dev/shredded | bzip2 -c meta.bz2 Okay, I've done two versions, one with and one without '-S'. I applied the following commands to the image copy (the image itself is untouched, I always worked with fresh copies): # reiserfsck -y /dev/loop/0 --rebuild-sb # reiserfsck -y /dev/loop/0 --check # reiserfsck -y /dev/loop/0 --rebuild-tree # debugreiserfs -p /dev/loop/0 | bzip2 -c meta.bz2 # reiserfsck -y /dev/loop/0 --rebuild-tree -S # debugreiserfs -p /dev/loop/0 | bzip2 -c meta-S.bz2 Use ftp://80.133.138.104:12121 user: marc pw: tukli ok. Lena gave me another hint: Sorry, but what does df -T say? Does it say that reiserfs filesystem is mounted on /mnt/temp1? Thanks, Lena. No, it replied: # /dev/loop/0 ext26952927620 65997368 1% /mnt/temp1 If I force mount with -t reiserfs it says: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro -t reiserfs /dev/loop/0 /mnt/temp1/ mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems Yes, so, were you able to mount the filesystem eventually?
Re: reiserfs3 rebuild-tree successful but no files
On Thursday 10 February 2005 09:50, you wrote: Hello On Thu, 2005-02-10 at 09:54, Christian Placzek wrote: On Wednesday 09 February 2005 13:01, Vladimir Saveliev wrote: Hello On Wed, 2005-02-09 at 12:04, Christian Placzek wrote: On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. can you do debugreiserfs -p -S /dev/shredded | bzip2 -c meta.bz2 Okay, I've done two versions, one with and one without '-S'. I applied the following commands to the image copy (the image itself is untouched, I always worked with fresh copies): # reiserfsck -y /dev/loop/0 --rebuild-sb # reiserfsck -y /dev/loop/0 --check # reiserfsck -y /dev/loop/0 --rebuild-tree # debugreiserfs -p /dev/loop/0 | bzip2 -c meta.bz2 # reiserfsck -y /dev/loop/0 --rebuild-tree -S # debugreiserfs -p /dev/loop/0 | bzip2 -c meta-S.bz2 Use ftp://80.133.138.104:12121 user: marc pw: tukli ok. Lena gave me another hint: Sorry, but what does df -T say? Does it say that reiserfs filesystem is mounted on /mnt/temp1? Thanks, Lena. No, it replied: # /dev/loop/0 ext26952927620 65997368 1% /mnt/temp1 If I force mount with -t reiserfs it says: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro -t reiserfs /dev/loop/0 /mnt/temp1/ mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems Yes, so, were you able to mount the filesystem eventually? No, I wasn't. It seems mount doesn't recognize the true file system, although the magic exists. snip 0001 30 76 0D 01 00 00 00 00 00 00 00 00 12 00 00 00 0v.. 00 00 00 00 00 20 00 00 00 04 00 00 00 00 00 00 . .. 00010020 84 03 00 00 1E 00 00 00 00 00 00 00 00 10 CC 03 00 00 02 00 52 65 49 73 45 72 32 46 73 00 01 00 ReIsEr2Fs... 00010040 00 00 00 00 00 00 1B 02 02 00 00 00 00 00 00 00 00 00 00 00 CF DC 6B 1C 3E 77 48 3C A7 4E 6E 84 ..k.wH.Nn. 00010060 6E 8E E3 EE 00 00 00 00 00 00 00 00 00 00 00 00 n... 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 snip Maybe the following output is the key. I did this with a fresh copy. Note the number before the '$' sign in the command prompt. It's the error status of the previous command. [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck -y /dev/loop/0 --rebuild-sb reiserfsck 3.6.19 (2003 www.namesys.com) * ** If you are using the latest reiserfsprogs and it fails ** ** please email bug reports to reiserfs-list@namesys.com, ** ** providing as much information as possible -- your ** ** hardware, kernel, patches, settings, all reiserfsck ** ** messages (including version), the reiserfsck logfile, ** ** check the syslog file for any related information. ** ** If you would like advice on using this program, support ** ** is available for $25 at www.namesys.com/support.html. ** * Will check superblock and rebuild it if needed Will put log info to 'stdout' reiserfs_open: the reiserfs superblock cannot be found on /dev/loop/0. what the version of ReiserFS do you use[1-4] (1) 3.6.x (2) =3.5.9 (introduced in the middle of 1999) (if you use linux 2.2, choose this one) (3) 3.5.9 converted to new format (don't choose if unsure) (4) 3.5.9 (this is very old format, don't choose if unsure) (X) exit 1 Enter block size [4096]: No journal device was specified. (If journal
Re: reiserfs3 rebuild-tree successful but no files
Hello On Thu, 2005-02-10 at 15:50, Christian Placzek wrote: No, I wasn't. It seems mount doesn't recognize the true file system, although the magic exists. snip 0001 30 76 0D 01 00 00 00 00 00 00 00 00 12 00 00 00 0v.. 00 00 00 00 00 20 00 00 00 04 00 00 00 00 00 00 . .. 00010020 84 03 00 00 1E 00 00 00 00 00 00 00 00 10 CC 03 00 00 02 00 52 65 49 73 45 72 32 46 73 00 01 00 ReIsEr2Fs... 00010040 00 00 00 00 00 00 1B 02 02 00 00 00 00 00 00 00 00 00 00 00 CF DC 6B 1C 3E 77 48 3C A7 4E 6E 84 ..k.wH.Nn. 00010060 6E 8E E3 EE 00 00 00 00 00 00 00 00 00 00 00 00 n... 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 snip Maybe the following output is the key. I did this with a fresh copy. Note the number before the '$' sign in the command prompt. It's the error status of the previous command. Sorry, I am confused. You had to do: dd if=/dev/shreded of=/dev/spare reiserfsck --rebuild-sb /dev/spare reiserfsck --rebuild-tree -S /dev/spare mount /dev/spare /mnt Would you try that and let us know the result? [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck -y /dev/loop/0 --rebuild-sb reiserfsck 3.6.19 (2003 www.namesys.com) * ** If you are using the latest reiserfsprogs and it fails ** ** please email bug reports to reiserfs-list@namesys.com, ** ** providing as much information as possible -- your ** ** hardware, kernel, patches, settings, all reiserfsck ** ** messages (including version), the reiserfsck logfile, ** ** check the syslog file for any related information. ** ** If you would like advice on using this program, support ** ** is available for $25 at www.namesys.com/support.html. ** * Will check superblock and rebuild it if needed Will put log info to 'stdout' reiserfs_open: the reiserfs superblock cannot be found on /dev/loop/0. what the version of ReiserFS do you use[1-4] (1) 3.6.x (2) =3.5.9 (introduced in the middle of 1999) (if you use linux 2.2, choose this one) (3) 3.5.9 converted to new format (don't choose if unsure) (4) 3.5.9 (this is very old format, don't choose if unsure) (X) exit 1 Enter block size [4096]: No journal device was specified. (If journal is not available, re-run with --no-journal-available option specified). Is journal default? (y/n)[y]: Did you use resizer(y/n)[n]: rebuild-sb: no uuid found, a new uuid was generated (cfdc6b1c-3e77-483c-a74e-6e846e8ee3ee) rebuild-sb: You either have a corrupted journal or have just changed the start of the partition with some partition table editor. If you are sure that the start of the partition is ok, rebuild the journal header. Do you want to rebuild the journal header? (y/n)[n]: y Reiserfs super block in block 16 on 0x700 of format 3.6 with standard journal Count of blocks on the device: 17659440 Number of bitmaps: 539 Blocksize: 4096 Free blocks (count of blocks - used [journal, bitmaps, data, reserved] blocks): 0 Root block: 0 Filesystem is NOT clean Tree height: 0 Hash function used to sort names: not set Objectid map size 0, max 972 Journal parameters: Device [0x0] Magic [0x0] Size 8193 blocks (including 1 for journal header) (first block 18) Max transaction length 1024 blocks Max batch size 900 blocks Max commit age 30 Blocks reserved by journal: 0 Fs state field: 0x1: some corruptions exist. sb_version: 2 inode generation number: 0 UUID: cfdc6b1c-3e77-483c-a74e-6e846e8ee3ee LABEL: Set flags in SB: Is this ok ? (y/n)[n]: y The fs may still be unconsistent. Run reiserfsck --check. [EMAIL PROTECTED]:/home/kris 1$ # reiserfsck -y /dev/loop/0 --check reiserfsck 3.6.19 (2003 www.namesys.com) * ** If you are using the latest reiserfsprogs and it fails ** ** please email bug reports to reiserfs-list@namesys.com, ** ** providing as much information as possible -- your ** ** hardware, kernel, patches, settings, all reiserfsck ** ** messages (including version), the reiserfsck logfile, ** ** check the syslog file for any related information. ** ** If you would like advice on using this program, support ** ** is available for $25 at www.namesys.com/support.html. ** * Will read-only check consistency of the filesystem on /dev/loop/0 Will put log info to 'stdout' ### reiserfsck --check started at Thu Feb 10 13:16:29 2005 ### Replaying journal.. Reiserfs journal '/dev/loop/0' in blocks [18..8211]: 0 transactions replayed Zero bit found in on-disk bitmap after the last
Re: reiserfs3 rebuild-tree successful but no files
On Thursday 10 February 2005 15:09, you wrote: Hello. Christian Placzek wrote: On Wednesday 09 February 2005 13:01, Vladimir Saveliev wrote: Hello On Wed, 2005-02-09 at 12:04, Christian Placzek wrote: On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. can you do debugreiserfs -p -S /dev/shredded | bzip2 -c meta.bz2 Okay, I've done two versions, one with and one without '-S'. I applied the following commands to the image copy (the image itself is untouched, I always worked with fresh copies): # reiserfsck -y /dev/loop/0 --rebuild-sb # reiserfsck -y /dev/loop/0 --check # reiserfsck -y /dev/loop/0 --rebuild-tree Sorry, do I understand correctly that you tried to mount /dev/loop/0 with -t reiserfs option after __this__ reiserfsck --rebuild-tree? Not after the following ones? Let me explain my mode of operation: I make a copy of the original image taken of the harddrive. Then I use 'losetup' or 'mount -o loop' in order to mount the image as device. Next I perform different operations using 'reiserfsck'. Above you see _one_ possiblity. Then I mount the image as filesystem using 'mount -o ro /dev/loop/0 /mnt/temp1/', and, as I described below, I get no directories or files. Mounting with '-t reiserfs' always result in following output: mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems What kernel do you use? 2.6.10-gentoo-r6 Thanks, Lena. # debugreiserfs -p /dev/loop/0 | bzip2 -c meta.bz2 # reiserfsck -y /dev/loop/0 --rebuild-tree -S # debugreiserfs -p /dev/loop/0 | bzip2 -c meta-S.bz2 Use ftp://80.133.138.104:12121 user: marc pw: tukli Lena gave me another hint: Sorry, but what does df -T say? Does it say that reiserfs filesystem is mounted on /mnt/temp1? Thanks, Lena. No, it replied: # /dev/loop/0 ext26952927620 65997368 1% /mnt/temp1 If I force mount with -t reiserfs it says: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro -t reiserfs /dev/loop/0 /mnt/temp1/ mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems Thanks, this is a good hint, but I don't know how to change the identifier of the filesystem. I know that normally mkfs.* does this task, but my friend's overwriting of the superblock probably has changed the identifier of the filesystem. Is it possible to apply mkreiserfs on the image whithout running the risk to lose any data? Thanks Kris and let us to download meta.bz2 so that we can take a look why lost+found gets emptied. I mounted the image after each operation, but all I can see is: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro /dev/loop/0 /mnt/temp1/ [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/ total 21 drwxr-xr-x 3 root root 4096 Jan 20 11:36 . drwxr-xr-x 39 root root 968 Feb 6 14:12 .. drwx-- 2 root root 16384 Jan 20 11:36 lost+found [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/lost+found/ total 20 drwx-- 2 root root 16384 Jan 20 11:36 . drwxr-xr-x 3 root root 4096 Jan 20 11:36 .. [EMAIL PROTECTED]:/home/kris 0$ # Do you have any suggestions how to rescue the data? Regards Kris Here you see a typical output: [EMAIL PROTECTED]:/home/kris 0$ # losetup /dev/loop/0 /mnt/temp/data.x.dd [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck /dev/loop/0 --rebuild-tree reiserfsck 3.6.19 (2003 www.namesys.com) snip Will rebuild the filesystem (/dev/loop/0) tree 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: the reiserfs superblock cannot be found on /dev/loop/0. Failed to open the filesystem. If
Re: reiserfs3 rebuild-tree successful but no files
On Thursday 10 February 2005 18:02, Christian Placzek wrote: On Thursday 10 February 2005 15:09, you wrote: Hello. Christian Placzek wrote: On Wednesday 09 February 2005 13:01, Vladimir Saveliev wrote: Hello On Wed, 2005-02-09 at 12:04, Christian Placzek wrote: On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. can you do debugreiserfs -p -S /dev/shredded | bzip2 -c meta.bz2 Okay, I've done two versions, one with and one without '-S'. I applied the following commands to the image copy (the image itself is untouched, I always worked with fresh copies): # reiserfsck -y /dev/loop/0 --rebuild-sb # reiserfsck -y /dev/loop/0 --check # reiserfsck -y /dev/loop/0 --rebuild-tree Sorry, do I understand correctly that you tried to mount /dev/loop/0 with -t reiserfs option after __this__ reiserfsck --rebuild-tree? Not after the following ones? Let me explain my mode of operation: I make a copy of the original image taken of the harddrive. Then I use 'losetup' or 'mount -o loop' in order to mount the image as device. Next I perform different operations using 'reiserfsck'. Above you see _one_ possiblity. Then I mount the image as filesystem using 'mount -o ro /dev/loop/0 /mnt/temp1/', and, as I described below, I get no directories or files. Mounting with '-t reiserfs' always result in following output: mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems after rebuilding the tree, does 'reiserfsck --check device' see these files? do you have a reiserfs support in the kernel? what if you zero the first 64K with dd conv=notrunc if=/dev/zero of=device bs=4096 count=16 can you mount it now? (rebuild-tree should already complete by the mount time). do you have anything related in the syslog about the mount time? -- Thanks, Vitaly Fertman
Re: reiserfs3 rebuild-tree successful but no files
Okay, I've done two versions, one with and one without '-S'. I applied the following commands to the image copy (the image itself is untouched, I always worked with fresh copies): # reiserfsck -y /dev/loop/0 --rebuild-sb # reiserfsck -y /dev/loop/0 --check # reiserfsck -y /dev/loop/0 --rebuild-tree # debugreiserfs -p /dev/loop/0 | bzip2 -c meta.bz2 # reiserfsck -y /dev/loop/0 --rebuild-tree -S # debugreiserfs -p /dev/loop/0 | bzip2 -c meta-S.bz2 Use ftp://80.133.138.104:12121 sorry, but I get 'no route to host' every time. -- Thanks, Vitaly Fertman
Re: reiserfs3 rebuild-tree successful but no files
On Thursday 10 February 2005 16:25, you wrote: On Thursday 10 February 2005 18:02, Christian Placzek wrote: On Thursday 10 February 2005 15:09, you wrote: Hello. Christian Placzek wrote: On Wednesday 09 February 2005 13:01, Vladimir Saveliev wrote: Hello On Wed, 2005-02-09 at 12:04, Christian Placzek wrote: On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. can you do debugreiserfs -p -S /dev/shredded | bzip2 -c meta.bz2 Okay, I've done two versions, one with and one without '-S'. I applied the following commands to the image copy (the image itself is untouched, I always worked with fresh copies): # reiserfsck -y /dev/loop/0 --rebuild-sb # reiserfsck -y /dev/loop/0 --check # reiserfsck -y /dev/loop/0 --rebuild-tree Sorry, do I understand correctly that you tried to mount /dev/loop/0 with -t reiserfs option after __this__ reiserfsck --rebuild-tree? Not after the following ones? Let me explain my mode of operation: I make a copy of the original image taken of the harddrive. Then I use 'losetup' or 'mount -o loop' in order to mount the image as device. Next I perform different operations using 'reiserfsck'. Above you see _one_ possiblity. Then I mount the image as filesystem using 'mount -o ro /dev/loop/0 /mnt/temp1/', and, as I described below, I get no directories or files. Mounting with '-t reiserfs' always result in following output: mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems after rebuilding the tree, does 'reiserfsck --check device' see these files? Yes, see my original email from 08.02.2005 23:21. The original output has a length of about 13000 lines. A extract looks like this: ... rebuild_semantic_pass: The entry [741258 1025777] (www.firstname.de.ico) in directory [296134 741258] points to nowhere - is removed rewrite_file: 2 items of file [741258 1041142] moved to [741258 93475] The entry [741258 1041142] (deltab.de.ico) in directory [296134 741258] updated to point to [741258 93475] rewrite_file: 2 items of file [741258 1041137] moved to [741258 93569] The entry [741258 1041137] (www.bild.t-online.de.ico) in directory [296134 741258] updated to point to [741258 93569] ... The last lines: ... Flushing..finished Objects without names 18403 Empty lost dirs removed 384 Dirs linked to /lost+found: 2174 Dirs without stat data found 83 Files linked to /lost+found 16229 Objects having used objectids: 49 files fixed 47 dirs fixed 2 Pass 4 - finished done 1476, 37 /sec Deleted unreachable items 716 Flushing..finished Syncing..finished ### reiserfsck finished at Tue Feb 8 17:40:05 2005 ... Most of the files were removed by 'reiserfsck --check device'. do you have a reiserfs support in the kernel? Sure, one of my data partition is reiserfs: ... [EMAIL PROTECTED]:~ 0$ # debugreiserfs -J /dev/hda7 debugreiserfs 3.6.19 (2003 www.namesys.com) Filesystem state: consistency is not checked after last mounting Reiserfs super block in block 16 on 0x307 of format 3.6 with standard journal Count of blocks on the device: 4393769 ... what if you zero the first 64K with dd conv=notrunc if=/dev/zero of=device bs=4096 count=16 can you mount it now? (rebuild-tree should already complete by the mount time). Hurray, this is the trick! I don't understand why, but I can see hundreds of directories and thousends of files. Thanks a lot!!! do you have anything related in the syslog about the mount time? This is the first time
Re: reiserfs3 rebuild-tree successful but no files - SOLVED
On Thursday 10 February 2005 16:25, you wrote: On Thursday 10 February 2005 18:02, Christian Placzek wrote: On Thursday 10 February 2005 15:09, you wrote: Hello. Christian Placzek wrote: On Wednesday 09 February 2005 13:01, Vladimir Saveliev wrote: Hello On Wed, 2005-02-09 at 12:04, Christian Placzek wrote: On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. can you do debugreiserfs -p -S /dev/shredded | bzip2 -c meta.bz2 Okay, I've done two versions, one with and one without '-S'. I applied the following commands to the image copy (the image itself is untouched, I always worked with fresh copies): # reiserfsck -y /dev/loop/0 --rebuild-sb # reiserfsck -y /dev/loop/0 --check # reiserfsck -y /dev/loop/0 --rebuild-tree Sorry, do I understand correctly that you tried to mount /dev/loop/0 with -t reiserfs option after __this__ reiserfsck --rebuild-tree? Not after the following ones? Let me explain my mode of operation: I make a copy of the original image taken of the harddrive. Then I use 'losetup' or 'mount -o loop' in order to mount the image as device. Next I perform different operations using 'reiserfsck'. Above you see _one_ possiblity. Then I mount the image as filesystem using 'mount -o ro /dev/loop/0 /mnt/temp1/', and, as I described below, I get no directories or files. Mounting with '-t reiserfs' always result in following output: mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems after rebuilding the tree, does 'reiserfsck --check device' see these files? Yes, see my original email from 08.02.2005 23:21. The original output has a length of about 13000 lines. A extract looks like this: ... rebuild_semantic_pass: The entry [741258 1025777] (www.firstname.de.ico) in directory [296134 741258] points to nowhere - is removed rewrite_file: 2 items of file [741258 1041142] moved to [741258 93475] The entry [741258 1041142] (deltab.de.ico) in directory [296134 741258] updated to point to [741258 93475] rewrite_file: 2 items of file [741258 1041137] moved to [741258 93569] The entry [741258 1041137] (www.bild.t-online.de.ico) in directory [296134 741258] updated to point to [741258 93569] ... The last lines: ... Flushing..finished Objects without names 18403 Empty lost dirs removed 384 Dirs linked to /lost+found: 2174 Dirs without stat data found 83 Files linked to /lost+found 16229 Objects having used objectids: 49 files fixed 47 dirs fixed 2 Pass 4 - finished done 1476, 37 /sec Deleted unreachable items 716 Flushing..finished Syncing..finished ### reiserfsck finished at Tue Feb 8 17:40:05 2005 ... Most of the files were removed by 'reiserfsck --check device'. do you have a reiserfs support in the kernel? Sure, one of my data partition is reiserfs: ... [EMAIL PROTECTED]:~ 0$ # debugreiserfs -J /dev/hda7 debugreiserfs 3.6.19 (2003 www.namesys.com) Filesystem state: consistency is not checked after last mounting Reiserfs super block in block 16 on 0x307 of format 3.6 with standard journal Count of blocks on the device: 4393769 ... what if you zero the first 64K with dd conv=notrunc if=/dev/zero of=device bs=4096 count=16 can you mount it now? (rebuild-tree should already complete by the mount time). Hurray, this is the trick! I don't understand why, but I can see hundreds of directories and thousends of files. Thanks a lot!!! do you have anything related in the syslog about the mount time? This is the first time 'dmesg'
Re: reiserfs3 rebuild-tree successful but no files
On Thursday 10 February 2005 15:52, you wrote: Hello On Thu, 2005-02-10 at 15:50, Christian Placzek wrote: No, I wasn't. It seems mount doesn't recognize the true file system, although the magic exists. snip 0001 30 76 0D 01 00 00 00 00 00 00 00 00 12 00 00 00 0v.. 00 00 00 00 00 20 00 00 00 04 00 00 00 00 00 00 . .. 00010020 84 03 00 00 1E 00 00 00 00 00 00 00 00 10 CC 03 00 00 02 00 52 65 49 73 45 72 32 46 73 00 01 00 ReIsEr2Fs... 00010040 00 00 00 00 00 00 1B 02 02 00 00 00 00 00 00 00 00 00 00 00 CF DC 6B 1C 3E 77 48 3C A7 4E 6E 84 ..k.wH.Nn. 00010060 6E 8E E3 EE 00 00 00 00 00 00 00 00 00 00 00 00 n... 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 snip Maybe the following output is the key. I did this with a fresh copy. Note the number before the '$' sign in the command prompt. It's the error status of the previous command. Sorry, I am confused. You had to do: dd if=/dev/shreded of=/dev/spare reiserfsck --rebuild-sb /dev/spare reiserfsck --rebuild-tree -S /dev/spare mount /dev/spare /mnt Okay, done. No output of 'mount' in 'dmesg'. Would you try that and let us know the result? Here it is, but not in full length (28000 lines): [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck --rebuild-sb /dev/sdc5 reiserfsck 3.6.19 (2003 www.namesys.com) * ** If you are using the latest reiserfsprogs and it fails ** ** please email bug reports to reiserfs-list@namesys.com, ** ** providing as much information as possible -- your ** ** hardware, kernel, patches, settings, all reiserfsck ** ** messages (including version), the reiserfsck logfile, ** ** check the syslog file for any related information. ** ** If you would like advice on using this program, support ** ** is available for $25 at www.namesys.com/support.html. ** * Will check superblock and rebuild it if needed 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: the reiserfs superblock cannot be found on /dev/sdc5. what the version of ReiserFS do you use[1-4] (1) 3.6.x (2) =3.5.9 (introduced in the middle of 1999) (if you use linux 2.2, choose this one) (3) 3.5.9 converted to new format (don't choose if unsure) (4) 3.5.9 (this is very old format, don't choose if unsure) (X) exit 1 Enter block size [4096]: No journal device was specified. (If journal is not available, re-run with --no-journal-available option specified). Is journal default? (y/n)[y]: Did you use resizer(y/n)[n]: rebuild-sb: no uuid found, a new uuid was generated (bff1c11a-ba70-4f9e-851d-a81d10b388b9) rebuild-sb: You either have a corrupted journal or have just changed the start of the partition with some partition table editor. If you are sure that the start of the partition is ok, rebuild the journal header. Do you want to rebuild the journal header? (y/n)[n]: y Reiserfs super block in block 16 on 0x825 of format 3.6 with standard journal Count of blocks on the device: 27453056 Number of bitmaps: 838 Blocksize: 4096 Free blocks (count of blocks - used [journal, bitmaps, data, reserved] blocks): 0 Root block: 0 Filesystem is NOT clean Tree height: 0 Hash function used to sort names: not set Objectid map size 0, max 972 Journal parameters: Device [0x0] Magic [0x0] Size 8193 blocks (including 1 for journal header) (first block 18) Max transaction length 1024 blocks Max batch size 900 blocks Max commit age 30 Blocks reserved by journal: 0 Fs state field: 0x1: some corruptions exist. sb_version: 2 inode generation number: 0 UUID: bff1c11a-ba70-4f9e-851d-a81d10b388b9 LABEL: Set flags in SB: Is this ok ? (y/n)[n]: y The fs may still be unconsistent. Run reiserfsck --check. [EMAIL PROTECTED]:/home/kris 1$ # reiserfsck --rebuild-tree -S /dev/sdc5 reiserfsck 3.6.19 (2003 www.namesys.com) * ** Do not run the program with --rebuild-tree unless ** ** something is broken and MAKE A BACKUP before using it. ** ** If you have bad sectors on a drive it is usually a bad ** ** idea to continue using it. Then you probably should get ** ** a working hard drive, copy the file system from the bad ** ** drive to the good one -- dd_rescue is a good tool for ** ** that -- and only then run this program. ** ** If you are using the latest reiserfsprogs and it fails ** ** please email bug reports to reiserfs-list@namesys.com, ** ** providing as much information as possible -- your ** ** hardware, kernel, patches, settings, all reiserfsck ** ** messages (including version), the reiserfsck logfile, ** ** check the syslog file for
Re: reiserfs3 rebuild-tree successful but no files - SOLVED
Hello On Fri, 2005-02-11 at 10:38, Christian Placzek wrote: On Thursday 10 February 2005 16:25, you wrote: On Thursday 10 February 2005 18:02, Christian Placzek wrote: what if you zero the first 64K with dd conv=notrunc if=/dev/zero of=device bs=4096 count=16 can you mount it now? (rebuild-tree should already complete by the mount time). Hurray, this is the trick! I don't understand why, but I can see hundreds of directories and thousends of files. Thanks a lot!!! do you have anything related in the syslog about the mount time? This is the first time 'dmesg' gives an output: ReiserFS: sdc5: found reiserfs format 3.6 with standard journal ReiserFS: sdc5: using ordered data mode ReiserFS: sdc5: journal params: device sdc5, size 8192, journal first block 18, max trans len 1024, max batch 900, max commit age 30, max trans age 30 ReiserFS: sdc5: checking transaction log (sdc5) ReiserFS: sdc5: Using r5 hash to sort names Could you give me a technical describtion why this worked? am I correct that mount /dev/sdc5 /mnt mounted it as ext mount /dev/sdc5 /mnt -t reiserfs refused to mount with mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems and after dd conv=notrunc if=/dev/zero of=/dev/sdc5 bs=4096 count=16 mount /dev/sdc5 /mnt mounts reiserfs? Again, thank you very much! Kris
Re: reiserfs3 rebuild-tree successful but no files
Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Did you look at lost+found? I mounted the image after each operation, but all I can see is: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro /dev/loop/0 /mnt/temp1/ [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/ total 21 drwxr-xr-x 3 root root 4096 Jan 20 11:36 . drwxr-xr-x 39 root root 968 Feb 6 14:12 .. drwx-- 2 root root 16384 Jan 20 11:36 lost+found [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/lost+found/ total 20 drwx-- 2 root root 16384 Jan 20 11:36 . drwxr-xr-x 3 root root 4096 Jan 20 11:36 .. [EMAIL PROTECTED]:/home/kris 0$ # Do you have any suggestions how to rescue the data? Regards Kris Here you see a typical output: [EMAIL PROTECTED]:/home/kris 0$ # losetup /dev/loop/0 /mnt/temp/data.x.dd [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck /dev/loop/0 --rebuild-tree reiserfsck 3.6.19 (2003 www.namesys.com) snip Will rebuild the filesystem (/dev/loop/0) tree 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: the reiserfs superblock cannot be found on /dev/loop/0. Failed to open the filesystem. If the partition table has not been changed, and the partition is valid and it really contains a reiserfs partition, then the superblock is corrupted and you need to run this utility with --rebuild-sb. [EMAIL PROTECTED]:/home/kris 8$ # reiserfsck /dev/loop/0 --rebuild-sb reiserfsck 3.6.19 (2003 www.namesys.com) snip Will check superblock and rebuild it if needed Will put log info to 'stdout' reiserfs_open: the reiserfs superblock cannot be found on /dev/loop/0. what the version of ReiserFS do you use[1-4] (1) 3.6.x (2) =3.5.9 (introduced in the middle of 1999) (if you use linux 2.2, choose this one) (3) 3.5.9 converted to new format (don't choose if unsure) (4) 3.5.9 (this is very old format, don't choose if unsure) (X) exit 1 Enter block size [4096]: No journal device was specified. (If journal is not available, re-run with --no-journal-available option specified). Is journal default? (y/n)[y]: Did you use resizer(y/n)[n]: rebuild-sb: no uuid found, a new uuid was generated (7e253707-4fef-42aa-9785-b1cd079851af) rebuild-sb: You either have a corrupted journal or have just changed the start of the partition with some partition table editor. If you are sure that the start of the partition is ok, rebuild the journal header. Do you want to rebuild the journal header? (y/n)[n]: y Reiserfs super block in block 16 on 0x700 of format 3.6 with standard journal Count of blocks on the device: 17659440 Number of bitmaps: 539 Blocksize: 4096 Free blocks (count of blocks - used [journal, bitmaps, data, reserved] blocks): 0 Root block: 0 Filesystem is NOT clean Tree height: 0 Hash function used to sort names: not set Objectid map size 0, max 972 Journal parameters: Device [0x0] Magic [0x0] Size 8193 blocks (including 1 for journal header) (first block 18) Max transaction length 1024 blocks Max batch size 900 blocks Max commit age 30 Blocks reserved by journal: 0 Fs state field: 0x1: some corruptions exist. sb_version: 2 inode generation number: 0 UUID: 7e253707-4fef-42aa-9785-b1cd079851af LABEL: Set flags in SB: Is this ok ? (y/n)[n]: y The fs may still be unconsistent. Run reiserfsck --check. [EMAIL PROTECTED]:/home/kris 1$ # reiserfsck /dev/loop/0 --check reiserfsck 3.6.19 (2003 www.namesys.com) snip Will read-only check consistency of the filesystem on /dev/loop/0 Will put log info to 'stdout' ### reiserfsck --check started at Tue Feb 8 17:17:31 2005 ### Replaying journal.. Reiserfs journal '/dev/loop/0' in blocks [18..8211]: 0 transactions replayed Zero bit found in on-disk bitmap after the last valid bit. Checking internal tree..
Re: reiserfs3 rebuild-tree successful but no files
On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. I mounted the image after each operation, but all I can see is: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro /dev/loop/0 /mnt/temp1/ [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/ total 21 drwxr-xr-x 3 root root 4096 Jan 20 11:36 . drwxr-xr-x 39 root root 968 Feb 6 14:12 .. drwx-- 2 root root 16384 Jan 20 11:36 lost+found [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/lost+found/ total 20 drwx-- 2 root root 16384 Jan 20 11:36 . drwxr-xr-x 3 root root 4096 Jan 20 11:36 .. [EMAIL PROTECTED]:/home/kris 0$ # Do you have any suggestions how to rescue the data? Regards Kris Here you see a typical output: [EMAIL PROTECTED]:/home/kris 0$ # losetup /dev/loop/0 /mnt/temp/data.x.dd [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck /dev/loop/0 --rebuild-tree reiserfsck 3.6.19 (2003 www.namesys.com) snip Will rebuild the filesystem (/dev/loop/0) tree 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: the reiserfs superblock cannot be found on /dev/loop/0. Failed to open the filesystem. If the partition table has not been changed, and the partition is valid and it really contains a reiserfs partition, then the superblock is corrupted and you need to run this utility with --rebuild-sb. [EMAIL PROTECTED]:/home/kris 8$ # reiserfsck /dev/loop/0 --rebuild-sb reiserfsck 3.6.19 (2003 www.namesys.com) snip Will check superblock and rebuild it if needed Will put log info to 'stdout' reiserfs_open: the reiserfs superblock cannot be found on /dev/loop/0. what the version of ReiserFS do you use[1-4] (1) 3.6.x (2) =3.5.9 (introduced in the middle of 1999) (if you use linux 2.2, choose this one) (3) 3.5.9 converted to new format (don't choose if unsure) (4) 3.5.9 (this is very old format, don't choose if unsure) (X) exit 1 Enter block size [4096]: No journal device was specified. (If journal is not available, re-run with --no-journal-available option specified). Is journal default? (y/n)[y]: Did you use resizer(y/n)[n]: rebuild-sb: no uuid found, a new uuid was generated (7e253707-4fef-42aa-9785-b1cd079851af) rebuild-sb: You either have a corrupted journal or have just changed the start of the partition with some partition table editor. If you are sure that the start of the partition is ok, rebuild the journal header. Do you want to rebuild the journal header? (y/n)[n]: y Reiserfs super block in block 16 on 0x700 of format 3.6 with standard journal Count of blocks on the device: 17659440 Number of bitmaps: 539 Blocksize: 4096 Free blocks (count of blocks - used [journal, bitmaps, data, reserved] blocks): 0 Root block: 0 Filesystem is NOT clean Tree height: 0 Hash function used to sort names: not set Objectid map size 0, max 972 Journal parameters: Device [0x0] Magic [0x0] Size 8193 blocks (including 1 for journal header) (first block 18) Max transaction length 1024 blocks Max batch size 900 blocks Max commit age 30 Blocks reserved by journal: 0 Fs state field: 0x1: some corruptions exist. sb_version: 2 inode generation number: 0 UUID: 7e253707-4fef-42aa-9785-b1cd079851af LABEL: Set flags in SB: Is this ok ? (y/n)[n]: y The fs may still be unconsistent. Run reiserfsck --check. [EMAIL PROTECTED]:/home/kris 1$ # reiserfsck /dev/loop/0 --check reiserfsck 3.6.19 (2003 www.namesys.com) snip Will read-only check consistency of the filesystem on /dev/loop/0 Will put
Re: reiserfs3 rebuild-tree successful but no files
On Wednesday 09 February 2005 10:34, you wrote: Christian Placzek wrote: On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. Sorry, but what does df -T say? Does it say that reiserfs filesystem is mounted on /mnt/temp1? No, it replied: # /dev/loop/0 ext26952927620 65997368 1% /mnt/temp1 If I force mount with -t reiserfs it says: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro -t reiserfs /dev/loop/0 /mnt/temp1/ mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems Thanks, this is a good hint, but I don't know how to change the identifier of the filesystem. I know that normally mkfs.* does this task, but my friend's overwriting of the superblock probably has changed the identifier of the filesystem. Is it possible to apply mkreiserfs on the image whithout running the risk to lose any data? Thanks Kris Thanks, Lena. I mounted the image after each operation, but all I can see is: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro /dev/loop/0 /mnt/temp1/ [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/ total 21 drwxr-xr-x 3 root root 4096 Jan 20 11:36 . drwxr-xr-x 39 root root 968 Feb 6 14:12 .. drwx-- 2 root root 16384 Jan 20 11:36 lost+found [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/lost+found/ total 20 drwx-- 2 root root 16384 Jan 20 11:36 . drwxr-xr-x 3 root root 4096 Jan 20 11:36 .. [EMAIL PROTECTED]:/home/kris 0$ # Do you have any suggestions how to rescue the data? Regards Kris Here you see a typical output: [EMAIL PROTECTED]:/home/kris 0$ # losetup /dev/loop/0 /mnt/temp/data.x.dd [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck /dev/loop/0 --rebuild-tree reiserfsck 3.6.19 (2003 www.namesys.com) snip Will rebuild the filesystem (/dev/loop/0) tree 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: the reiserfs superblock cannot be found on /dev/loop/0. Failed to open the filesystem. If the partition table has not been changed, and the partition is valid and it really contains a reiserfs partition, then the superblock is corrupted and you need to run this utility with --rebuild-sb. [EMAIL PROTECTED]:/home/kris 8$ # reiserfsck /dev/loop/0 --rebuild-sb reiserfsck 3.6.19 (2003 www.namesys.com) snip Will check superblock and rebuild it if needed Will put log info to 'stdout' reiserfs_open: the reiserfs superblock cannot be found on /dev/loop/0. what the version of ReiserFS do you use[1-4] (1) 3.6.x (2) =3.5.9 (introduced in the middle of 1999) (if you use linux 2.2, choose this one) (3) 3.5.9 converted to new format (don't choose if unsure) (4) 3.5.9 (this is very old format, don't choose if unsure) (X) exit 1 Enter block size [4096]: No journal device was specified. (If journal is not available, re-run with --no-journal-available option specified). Is journal default? (y/n)[y]: Did you use resizer(y/n)[n]: rebuild-sb: no uuid found, a new uuid was generated (7e253707-4fef-42aa-9785-b1cd079851af) rebuild-sb: You either have a corrupted journal or have just changed the start of the partition with some partition table editor. If you are sure that the start of the partition is ok, rebuild the journal header. Do you want to rebuild the journal header? (y/n)[n]: y Reiserfs super block in block 16 on 0x700 of format 3.6 with standard journal Count of blocks on the device: 17659440 Number of bitmaps: 539 Blocksize: 4096 Free blocks (count of blocks - used [journal, bitmaps, data, reserved] blocks): 0 Root block: 0 Filesystem is NOT clean Tree height: 0 Hash function used to
Re: reiserfs3 rebuild-tree successful but no files
Hello On Wed, 2005-02-09 at 12:04, Christian Placzek wrote: On Wednesday 09 February 2005 09:47, you wrote: Hello On Wed, 2005-02-09 at 01:21, Christian Placzek wrote: Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... have you tried reiserfsck --rebuild-tree -S ? If not, run it on newly created copy of shredded device. Yes, I did. The output of reiserfsck --rebuild-tree gave other numbers of linked directories/files. But I can't see them. Did you look at lost+found? Shure, see below. can you do debugreiserfs -p -S /dev/shredded | bzip2 -c meta.bz2 and let us to download meta.bz2 so that we can take a look why lost+found gets emptied. I mounted the image after each operation, but all I can see is: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro /dev/loop/0 /mnt/temp1/ [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/ total 21 drwxr-xr-x 3 root root 4096 Jan 20 11:36 . drwxr-xr-x 39 root root 968 Feb 6 14:12 .. drwx-- 2 root root 16384 Jan 20 11:36 lost+found [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/lost+found/ total 20 drwx-- 2 root root 16384 Jan 20 11:36 . drwxr-xr-x 3 root root 4096 Jan 20 11:36 .. [EMAIL PROTECTED]:/home/kris 0$ # Do you have any suggestions how to rescue the data? Regards Kris Here you see a typical output: [EMAIL PROTECTED]:/home/kris 0$ # losetup /dev/loop/0 /mnt/temp/data.x.dd [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck /dev/loop/0 --rebuild-tree reiserfsck 3.6.19 (2003 www.namesys.com) snip Will rebuild the filesystem (/dev/loop/0) tree 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: the reiserfs superblock cannot be found on /dev/loop/0. Failed to open the filesystem. If the partition table has not been changed, and the partition is valid and it really contains a reiserfs partition, then the superblock is corrupted and you need to run this utility with --rebuild-sb. [EMAIL PROTECTED]:/home/kris 8$ # reiserfsck /dev/loop/0 --rebuild-sb reiserfsck 3.6.19 (2003 www.namesys.com) snip Will check superblock and rebuild it if needed Will put log info to 'stdout' reiserfs_open: the reiserfs superblock cannot be found on /dev/loop/0. what the version of ReiserFS do you use[1-4] (1) 3.6.x (2) =3.5.9 (introduced in the middle of 1999) (if you use linux 2.2, choose this one) (3) 3.5.9 converted to new format (don't choose if unsure) (4) 3.5.9 (this is very old format, don't choose if unsure) (X) exit 1 Enter block size [4096]: No journal device was specified. (If journal is not available, re-run with --no-journal-available option specified). Is journal default? (y/n)[y]: Did you use resizer(y/n)[n]: rebuild-sb: no uuid found, a new uuid was generated (7e253707-4fef-42aa-9785-b1cd079851af) rebuild-sb: You either have a corrupted journal or have just changed the start of the partition with some partition table editor. If you are sure that the start of the partition is ok, rebuild the journal header. Do you want to rebuild the journal header? (y/n)[n]: y Reiserfs super block in block 16 on 0x700 of format 3.6 with standard journal Count of blocks on the device: 17659440 Number of bitmaps: 539 Blocksize: 4096 Free blocks (count of blocks - used [journal, bitmaps, data, reserved] blocks): 0 Root block: 0 Filesystem is NOT clean Tree height: 0 Hash function used to sort names: not set Objectid map size 0, max 972 Journal parameters: Device [0x0] Magic [0x0] Size 8193 blocks (including 1 for journal header) (first block 18) Max transaction length 1024 blocks Max batch size 900 blocks Max commit age 30 Blocks reserved by journal: 0 Fs state field: 0x1: some corruptions exist. sb_version: 2 inode generation number: 0
Re: reiserfs3 rebuild-tree successful but no files
Hello On Wed, 2005-02-09 at 14:56, Christian Placzek wrote: On Wednesday 09 February 2005 10:34, you wrote: Sorry, but what does df -T say? Does it say that reiserfs filesystem is mounted on /mnt/temp1? No, it replied: # /dev/loop/0 ext26952927620 65997368 1% /mnt/temp1 If I force mount with -t reiserfs it says: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro -t reiserfs /dev/loop/0 /mnt/temp1/ mount: wrong fs type, bad option, bad superblock on /dev/loop/0, or too many mounted file systems what does dmesg say after mount attempt? Thanks, this is a good hint, but I don't know how to change the identifier of the filesystem. I know that normally mkfs.* does this task, but my friend's overwriting of the superblock probably has changed the identifier of the filesystem. Is it possible to apply mkreiserfs on the image whithout running the risk to lose any data?
reiserfs3 rebuild-tree successful but no files
Hello, a friend of mine shredded his data (70GB) when he tried to undelete an accidentally deleted file. He normally works with windoze. Therefore he didn't know he couldn't undelete a file on a reiserfs partition with ext2 undelete tool %-( When he called me it was already too late. He had overwritten the superblock :-( I'm still trying to rescue the data. I can see them in the image using grep or hexedit. But nothing I tried has been successful. My first steps were unmounting the partition, taking an image and working with a copy of this image using a loop back device. All files have been retrieved but were removed by reiserfsck --check although the last output says that directories and files have been linked (see below). I tried with many combinations nearly all parameters of reiserfsck: --fix-fixable --no-journal-available -S ... I mounted the image after each operation, but all I can see is: [EMAIL PROTECTED]:/home/kris 0$ # mount -o ro /dev/loop/0 /mnt/temp1/ [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/ total 21 drwxr-xr-x 3 root root 4096 Jan 20 11:36 . drwxr-xr-x 39 root root 968 Feb 6 14:12 .. drwx-- 2 root root 16384 Jan 20 11:36 lost+found [EMAIL PROTECTED]:/home/kris 0$ # ls -la /mnt/temp1/lost+found/ total 20 drwx-- 2 root root 16384 Jan 20 11:36 . drwxr-xr-x 3 root root 4096 Jan 20 11:36 .. [EMAIL PROTECTED]:/home/kris 0$ # Do you have any suggestions how to rescue the data? Regards Kris Here you see a typical output: [EMAIL PROTECTED]:/home/kris 0$ # losetup /dev/loop/0 /mnt/temp/data.x.dd [EMAIL PROTECTED]:/home/kris 0$ # reiserfsck /dev/loop/0 --rebuild-tree reiserfsck 3.6.19 (2003 www.namesys.com) snip Will rebuild the filesystem (/dev/loop/0) tree 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: the reiserfs superblock cannot be found on /dev/loop/0. Failed to open the filesystem. If the partition table has not been changed, and the partition is valid and it really contains a reiserfs partition, then the superblock is corrupted and you need to run this utility with --rebuild-sb. [EMAIL PROTECTED]:/home/kris 8$ # reiserfsck /dev/loop/0 --rebuild-sb reiserfsck 3.6.19 (2003 www.namesys.com) snip Will check superblock and rebuild it if needed Will put log info to 'stdout' reiserfs_open: the reiserfs superblock cannot be found on /dev/loop/0. what the version of ReiserFS do you use[1-4] (1) 3.6.x (2) =3.5.9 (introduced in the middle of 1999) (if you use linux 2.2, choose this one) (3) 3.5.9 converted to new format (don't choose if unsure) (4) 3.5.9 (this is very old format, don't choose if unsure) (X) exit 1 Enter block size [4096]: No journal device was specified. (If journal is not available, re-run with --no-journal-available option specified). Is journal default? (y/n)[y]: Did you use resizer(y/n)[n]: rebuild-sb: no uuid found, a new uuid was generated (7e253707-4fef-42aa-9785-b1cd079851af) rebuild-sb: You either have a corrupted journal or have just changed the start of the partition with some partition table editor. If you are sure that the start of the partition is ok, rebuild the journal header. Do you want to rebuild the journal header? (y/n)[n]: y Reiserfs super block in block 16 on 0x700 of format 3.6 with standard journal Count of blocks on the device: 17659440 Number of bitmaps: 539 Blocksize: 4096 Free blocks (count of blocks - used [journal, bitmaps, data, reserved] blocks): 0 Root block: 0 Filesystem is NOT clean Tree height: 0 Hash function used to sort names: not set Objectid map size 0, max 972 Journal parameters: Device [0x0] Magic [0x0] Size 8193 blocks (including 1 for journal header) (first block 18) Max transaction length 1024 blocks Max batch size 900 blocks Max commit age 30 Blocks reserved by journal: 0 Fs state field: 0x1: some corruptions exist. sb_version: 2 inode generation number: 0 UUID: 7e253707-4fef-42aa-9785-b1cd079851af LABEL: Set flags in SB: Is this ok ? (y/n)[n]: y The fs may still be unconsistent. Run reiserfsck --check. [EMAIL PROTECTED]:/home/kris 1$ # reiserfsck /dev/loop/0 --check reiserfsck 3.6.19 (2003 www.namesys.com) snip Will read-only check consistency of the filesystem on /dev/loop/0 Will put log info to 'stdout' ### reiserfsck --check started at Tue Feb 8 17:17:31 2005 ### Replaying journal.. Reiserfs journal '/dev/loop/0' in blocks [18..8211]: 0 transactions replayed Zero bit found in on-disk bitmap after the last valid bit. Checking internal tree.. Bad root block 0. (--rebuild-tree did not complete) Aborted [EMAIL PROTECTED]:/home/kris 134$ # reiserfsck /dev/loop/0 -y --rebuild-tree reiserfsck 3.6.19 (2003 www.namesys.com) snip Will rebuild the filesystem (/dev/loop/0) tree Will put log info to 'stdout' Do you want to run this program?[N/Yes] (note need to type Yes if you