October 23, 2014, 11:59:37 AM

Author Topic: Recovery of files  (Read 2229 times)

J.R.

  • 1D X
  • *******
  • Posts: 1512
    • View Profile
Recovery of files
« on: February 04, 2013, 12:40:37 AM »
Hi,

Is there any way to recover files after the card has been subject to an "in-camera" low level format?

I'll be selling off a few cards and just want to make sure nothing is recoverable on them.
5D3, 6D, 600D, RX100
16-35L, 24-70L II, 70-200L II, 100-400L, 50L, 85L II, 135L, 24TSE, 40, 100 macro, 18-55 II, 55-250 II, 600RT x 4
I come here to learn something new, not to learn how bad my gear is - I know that already ;-)!

canon rumors FORUM

Recovery of files
« on: February 04, 2013, 12:40:37 AM »

bycostello

  • 1D Mark IV
  • ******
  • Posts: 910
    • View Profile
    • London Weddings
Re: Recovery of files
« Reply #1 on: February 04, 2013, 02:07:59 AM »
cost would outweigh any desire to do so....  but what was on them I'm intrigued to know!!!

Halfrack

  • Canon 7D MK II
  • *****
  • Posts: 480
    • View Profile
Re: Recovery of files
« Reply #2 on: February 04, 2013, 02:23:56 AM »
Doable, but it's a trade off ....

Take an old body and a wired remote, point it at a wall and set it to continuous shooting and walk away.  Card fills up with real data, wipe it once more and you're set.
"Me owning a lens shop is kind of like having an alcoholic bar tender." - Roger Cicala

J.R.

  • 1D X
  • *******
  • Posts: 1512
    • View Profile
Re: Recovery of files
« Reply #3 on: February 04, 2013, 02:26:53 AM »
cost would outweigh any desire to do so.... but what was on them I'm intrigued to know!!!

LOL ... The cards contain pics of my family which I don't wants in the hands of a third party for obvious reasons. These are 4-16GB slow cards which I never use now (a couple of them report errors on the 5D3).

The 32GB 90x card from the 7D was retained upon sale of the camera so I practically have too much CF gigabytes than necessary.

Dunno whether it would be better to just destroy the damn things because I'm not sure what these will fetch ... I was hoping of getting a fast SDHC card for the 6D.
5D3, 6D, 600D, RX100
16-35L, 24-70L II, 70-200L II, 100-400L, 50L, 85L II, 135L, 24TSE, 40, 100 macro, 18-55 II, 55-250 II, 600RT x 4
I come here to learn something new, not to learn how bad my gear is - I know that already ;-)!

rpt

  • Canon EF 300mm f/2.8L IS II
  • *******
  • Posts: 2219
  • Could not wait for 7D2 so I got the 5D3
    • View Profile
Re: Recovery of files
« Reply #4 on: February 04, 2013, 03:15:23 AM »
Put them in a card reader. Copy useless files over if you don't want to use up shutter count... If your file size is 1K, you will use up all memory.

You could also look for file shredding software that overwrites your current files with junk before deleting them.

J.R.

  • 1D X
  • *******
  • Posts: 1512
    • View Profile
Re: Recovery of files
« Reply #5 on: February 04, 2013, 04:53:29 AM »
Put them in a card reader. Copy useless files over if you don't want to use up shutter count... If your file size is 1K, you will use up all memory.


Thanks ... I'll use the above method.
5D3, 6D, 600D, RX100
16-35L, 24-70L II, 70-200L II, 100-400L, 50L, 85L II, 135L, 24TSE, 40, 100 macro, 18-55 II, 55-250 II, 600RT x 4
I come here to learn something new, not to learn how bad my gear is - I know that already ;-)!

Don Haines

  • Canon EF 300mm f/2.8L IS II
  • *******
  • Posts: 3357
  • Posting cat pictures on the internet since 1986
    • View Profile
Re: Recovery of files
« Reply #6 on: February 06, 2013, 09:26:10 PM »
Put them in a card reader. Copy useless files over if you don't want to use up shutter count... If your file size is 1K, you will use up all memory.

