# losetup -a /dev/loop0: [fd00]:88191 (/root/test.img) # file -s /dev/loop0 /dev/loop0: Linux rev 1.0 ext3 filesystem data (large files) # for i in `seq 1 10`; do (dd if=/dev/zero of=/dev/loop0 bs=$RANDOM count=$RANDOM seek=$RANDOM); done # file -s /dev/loop0 /dev/loop0: Linux rev 1.0 ext3 filesystem data (large files) # tune2fs -l /dev/loop0 tune2fs 1.41.4 (27-Jan-2009) Filesystem volume name: Last mounted on: Filesystem UUID: 035d46ec-f2fe-4701-9b57-c97a59c21174 Filesystem magic number: 0xEF53 Filesystem revision #: 1 (dynamic) Filesystem features: has_journal ext_attr resize_inode dir_index filetype sparse_super large_file Filesystem flags: signed_directory_hash Default mount options: (none) Filesystem state: clean Errors behavior: Continue Filesystem OS type: Linux Inode count: 32768 Block count: 131072 Reserved block count: 6553 Free blocks: 40012 Free inodes: 13538 First block: 0 Block size: 4096 Fragment size: 4096 Reserved GDT blocks: 31 Blocks per group: 32768 Fragments per group: 32768 Inodes per group: 8192 Inode blocks per group: 512 Filesystem created: Tue Jun 16 02:03:36 2009 Last mount time: Tue Jun 16 02:13:56 2009 Last write time: Tue Jun 16 02:31:03 2009 Mount count: 0 Maximum mount count: 31 Last checked: Tue Jun 16 02:31:03 2009 Check interval: 15552000 (6 months) Next check after: Sun Dec 13 01:31:03 2009 Reserved blocks uid: 0 (user root) Reserved blocks gid: 0 (group root) First inode: 11 Inode size: 256 Required extra isize: 28 Desired extra isize: 28 Journal inode: 8 Default directory hash: half_md4 Directory Hash Seed: 09a33088-7316-466b-aa77-d785874f807e Journal backup: inode blocks # extundelete --restore-all /dev/loop0 WARNING: Extended attributes are not restored. Loading group metadata ... 4 groups loaded. extundelete: extundelete.cc:1473: void run_program(struct_ext2_filsys*): Assertion `journal_superblock->s_header.h_magic == 0xc03b3998U' failed. Aborted # echo $? 134 # gdb /usr/local/sbin/extundelete GNU gdb (GDB) Fedora (6.8.50.20090302-23.fc11) Copyright (C) 2009 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "i586-redhat-linux-gnu". For bug reporting instructions, please see: ... (gdb) run --restore-all /dev/loop0 Starting program: /usr/local/sbin/extundelete --restore-all /dev/loop0 warning: Unable to open "librpm.so" (librpm.so: cannot open shared object file: No such file or directory), missing debuginfos notifications will not be displayed Missing separate debuginfo for /lib/ld-linux.so.2 Try: yum --enablerepo='*-debuginfo' install /usr/lib/debug/.build-id/7f/17a8dcd78cff33fdaa9729c94e32c2aac4832a.debug Missing separate debuginfo for /lib/libext2fs.so.2 Try: yum --enablerepo='*-debuginfo' install /usr/lib/debug/.build-id/fb/ef94407f90b2186cffd5e785fcf9fa0f833612.debug Missing separate debuginfo for /usr/lib/libstdc++.so.6 Try: yum --enablerepo='*-debuginfo' install /usr/lib/debug/.build-id/57/bb514f1e3e02fcc475236a9624b58406ca3f63.debug Missing separate debuginfo for /lib/libm.so.6 Try: yum --enablerepo='*-debuginfo' install /usr/lib/debug/.build-id/60/df27074322cad32bbad4d55ee09ddc2adbe370.debug Missing separate debuginfo for /lib/libgcc_s.so.1 Try: yum --enablerepo='*-debuginfo' install /usr/lib/debug/.build-id/08/7341c884dd158064dbfd00e9fcde0481b2f40d.debug Missing separate debuginfo for /lib/libc.so.6 Try: yum --enablerepo='*-debuginfo' install /usr/lib/debug/.build-id/a5/e5564345da9ff0f15040d69dcdefef89d1ed73.debug Missing separate debuginfo for /lib/libcom_err.so.2 Try: yum --enablerepo='*-debuginfo' install /usr/lib/debug/.build-id/a8/9d6d5c3932c4fff0f1b3a8afe553ef940ba637.debug Missing separate debuginfo for /lib/libpthread.so.0 Try: yum --enablerepo='*-debuginfo' install /usr/lib/debug/.build-id/42/0e274eb90edb3a1ddcba0b33b6ba52993a0397.debug [Thread debugging using libthread_db enabled] WARNING: Extended attributes are not restored. Loading group metadata ... 4 groups loaded. extundelete: extundelete.cc:1473: void run_program(struct_ext2_filsys*): Assertion `journal_superblock->s_header.h_magic == 0xc03b3998U' failed. Program received signal SIGABRT, Aborted. 0x005a1424 in __kernel_vsyscall () (gdb) bt #0 0x005a1424 in __kernel_vsyscall () #1 0x003cd7c1 in raise () from /lib/libc.so.6 #2 0x003cf092 in abort () from /lib/libc.so.6 #3 0x003c68ee in __assert_fail () from /lib/libc.so.6 #4 0x0804efe7 in run_program (fs=0x8063078) at extundelete.cc:1473 #5 0x0804b4f0 in main (argc=1, argv=0xbffff85c) at extundelete.cc:470 (gdb) quit The program is running. Quit anyway (and kill it)? (y or n) y # file /usr/local/sbin/extundelete /usr/local/sbin/extundelete: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.18, not stripped # extundelete -v; uname -a extundelete version 0.1.0 libext2fs version 1.41.4 Processor is little endian. Linux fedora 2.6.29.4-167.fc11.i686.PAE #1 SMP Wed May 27 17:28:22 EDT 2009 i686 i686 i386 GNU/Linux