MacOS – Files gone after disk utility repair tool. however, space on disk remains

external-diskhard drivemacos

I stupidly repaired my external hard disk without backing it up via mavericks's disk utility repair option.

After the repair, all my folders disappeared but at the same time I noticed that the disk space still remained the same. Is there anyway to get these files back? My thesis is on it.

 See capacity and number of files

when running disk repair again, it managed to find the files but at the same time it doesnt restore it

enter image description here

enter image description here

Best Answer

Set the Finder to show invisible files. The following Applescript will toggle that on/off.

The report says files were moved to a folder called "." which will be invisible. If you're lucky they may be in there... otherwise it's time for Disk Drill or Data Recovery Data Recovery [neither of which are free]

The next things to do will be, in order...

  1. Invest in a backup strategy; Time Machine, Backblaze etc & use it.
  2. Throw that drive out & use an HFS+ formatted drive, with Journalling - because Mac's support for NTFS is not great.. & by default can't write or repair NTFS, so you either have Paragon or similar or you enabled it via Terminal.

Toggle Invisibles Applescript [copy/paste to Applescript Editor, save as Application]

        --Toggle Invisibles
    tell application "Finder"
        try
            -- on launch check invis files state, if invis, switch to vis
            set onOff to do shell script "defaults read com.apple.finder AppleShowAllFiles"
            if onOff = "NO" or onOff = "OFF" then
                my showAllFiles()
            else
                my hideAllFiles()
            end if
            my testFinderRunning()
        end try
    end tell

    --Finder Visible & relaunch sub-routine
    on showAllFiles()
        do shell script "defaults write com.apple.finder AppleShowAllFiles ON"
        tell application "Finder" to quit
        delay 3
        try
            tell application "Finder" to activate
        end try
    end showAllFiles

    on hideAllFiles()
        --try
        set onOff to do shell script "defaults read com.apple.finder AppleShowAllFiles"
        do shell script "defaults write com.apple.finder AppleShowAllFiles OFF" --OnOffCommand
        tell application "Finder" to quit
        delay 3
        try
            tell application "Finder" to activate
        end try
    end hideAllFiles

    on testFinderRunning()
        set test to 0
        --try
        repeat while test = 0
            log test
            tell application "System Events" to set test to count (every process whose name is "Finder")
            delay 2
            --we do this even if active because it doesn't naturally come to front
            try
                tell application "Finder" to activate
            end try
            if (test > 0) then exit repeat
        end repeat
    end testFinderRunning