I *might* be making some progress, or on the other hand...
Using testdisk I scanned for partitions and found, allegedly, one at C/H/S = 3/112/46. Testdisk wouldn't add it for me because my disk image is too small - it looks like makybe I have only the first 40GB of a 400GB disk, although that should still include the data I'm looking for. So I added it manually and now: $ fdisk -l mydisk.dsk
Disk mydisk.dsk: 39.7 GB, 39711651840 bytes 255 heads, 63 sectors/track, 4828 cylinders, total 77561820 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000
Device Boot Start End Blocks Id System mydisk.dsk1 53248 77561819 38754286 5 Extended mydisk.dsk5 55296 77561819 38753262 83 Linux
So, taking the 55296 from fdisk [1]: $ sudo losetup /dev/loop0 mydisk.dsk -o $((55296 * 512)) $ sudo file -s /dev/loop0 /dev/loop0: Linux rev 1.0 ext3 filesystem data, UUID=a8a4611e-43c8-11d5-93cc-d0a0e5109e59 (errors)
Looks like I now have a visible filesystem, albeit with errors. I then tried:
$ sudo dumpe2fs /dev/loop0 dumpe2fs 1.42.9 (4-Feb-2014) Filesystem volume name: / Last mounted on: <not available> Filesystem UUID: a8a4611e-43c8-11d5-93cc-d0a0e5109e59 Filesystem magic number: 0xEF53 Filesystem revision #: 1 (dynamic) Filesystem features: has_journal filetype sparse_super Default mount options: (none) Filesystem state: clean with errors Errors behavior: Continue Filesystem OS type: Linux Inode count: 4849664 Block count: 9695227 Reserved block count: 484761 Free blocks: 7452549 Free inodes: 4675796 First block: 0 Block size: 4096 Fragment size: 4096 Blocks per group: 32768 Fragments per group: 32768 Inodes per group: 16384 Inode blocks per group: 512 Last mount time: Fri Dec 6 16:24:24 2002 Last write time: Thu Apr 3 16:31:39 2003 Mount count: 10 Maximum mount count: -1 Last checked: Tue May 8 16:41:57 2001 Check interval: 0 (<none>) Reserved blocks uid: 0 (user root) Reserved blocks gid: 0 (group root) First inode: 11 Inode size: 128 Journal inode: 8 First orphan inode: 213013 dumpe2fs: A block group is missing an inode table while reading journal inode
The data presented in terms of mount/write times sounds like it could be about right, which is nice. So, what next? The help I found online suggested I used a backup superblock to recover the filesystem but there are none listed here (is that an ext2 vs ext3 thing?)
I tried e2fsck:
$ sudo e2fsck /dev/loop0 e2fsck 1.42.9 (4-Feb-2014) ext2fs_check_desc: Corrupt group descriptor: bad block for block bitmap e2fsck: Group descriptors look bad... trying backup blocks... e2fsck: Bad magic number in super-block while using the backup blockse2fsck: going back to original superblock e2fsck: A block group is missing an inode table while checking ext3 journal for /
/: ********** WARNING: Filesystem still has errors **********
Like any of that means anything to me!
[1] If someone can advise me how the 55296 relates to the C/H/S figures I'd love to understand that!