That's what we do at work to hard drives being circulated through the organization.... low level format.... fill with junk files... then low level format. We shred any drives or destroy any memory cards before disposal outside of the organization. For us, the risk of someone recovering data far outweighs what we could sell used storage devices for.
The best camera is the one in your hands

canon rumors FORUM

Re: Recovery of files
« Reply #6 on: February 06, 2013, 09:26:10 PM »

rpt

  • Canon EF 300mm f/2.8L IS II
  • *******
  • Posts: 2219
  • Could not wait for 7D2 so I got the 5D3
    • View Profile
Re: Recovery of files
« Reply #7 on: February 06, 2013, 09:33:59 PM »
Put them in a card reader. Copy useless files over if you don't want to use up shutter count... If your file size is 1K, you will use up all memory.

That's what we do at work to hard drives being circulated through the organization.... low level format.... fill with junk files... then low level format. We shred any drives or destroy any memory cards before disposal outside of the organization. For us, the risk of someone recovering data far outweighs what we could sell used storage devices for.
I had written a program last year. If I can find it I will post a link...

Mt Spokane Photography

  • EF 50mm F 0.7 IS
  • *********
  • Posts: 8870
    • View Profile
Re: Recovery of files
« Reply #8 on: February 06, 2013, 09:34:43 PM »
Only SD cards will have a in-camera low level format option. A regular in-camera format is not a low level format.  If you have a camera that offers a low level format for your SD card, it writes zeros to all of the memory cells and the images are not recoverable.
Most cameras do not offer the low level format option.  You can do a full format with the card in a card reader using your computer which does the same thing.  A quick format does not.

J.R.

  • 1D X
  • *******
  • Posts: 1512
    • View Profile
Re: Recovery of files
« Reply #9 on: February 06, 2013, 09:54:33 PM »
Only SD cards will have a in-camera low level format option. A regular in-camera format is not a low level format.  If you have a camera that offers a low level format for your SD card, it writes zeros to all of the memory cells and the images are not recoverable.
Most cameras do not offer the low level format option.  You can do a full format with the card in a card reader using your computer which does the same thing.  A quick format does not.

The 5d3 offers a low level format for both the CF as well as ONLY for the SD card in the camera. Glad to know that the low level 'in camera' format will render any on card files unrecoverable.

Mt Spokane was right all along ... low level format is available only for the SD card and not the CF card. An edit to my post was necessitated ...

Thanks ... JR
« Last Edit: February 07, 2013, 03:08:00 AM by J.R. »
5D3, 6D, 600D, RX100
16-35L, 24-70L II, 70-200L II, 100-400L, 50L, 85L II, 135L, 24TSE, 40, 100 macro, 18-55 II, 55-250 II, 600RT x 4
I come here to learn something new, not to learn how bad my gear is - I know that already ;-)!

Drizzt321

  • 1D X
  • *******
  • Posts: 1674
    • View Profile
    • Aaron Baff Photography
Re: Recovery of files
« Reply #10 on: February 07, 2013, 02:26:27 AM »
Only SD cards will have a in-camera low level format option. A regular in-camera format is not a low level format.  If you have a camera that offers a low level format for your SD card, it writes zeros to all of the memory cells and the images are not recoverable.
Most cameras do not offer the low level format option.  You can do a full format with the card in a card reader using your computer which does the same thing.  A quick format does not.

The 5d3 offers a low level format for both the CF as well as SD card in the camera. Glad to know that the low level 'in camera' format will render any on card files unrecoverable.

Thanks ... JR

Erm...if the 'format' options takes just a few seconds, there's no way it's a low level format unless you are dealing with just a few hundred MByte's tops. If it takes several minutes to an hour or so, then it's probably really doing a 'low level' format, which would be resetting all of the cells on the flash memory to blank.
5D mark 2, 5D mark 3, EF 17-40mm f/4L,  EF 24-105mm f/4L IS USM, EF 135mm f/2L, EF 85mm f/1.8
Film Cameras: Mamiya RB67, RB-50, RB-180-C, RB-90-C, RB-50, Perkeo I folder, Mamiya Six Folder (Pre-WWII model)
http://www.aaronbaff.com

