SD Card Failure


vadsamoht

Well-Known Member
Joined
Jun 11, 2010
Messages
1,021
Age
34
Location
South Australia
As the thread title suggests, I have a failed SD card. I'm not sure exactly what caused the failure, as while the card was in the Pandora during the period in which it failed, it may have been caused by physical exerted on the card (through the casing of the Pandora) because I tend to fill the bag I take to university to near bursting.


The card is not recognised at all when put into either SD slot of the Pandora or even the one on my laptop, so it seems more like a full failure than a filesystem corruption.


Is there any way that I can recover the data from the card (even if it means destroying it)?


Also, is the same error likely to occur on another card I have that is exactly the same (same brand, size, and bought at the same time so they probably contain the same hardware)?
 
There's no doubt dedicated SD recovery programs but I'm not familiar with any, however if your running windows and the SD card isn't being detected it might be worth running a Linux LiveCD to see if it shows up there (I've had this occur before), or try out a 30 day demo of this Linux based recovery software for Windows PCs and see if it can see the card.


http://www.acronis.com/homecomputing/download/link/?ATIH2012_trial_en-US.exe


If it can, you can quickly create an image of the card and then browse its contents like a folder, or restore the image to a new card. I use this alot for Windows HDD recovery/backup, or Pandora SD card images as backups. Works very well.
 
Unfortunately, I'm using ubuntu on my laptop, and the problem isn't that it thinks there's an unformatted or corrupt card in the slot, it's that the OS is acting as though there is *no* card in the slot.
 
A couple other things to try:


Reboot. I'm serious, my laptop is a bit finicky, and will stop detecting SD Card slots after a while. Probably a kernel level bug (I'm running some unstable Debian on it right now).


If you ever get it to be detected (but unmountable because it's corrupted or whatnot) don't forget to DD it.



Code:
dd if=/dev/WhateverYourCardIs of=/home/you/my-card.img
Because if you ever need to do drive recovery, say trying to detect images or the like, it's much better to do on the image.
 
If it really has failed, the nature of SD cards and their wear leveling is likely to mean that a dd image will not work. It's worth a try, and once you have the image there's a lot of fancy tools you can use to try and recover the filesystem, but if I were a betting man I'd put all my money in "gone forever". SD cards (and by extension solid state drives) are not backup medium, do not keep anything you can't afford to lose on them.


The card itself might be recoverable, if you can bring it up in gparted you can repartition and reformat it. It could be that the controller is completely dead though, in which case there's no hope of anything, not data recovery, not being able to use the card ever again at all.
 
Unfortunately, I'm using ubuntu on my laptop, and the problem isn't that it thinks there's an unformatted or corrupt card in the slot, it's that the OS is acting as though there is *no* card in the slot.

It possibly sounded like I had misunderstood you but I hadn't. Like Mr Rob, I've had SD cards fail to be recognised at all under one OS (a reboot sometimes fixing it) but detected and working fine on another, or via that Acronis tool I mentioned.


I would agree with WizardStan though, that if it really isn't showing up with anything, then its toast already sadly :(
 
OK, I've managed to have a bit of luck. GParted gave me the location of the disk, and from there I managed to dd a .img image of the card to the desktop of my laptop. The problem is, I now can't find a way of mounting the image. PowerISO gives "SDCARD.img: The file format is invalid or unsupported.", and trying to mount with -o loop gives me a ~500mb folder that in no way resembles the 15GB image.
 
I remember doing something similar long ago, but can't recall anything about it: basically the partition table had gotten messed up and a tool plus a bit of jiggering was able to get it basically working again. A search for "fat32 partition repair" might help.


Keep in mind what I said though: the way SD cards do wear levelling, if the controller became confused resulting in corruption, then it is almost guaranteed that the bytes it has built the image of in no way correspond to the actual bytes of the filesystem. That's being pessimistic though: that you were able to get an image at all, and one of the correct size, is definitely a good sign. Recovering a broken partition is by no means an easy task though, so good luck.
 
I've managed to recover most of the files from the card using photorec as suggested by Linux-SWAT, so I guess you could say problem solved - thanks to everyone who helped.


Now I just have to trawl through the 9000+ files to find the ones that aren't corrupt, and haven't lost all meaning outside of the context of their folders. Yay.
 
One last thing: PhotoRec recovered a large number of files in .elf and .sqlite format, which I certainly didn't have on my card before the issue. It also didn't recover a number of other files, most notably the PNDs. Any guesses where the .elf and .sqlite files came from, and is there any way of recovering the original files?
 
Back
Top