Skip navigation

Secure Empty Trash seems to repeat itself

1024 Views 12 Replies Latest reply: Feb 2, 2013 8:24 AM by jsd2 RSS
n m u Level 1 Level 1 (15 points)
Currently Being Moderated
Apr 20, 2011 5:43 PM

If I use "Secure Empty Trash..." I may (for example) see that 8 files are being deleted and the Trash is now empty. If I then delete 1 file and repeat the aforementioned process I see that once again 8 files are being deleted. Why would this happen? Thanks.

MacBookPro6,2, Mac OS X (10.6.7)
  • McYukon Calculating status...
    Currently Being Moderated
    Apr 20, 2011 7:15 PM (in response to n m u)

    Nothing to worry about, AFIK it doesn't really delete any extra files.

    But as to why it exactly happens I haven't found out yet.

  • jsd2 Level 5 Level 5 (6,200 points)
    Currently Being Moderated
    Apr 20, 2011 10:12 PM (in response to n m u)

    You have some external volumes mounted as well, correct?

     

    In my system, every mounted volume seems to contribute a minimum of two items that get deleted by Secure Empty Trash, even if there is just a single item in the dock Trash window beforehand. Making hidden files visible in Finder does not show any additional items in the various Trash folders before the secure delete.

     

    I currently have a total of 16 partitions mounted. If I first Secure Empty the Trash, then put a single item into the Trash from my Desktop and then Secure Empty the Trash again, I will see a progress window saying that 34 items are being deleted. Reducing the number of mounted volumes reduces the count by two for each volume that is unmounted.

     

    I don't know what the extra items actually represent. They may be part of the always-hidden directory structure that exists in every hfs+ volume.

  • Topher Kessler Level 6 Level 6 (9,295 points)
    Currently Being Moderated
    Apr 20, 2011 11:50 PM (in response to n m u)

    This happens because secure empty trash writes over the data on disk with a file that is the exact size of the data. This ensures the original data is not ever recoverable. The file contains random patterns of data and is written to the disk 7 times to ensure all original data will be practically impossible to recover (this is what makes the erase routine "secure"). The finder will see each of the random data files as an individual file, so you will see them included in the list of files being deleted.

  • jsd2 Level 5 Level 5 (6,200 points)
    Currently Being Moderated
    Apr 21, 2011 3:04 AM (in response to Topher Kessler)

    Hi,

     

    That doesn't explain some of my own findings - the numbers don't add up.  In my system, if only the startup disk is mounted and a single file is placed in the Trash, a secure-delete progress window will show four items being deleted.

     

    Just mounting an additional external volume will add two items to the apparent number of items being secure-deleted for each such volume added, even though no files on the additional volumes are placed in the Trash to begin with.

     

    Here are the tests I did.

    Start with a text file that is on the DeskTop.

    For each test:

    1) duplicate the text file

    2) move the duplicate copy to the Trash

    3) secure-empty the Trash,

    4) repeat step 1

    5) repeat step 2

    6) repeat step 3

     

    Steps 1-3 were done to be sure the Trash folders were truly empty before performing the actual test in steps 4-6.

     

    To be determined:

    In step 6, after that single file has been placed in the startup volume's Trash, how many items does the secure-delete progress window show as being deleted?

     

    Results:

    In my system, if the test is run with no disk volumes other than the startup disk mounted, the secure-delete progress window shows four items being deleted.

     

    If I run the test after first mounting a single external volume, then the secure-delete progress window shows six items being deleted.  Again, just one file was in the Trash after step 5, the same as for the first test.

     

    If I mount a second external volume and repeat the test, again with only a single file in the Trash after step 5, the secure-delete progress window now shows 8 items being deleted.

     

    If I first mount all 15 of my external partitions and run the same test, again with a single file in the Trash after step 5, the secure-delete progress window shows 34 items being deleted!

  • jsd2 Level 5 Level 5 (6,200 points)
    Currently Being Moderated
    Apr 21, 2011 11:25 AM (in response to n m u)

    n m u wrote:

     

    jsd2 wrote:

     

    You have some external volumes mounted as well, correct?

     

     

    Yes.

     

    Message was edited by: n m u

     

    Am I supposed to guess how many?

     

    OK, since you said you're seeing 8 items being securely deleted when you put one item in the trash, I'm going to guess, based on what I posted earlier, that you have precisely two external volumes mounted.

     

    A further prediction, again as posted, would be that if you first unmount all the external volumes and again secure-erase one file, you should now see four items being deleted.

     

    If so, I think that would all be normal.

  • Topher Kessler Level 6 Level 6 (9,295 points)
    Currently Being Moderated
    Apr 21, 2011 9:38 PM (in response to jsd2)

    If I take a single text file that's a few KB in size (as basic of a document as you can get) and secure-delete it, it shows a 7-pass deletion (7 files deleted). This happens both with and without secondary drives attached (the behavior is very consistent). One thing to keep in mind is if you are removing packaged files (e.g., applications or installer files) then all of the files within the package will be deleted as individual files.

  • Topher Kessler Level 6 Level 6 (9,295 points)
    Currently Being Moderated
    Apr 21, 2011 9:42 PM (in response to jsd2)

    Another thing to keep in mind is the Finder will not always show the total number of files being deleted. The Finder will only show the total number of files remaining to be deleted, and in the time it takes for the progress window to appear a few files can already be gone. Therefore, if you put a number of files in the trash and deleted them often the Finder will only show the last few as they get trashed.

  • jsd2 Level 5 Level 5 (6,200 points)
    Currently Being Moderated
    Apr 21, 2011 10:36 PM (in response to Topher Kessler)

    I had used a single 4KB text file, not a bundle such as an application. I just tried again and got the same result with even simpler files, namely zero-KB "empty" files that I created with Terminal's "touch" command.

     

    With all my 15 external volumes mounted, if I first secure-empty the Trash as a preliminary step, then move a single 0KB  file from the Desktop to the Trash  and then secure-empty the Trash again, I again see a window showing that 34 items are being deleted. Since this number is much higher than seven, there can't be an issue of the Finder progress window giving a misleadingly low number because it only shows "the last few as they get trashed".

     

    And again as before, if I first unmount all my external volumes and again secure-delete a single 0KB  file, I again see a window saying that four items are being deleted.

     

    I can't explain the difference in our findings.

  • Graham Perrin Level 2 Level 2 (240 points)
    Currently Being Moderated
    Feb 2, 2013 5:39 AM (in response to jsd2)

    Echoing https://discussions.apple.com/message/21114113#21114113

     

    > 16 partitions

     

    From more than one disk, yes?

  • jsd2 Level 5 Level 5 (6,200 points)
    Currently Being Moderated
    Feb 2, 2013 8:24 AM (in response to Graham Perrin)

    Graham Perrin wrote:

     

    Echoing https://discussions.apple.com/message/21114113#21114113

     

    > 16 partitions

     

    From more than one disk, yes?

     

    Yes, to be sure!

     

    As I mentioned in this Snow Leopard thread, each additional mounted volume seemed to increase the apparent  count by two. The same had been true in Leopard, but when I tried this in Lion, there was a change - each additional mounted volume increased the count by one instead of two. Strange.

Actions

More Like This

  • Retrieving data ...

Bookmarked By (1)

Legend

  • This solved my question - 10 points
  • This helped me - 5 points
This site contains user submitted content, comments and opinions and is for informational purposes only. Apple disclaims any and all liability for the acts, omissions and conduct of any third parties in connection with or related to your use of the site. All postings and use of the content on this site are subject to the Apple Support Communities Terms of Use.