J.R.

  • 1D X
  • *******
  • Posts: 1512
    • View Profile
Re: Recovery of files
« Reply #11 on: February 07, 2013, 03:00:35 AM »

Erm...if the 'format' options takes just a few seconds, there's no way it's a low level format unless you are dealing with just a few hundred MByte's tops. If it takes several minutes to an hour or so, then it's probably really doing a 'low level' format, which would be resetting all of the cells on the flash memory to blank.

I believe that the 5D3 offers a quick format mode and also a low level format mode. The last time I formatted the SD card, it took a good amount of time - several minutes I think. I don't have the camera here to confirm this though ... will check and revert.
5D3, 6D, 600D, RX100
16-35L, 24-70L II, 70-200L II, 100-400L, 50L, 85L II, 135L, 24TSE, 40, 100 macro, 18-55 II, 55-250 II, 600RT x 4
I come here to learn something new, not to learn how bad my gear is - I know that already ;-)!

J.R.

  • 1D X
  • *******
  • Posts: 1512
    • View Profile
Re: Recovery of files
« Reply #12 on: February 07, 2013, 03:11:06 AM »
Only SD cards will have a in-camera low level format option. A regular in-camera format is not a low level format.  If you have a camera that offers a low level format for your SD card, it writes zeros to all of the memory cells and the images are not recoverable.
Most cameras do not offer the low level format option.  You can do a full format with the card in a card reader using your computer which does the same thing.  A quick format does not.

The 5d3 offers a low level format for both the CF as well as SD card in the camera. Glad to know that the low level 'in camera' format will render any on card files unrecoverable.

Thanks ... JR

Erm...if the 'format' options takes just a few seconds, there's no way it's a low level format unless you are dealing with just a few hundred MByte's tops. If it takes several minutes to an hour or so, then it's probably really doing a 'low level' format, which would be resetting all of the cells on the flash memory to blank.

I checked the manual - It specifically mentions this on page 54 regarding the SD card low level format -

"Since low-level formatting will erase all recordable sectors in the SD card, the formatting will take slightly longer than normal formatting"
5D3, 6D, 600D, RX100
16-35L, 24-70L II, 70-200L II, 100-400L, 50L, 85L II, 135L, 24TSE, 40, 100 macro, 18-55 II, 55-250 II, 600RT x 4
I come here to learn something new, not to learn how bad my gear is - I know that already ;-)!

canon rumors FORUM

Re: Recovery of files
« Reply #12 on: February 07, 2013, 03:11:06 AM »

rpt

  • Canon EF 300mm f/2.8L IS II
  • *******
  • Posts: 2219
  • Could not wait for 7D2 so I got the 5D3
    • View Profile
Re: Recovery of files
« Reply #13 on: February 07, 2013, 03:23:22 AM »
J.R., I found the code. It is in Java. I am attaching it here. You can use any java IDE to run it. You will need to change the drive letter defined in the line below to the drive that maps your memory card.
      FillDiskSpace fds1 = new FillDiskSpace("D:");

can be changed to:
      FillDiskSpace fds1 = new FillDiskSpace("G:");
if your drive G is the memory card. The program creates a folder called Dir2Fill and fills it with 1MB files containing junk. So delete everything on the card. Run the program. Once it fills up, you can delete that folder and you should be ok. In case you are paranoid about the 1MB, change the line:
   private static final int ONE_MB = 1048576;
to:
   private static final int ONE_MB = 1024;
and you will be fine.

Code follows:
//==Code follows: ======================================

import java.io.BufferedWriter;
import java.io.File;
import java.io.FileWriter;
import java.io.IOException;


public class FillDiskSpace {

   private static final String DIR_NAME = "Dir2Fill";
   private static final String FILE_LINE = "AAAAAAAAAASSSSSSSSSSDDDDDDDDDDFFFFFFFFFFGGGGGGGGGGHHHHHHHHHHJJ\r\n";
   private static final String C_DRIVE = "C:";
   private static final int ONE_MB = 1048576;
   private static final int SIXTY_FOUR = 64;
   private static final String DRV_STR_LENGTH = "Drive string must be 2 characters long.";
   private static final String DRV_STR_NO_COLON = "The character at the second position must be a colon ':'";
   private static final String INVALID_DRV_LTR = "Invalid drive letter. Must be between 'A' and 'Z' inclusive.";
   private String sDrive = null;
   private String sDirFullPath = null;
   
