28 Jan 2020

Copying files from a MicroSD card to PC fails

On an Android phone the 64GB MicroSD storage expansion card was nearly full. I replaced it with a 128GB card. I plugged the old 64GB card in my Windows PC and started copying the photos and videos from it to my hard disk. There was nearly 64GB of data so I left it copying... Upon my return I found it had stopped after only copying only a few files. There was a semaphore error.

Maybe there was a corrupt file? The MicroSD card could be corrupt or faulty?

I tried the file copy again but this time I used the Robocopy command line, it is more robust than Explorer and I felt perhaps it would do a better job. Robocopy also stopped after copying just a few files. It was as thorough the SD card was no longer recognised by my PC.


Robocopy ERROR 121 (0x00000079)
The semaphore timeout period has expired.

I tried a different USB port
I tried a different SD card reader
No success.

I ran the Robocopy command, when it got stuck I removed the SD card physically from the computer, then plugged it back in. It would copy more files... Until getting stuck again. I successfully used this method to copy a large number of files but with hundreds of files this was not a viable solution.

I noticed that mostly smaller files were being copied more often than larger ones. Video files of 100MB just got stuck.

For the video files over 50MB I used 7-Zip to create a compressed file with volumes. I ended up with lots of 1.44MB files. I managed to copy these smaller files to the C: drive and extract the video file. I continued with this for a time, I was mostly successful. But this was slow and the semaphore error came up again. 



Solution
I did a lot of searching on the web, I came across an application called Backupper. I tried this to synchronise a folder on the old MicroSD card to my C: drive. This worked! It does take a long time and it is quirky software because it has a percentage complete that goes steadily to 76% and appears to get stuck there. But it is still working, if you open Explorer to the destination folder you will see new files appear. Be patient though, in my case I left it running all day.


In the above screen shot you'll see that it couldn't read a file. In this case you'll just have to accept that, because it can't work miracles, some files might be corrupt/damaged. I did recover most of the files though.


Conclusion
If you have the semaphore error do not despair. Try Backupper, it's worth a go.

Of course it does raise a question over the reliability of MicroSD cards. My feeling is that when you have used a card extensively and almost filled it with so many files, the possibility of a failure like this grows. Contemplate replacing your micro SD card every few years and of course back up. Google Photos backup is free therefore at least for JPGs you can safeguard them. For videos maybe copy them off your phone periodically?

I hope this was helpful. Many thanks to Backupper.
https://www.ubackup.com/download.html


Disclaimer
I am not guaranteeing anything here. This is just my experience! Good luck.


Related
You might also be interested in the following recent article I wrote about a problem I found with MicroSD cards. This is more related to the speed of the card and which one to purchase.
https://mgxp.blogspot.com/2019/12/which-microsd-card-should-i-use-in-my.html

1 comment:

Peer said...

Thanks for the recommendation. I had a microSD card where the Windows Explorer would crash after a few minutes of accessing or copying files. Thanks to Backuper I was able to recover most of the files.