DMG Image of Startup Disk Won't Mount — URGENT HELP NEEDED!!

I am in high-anxiety panic mode — I have lost everything on my hard drive! Please help!

This initial description will be lengthy with hopes that others have found a solution or can lend a helping hand.

Research

I have been scouring the web for a solution day and night — literally.

I have found discussions about similar, if not exactly alike, problems (e.g., http://discussions.apple.com/thread.jspa?messageID=5751143). Although they have solidified my belief that my data is definitely recoverable, I have not been successful yet.

*A Series of Unfortunate Events*

1. My MacBook Pro's Airport went out (unrelated issue), so I prepped my MBP to be sent to Apple to be fixed.

2. All data was backed up with Time Machine. Also, I booted to the Mac OS X Install Disc 1 that came with my MBP and used Disk Utility to create an image (DMG) of my entire startup disk.

3. I installed a fresh copy of Mac OS X on the hard drive and sent the MBP to Apple.

4. While the MBP was out to be worked on, I desperately needed space on my G-RAID2 so I deleted my Time Machine backups, thinking it was no big deal since I had the DMG backup. Looking back, I have +no idea+ what I was thinking.

5. When I got my MBP back, I tried to mount the DMG to access my files and got this error: "The following disk images failed to mount" with "no mountable file systems" given as Reason.

*Other Information*

My MBP has a 500 GB hard drive with two partitions, one for Mac OS X and one for Windows Vista Ultimate 64-bit (Bootcamp). The Mac OS X partition had a capacity of 414.88 GB, but with only approx. 300 GB used.

When I first tried to create the DMG, I selected New Image and used the settings "read/write" for Image Format and "none" for Encryption. However, I did not have enough free space, so I used the default settings "compressed" for Image Format and "none" for Encryption. The image was created +without any reported errors+ at a size of 226.83 GB.

*Elementary Tests*

Disk Utility
~ Can see the DMG.
~ Repair Disk returns an error: "Repairing volume failed: Unrecognized Filesystem."
~ Using Convert works, but the new image is the exact same (with the same failures).

DiskWarrior
~ Cannot see the DMG because it won't mount. This is expected given DW documentation.
~ Using File > Rebuild Disc Image... I am able to select the DMG, but I get the following error (probably resulting from being unmountable): "DiskWarrior encountered an unexpected error while attempting to rebuild the directory of the disk '/backup/Mac OS X.dmg'. Rebuilding was canceled and the disk was not modified. Restart from the DiskWarrior disc and try rebuilding again. If you report this error, please mention the error code (2150, 2)."

DropDMG
~ Able to convert the DMG to CDR, but still unmountable.

Data Rescue II (Demo) and VirtualLab Data Recovery (Free Trial)
~ Able to scan DMG and find some files, but I cannot see what the files actually are since I am using the free versions. This simply gives me hope that I don't have a useless image.

*Closing Statements*

ANYONE that can help, PLEASE do! With the insomnia this is causing, I will be here 24/7.

Thank you in advance!

Steve

MacBook Pro 17-inch: 2.5 GHz (Early 2008), Mac OS X (10.5.7), Intel Core 2 Duo, 4 GB Memory, 500 GB Hard Drive

Posted on Jun 30, 2009 11:12 PM

Reply
53 replies

Jul 3, 2009 11:56 AM in response to romarcin

Thanks for sharing your expertise on this frightening issue! Hopefully my end result will be as successful as your own.

I did see that post. In fact, one of the first things I tried were the steps laid out in the post by Sonic84 ( http://discussions.apple.com/thread.jspa?threadID=1253428#8994546). Needless to say, it was unsuccessful.

On my main hard drive there were 2 partitions — 1 for Mac OS X and 1 for Windows Vista Ultimate 64-bit. However, in Disk Utility I selected the Mac OS X partition, then New Image, and so on.

I created the DMG tail using *tail -c 20000 /Volumes/G-RAID2/Backup/Mac\ OS\ X.dmg >dmgtail*, and it can be found here:

http://www.box.net/shared/unteghc1gu

Please note that I added a TXT extension to the file so that it could be recognized for upload.

Jul 3, 2009 3:30 PM in response to Steven "Steve" Rogers

Hi Steve:
I just discovered that the open source disk partition recovery tool TestDisk will operate on an attached, unmounted disk image.

The command will look something like this (after you attach your image file)
assuming testdisk is on the desktop in a folder called testdisk:
sudo testdisk /Users/steve/Desktop/testdisk/testdisk /dev/disk6s2

Let me know if this helps
Kj

Jul 4, 2009 6:42 AM in response to romarcin

the code at:
http://github.com/planetbeing/libdmg-hfsplus/tree/master
starts by reading resources part from the end. There is written the position of the xml and its length...
If the xml is at the begining then maybe adding the missing resource part would work.
But again I am not sure. The best would be If apple enginners had a look at that.

Please send us:
head -c 10000000 broken.dmg >dmghead

Message was edited by: romarcin

Jul 8, 2009 2:44 AM in response to KJK555

Below is a quick disk summary. Note that the image is attached (disk5).

*diskutil list*

/dev/disk0
#: TYPE NAME SIZE IDENTIFIER
0: GUID partitionscheme *465.8 Gi disk0
1: EFI 200.0 Mi disk0s1
2: Apple_HFS Mac OS X 414.9 Gi disk0s2
3: Microsoft Basic Data Windows Vista 50.6 Gi disk0s3
/dev/disk1
#: TYPE NAME SIZE IDENTIFIER
0: Apple partitionscheme *1.8 Ti disk1
1: Apple partitionmap 31.5 Ki disk1s1
2: Apple_HFS G-RAID2 1.8 Ti disk1s3
/dev/disk2
#: TYPE NAME SIZE IDENTIFIER
0: GUID partitionscheme *149.1 Gi disk2
1: EFI 200.0 Mi disk2s1
2: Apple_HFS Lacie43 148.7 Gi disk2s2
/dev/disk3
#: TYPE NAME SIZE IDENTIFIER
0: GUID partitionscheme *465.8 Gi disk3
1: EFI 200.0 Mi disk3s1
2: Apple_HFS Lacie37 465.4 Gi disk3s2
/dev/disk4
#: TYPE NAME SIZE IDENTIFIER
0: Apple partitionscheme *829.8 Gi disk4
1: Apple partitionmap 31.5 Ki disk4s1
2: Apple_HFS srogers 829.8 Gi disk4s2
/dev/disk5
#: TYPE NAME SIZE IDENTIFIER
0: *226.8 Gi disk5

TestDisk

I tried the commands you supplied, but Terminal returned "sudo: testdisk: command not found" for every attempt. I used the TestDisk documentation ( http://www.cgsecurity.org/wiki/TestDisk) to find another route. Next are the steps I took.

Terminal
1. Changed from the current directory to the location of TestDisk.
– cd /Users/srogers/Desktop/testdisk-6.11.3/darwin
2. Opened TestDisk (menu-based) within Terminal.
– sudo ./testdisk

TestDisk
1. Selected "Create" in order to create a new log file.
2. Selected "/dev/disk5" as media (hard drive with lost partitions).
3. Selected "Mac" (Apple Partition Map) as the partition table type.
4. Selected "Analyse" to check the current partition structure and search for lost partitions.

The one concern I have is that I should have chosen "EFI GPT" instead of "Mac" in Step 3. Thoughts on this?

At this point I am leaving TestDisk to finish analyzing (currently at 20%) while I grab a nap. I'll be checking back soon. Until then...

Jul 8, 2009 1:49 PM in response to romarcin

After the analysis completed, here is what was displayed:

*Terminal Window <top>*

TestDisk 6.11.3, Data Recovery Utility, May 2009
Christophe GRENIER <grenier@cgsecurity.org>
http://www.cgsecurity.org

Disk /dev/disk5 - 243 GB / 226 GiB - CHS 475695105 1 1
Partition Start End Size in sectors

Structure: Ok.

Keys A: add partition, L: load backup, Enter: to continue

*Terminal Window <bottom>*

Even though it says that the structure is "OK," I am guessing this is akin to how I am able to convert the DMG to a sparse image successfully, yet unsuccessfully (see my post on Jul 3, 2009 1:22 PM: http://discussions.apple.com/thread.jspa?messageID=9764137#9760412).

The only options are "add partition" or "load backup," so I might have hit another dead end.

Any advice or suggestions on using TestDisk?

Jul 8, 2009 3:18 PM in response to Steven "Steve" Rogers

"Structure: Ok. ...
The only options are "add partition" or "load backup," so I might have hit another dead end. "
##
I was afraid of that...
That is good news, but bad news at the same time.

The actual files and partition structure are sane, but obviously not recorded properly in the
xml file. TestDisk (and most any other partition recovery utility) is designed to work on physical
disk drives, which do not use an xml file as a guide to establish the starting and ending address
of the partition map. Physical disk drives use the physical drive sector 0 as a reference, disk
images record the partition starting points and other info in an xml file at the time of creation.
So quite simply, if the image mount utility cannot find the partition starting and ending points
because the xml file is corrupt, it won't mount the image.

If I were you I would put a call in to apple engineers to see if they would be kind enough to
assist in repairing the xml files.

Kj

Jul 8, 2009 6:09 PM in response to Steven "Steve" Rogers

Unfortunately, Apple is very secretive and doesn't publish the disk image format specifications
(according to sourceforge.net - and I believe them).

I searched Apple Developer Connection but found nothing that would help in repairing your
disk image.

Since they are the only ones that have the needed knowledge at their fingertips to gain access
to your data, then your going to have to not take no for an answer if you want to recover your
data, even if you have to call Steve Jobs personally somehow.

Maybe one of us good 'ol boys will figure something out 🙂

Kj

Jul 8, 2009 11:33 PM in response to KJK555

I did try DiskWarrior – see my initial post under the heading "Elementary Tests" to see a description. The combination of being unmountable and compressed proved to be an insurmountable problem for DW.

I too have searched endlessly for information on Apple's disk imaging. Maybe somebody out there has done enough experimenting to help out, or Apple will come to the rescue.

I am not giving up on the fight — I am keeping the faith!

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

DMG Image of Startup Disk Won't Mount — URGENT HELP NEEDED!!

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.