   public FillDiskSpace()
   {
      FillDiskSpaceMthd(C_DRIVE);
   }

   private void FillDiskSpaceMthd(String sDir)
   {
      String sErrMsg = null;
      
      sDir = sDir.toUpperCase();
      if(sDir.length() != 2)
         sErrMsg = DRV_STR_LENGTH;
      else if(sDir.charAt(1) != ':')
         sErrMsg = DRV_STR_NO_COLON;
      else if(sDir.charAt(0) < 'A' || sDir.charAt(0) > 'Z')
         sErrMsg = INVALID_DRV_LTR;
      
      if(sErrMsg != null)
      {
         System.out.println(sErrMsg);
         return;
      }
      
      long lStart = System.currentTimeMillis()/1000l;
      long lThen = lStart;
      long lNow = lStart;
      long lDiffSec = 0;
      long lDiffSecTotal = 0;
      sDrive = sDir;
      sDirFullPath = sDrive + "/" + DIR_NAME;
      File dir = new File(sDirFullPath); 
      dir.mkdir();
      int ret = 0;
      int fileNo = 1;
      while(ret == 0)
      {
         String sFileName = "File_" + fileNo + ".txt";
         ret = WriteA1MbFile(sFileName);
         if( fileNo%100 == 0)
         {
            lNow = System.currentTimeMillis()/1000l;
            lDiffSec = (lNow - lThen);
            lThen = lNow;
            lDiffSecTotal = (lNow - lStart);
            System.out.println("Wrote " + fileNo + " files so far... This set took " + lDiffSec + " sec. Total so far " + lDiffSecTotal + " sec.");
         }
         if(ret == 0)
            fileNo++;
      }
      lNow = System.currentTimeMillis()/1000l;
      lDiffSec = (lNow - lThen);
      System.out.println("\r\nWrote " + (ret==-1?fileNo:fileNo-1) + " files in all. This set took " + lDiffSec + " sec.");
      lDiffSec = (lNow - lStart);
      System.out.println("Total time taken is " + lDiffSec + " sec.");

   }

   public FillDiskSpace(String sDir)
   {
      FillDiskSpaceMthd(sDir);
   }

   /**
    * @param args
    */
   public static void main(String[] args)
   {
      FillDiskSpace fds1 = new FillDiskSpace("D:");

   }

   private int WriteA1MbFile(String sFileName)
   {
      String content = FILE_LINE;
      int siz = 0;
      
      try {
         
         File file = new File(sDirFullPath + "/" + sFileName);
   
         // if file doesnt exists, then create it
         if (!file.exists()) {
            file.createNewFile();
         }
   
         FileWriter fw = new FileWriter(file.getAbsoluteFile());
         BufferedWriter bw = new BufferedWriter(fw);
         while( siz < ONE_MB)
         {
            bw.write(content);
            siz += SIXTY_FOUR;
         }
         bw.close();
   
   
      } catch (IOException e) {
//         e.printStackTrace();
         System.out.println(e.getMessage());
         return (siz == 0? -2:-1);
      }
      
      return 0;
   }

}

//==Code ends: =======================================


J.R.

  • 1D X
  • *******
  • Posts: 1512
    • View Profile
Re: Recovery of files
« Reply #14 on: February 07, 2013, 03:24:44 AM »
Thanks rpt ... just the thing I was looking for. Will try this once I get home!
5D3, 6D, 600D, RX100
16-35L, 24-70L II, 70-200L II, 100-400L, 50L, 85L II, 135L, 24TSE, 40, 100 macro, 18-55 II, 55-250 II, 600RT x 4
I come here to learn something new, not to learn how bad my gear is - I know that already ;-)!

canon rumors FORUM

Re: Recovery of files
« Reply #14 on: February 07, 2013, 03:24:44 AM »