How do I resolve error code -8062 on Mac mini 2023 running macOS Sequoia 15.4?

Hey all, I was trying to copy a folder from my desktop onto my portable hard drive, and it appeared that the process did not complete.


When I tried again, it said "a partial copy of the folder has been detected. Do you want to resume?"


When I click "resume", I get "The operation can't be completed because an unexpected error occurred (error code -8062).


How do I resolve this error code? Is there a way to just stop the partial copying and start the process over? I'd welcome any tips to fix this.


I'm running Sequioia 15.4.1 on a Mac Mini 2023.


Thanks!


[Re-Titled by Moderator]

Mac mini, macOS 15.4

Posted on Apr 28, 2025 3:05 PM

Reply
Question marked as Top-ranking reply

Posted on May 2, 2025 9:21 AM

Hey, no worries at all—you’re not being a pest. You're clearly trying to fix a frustrating issue. The output you're seeing from the dot_clean command is actually pretty common, especially when it's run on volumes that include system-level or hidden metadata directories. Let me break it down for you.


The warnings like:

Failed trying to change dir to .DocumentRevisions-V100  
Bad Pathname: Operation not permitted  

are referring to hidden system directories that macOS uses for its internal housekeeping—things like Spotlight indexing (Spotlight-V100), temporary files (.TemporaryItems), and the trash (.Trashes). These directories are usually protected by System Integrity Protection (SIP), or you may not have permission to access them without elevated privileges (and in some cases, not even then). The dot_clean tool is just saying, “Hey, I tried to enter this folder, but I’m not allowed to.” It’s not a big deal and won’t affect your main goal.


Now, as for those two stubborn folders giving you the -8062 error—this typically means the Finder is running into trouble merging directories or dealing with resource forks, or there’s a locked/in-use file somewhere in those folders.


Here’s what I’d suggest trying next:


Try dot_clean specifically on the problem folders:

  • Instead of running it on the whole volume, run: dot_clean /path/to/problem_folder
  • Replace with the actual path to the folders giving you trouble.


Ensure SIP isn't the issue:

  • If you’re working on an external drive or shared volume, make sure the disk isn’t set to be read-only, and check in System Preferences > Security & Privacy > Full Disk Access that Terminal has access. Add it if it’s not already there.


Check for locked or in-use files:

  • Right-click the files in the problem folders > Get Info > see if “Locked” is checked.
  • Also, use lsof | grep <filename> in Terminal to see if a process is using the file.


Try Safe Boot or copy via Terminal:

  • Boot into Safe Mode, and try copying the folders again.
  • Or use: cp -R /path/to/problem_folder /destination/path
6 replies
Question marked as Top-ranking reply

May 2, 2025 9:21 AM in response to Freelance_Lady

Hey, no worries at all—you’re not being a pest. You're clearly trying to fix a frustrating issue. The output you're seeing from the dot_clean command is actually pretty common, especially when it's run on volumes that include system-level or hidden metadata directories. Let me break it down for you.


The warnings like:

Failed trying to change dir to .DocumentRevisions-V100  
Bad Pathname: Operation not permitted  

are referring to hidden system directories that macOS uses for its internal housekeeping—things like Spotlight indexing (Spotlight-V100), temporary files (.TemporaryItems), and the trash (.Trashes). These directories are usually protected by System Integrity Protection (SIP), or you may not have permission to access them without elevated privileges (and in some cases, not even then). The dot_clean tool is just saying, “Hey, I tried to enter this folder, but I’m not allowed to.” It’s not a big deal and won’t affect your main goal.


Now, as for those two stubborn folders giving you the -8062 error—this typically means the Finder is running into trouble merging directories or dealing with resource forks, or there’s a locked/in-use file somewhere in those folders.


Here’s what I’d suggest trying next:


Try dot_clean specifically on the problem folders:

  • Instead of running it on the whole volume, run: dot_clean /path/to/problem_folder
  • Replace with the actual path to the folders giving you trouble.


Ensure SIP isn't the issue:

  • If you’re working on an external drive or shared volume, make sure the disk isn’t set to be read-only, and check in System Preferences > Security & Privacy > Full Disk Access that Terminal has access. Add it if it’s not already there.


Check for locked or in-use files:

  • Right-click the files in the problem folders > Get Info > see if “Locked” is checked.
  • Also, use lsof | grep <filename> in Terminal to see if a process is using the file.


Try Safe Boot or copy via Terminal:

  • Boot into Safe Mode, and try copying the folders again.
  • Or use: cp -R /path/to/problem_folder /destination/path

Apr 28, 2025 10:46 PM in response to Freelance_Lady

That error code -8062 on macOS usually pops up when Finder runs into trouble dealing with partially completed copy or move operations—especially if the destination has some residual data that doesn’t quite match up with what you're trying to copy again.


See if the following can help:


Delete the partial copy manually:

  1. Open the destination folder on your external drive.
  2. Look for the folder that partially copied. You might see a “._” version of it or it might look complete but missing data.
  3. Move it to the Trash and empty the Trash. If it won’t delete, try holding Option and choosing Secure Empty Trash (or use Terminal as noted below).


Eject and reconnect the drive:

  1. Eject the portable drive from Finder.
  2. Unplug it, wait a few seconds, and plug it back in to reset the I/O connection.


Reset Finder’s copy state:

  • Simultaneously select Cmd + Option + Esc, and then, Force Quit Finder. It should restart Finder automatically and clear any hung operations.


Clear metadata files (optional but helpful):

  • Open the Terminal app (it is located in /Applications/Utilities) and enter:


dot_clean /Volumes/YourDriveName


  • Press the <enter> key after entering the command to execute it. You can then type: exit <enter> to close the Terminal.
  • "YourDriveName" should be replaced with the actual name of your destination drive as it appears in Finder or under /Volumes.
  • This removes AppleDouble files like ._filename, which can cause issues on external volumes formatted for Windows (like exFAT or FAT32).


Now try the copy again:

  • Drag the folder from your Desktop to the external drive like usual.


If the issue keeps repeating, it’s worth checking your external drive with Disk Utility for any minor corruptions (use First Aid) or consider reformatting the drive if it's been used across multiple platforms.

Apr 29, 2025 7:28 PM in response to Freelance_Lady

Let’s start with the dot_clean error. The syntax you used — dot_clean/Volumes/MB — is missing a space. Terminal interprets that as a file or folder named literally “dot_clean/Volumes/MB,” which doesn’t exist. The correct command should be: dot_clean /Volumes/MB


There is a space after dot_clean and /Volumes/MB.


This command removes hidden “dot” files (.DS_Store, resource forks, etc.) that can interfere with file transfers, especially to non-Mac volumes like your WD Elements (which I’m guessing is formatted as exFAT or NTFS — both of which can be picky about those metadata files). Run that, and it should complete silently if all goes well.


Now, about Secure Empty Trash — My error, sorry about that. Apple actually removed that feature back with OS X El Capitan. The reason, I understand, was that SSDs don’t reliably “secure erase” sectors like spinning drives do, so it gave a false sense of security. It’s not in the Finder anymore. If you're trying to force-delete a stubborn file, though, you can use this in Terminal: sudo rm -rf /Volumes/MB/path/to/folder


However, you can ignore this step since you already cleaned out the folder.


Last thought: since you're saying only one specific folder refuses to copy, try this — compress it first into a ZIP file (right-click > Compress) and then copy that ZIP file to your WD drive. That avoids the metadata conflicts altogether. If that works, it points to something funky in the folder's metadata structure.

Apr 29, 2025 10:24 AM in response to Tesserax

Thanks for the suggestions. I tried all of the above, but it didn't seem to help.


Where is the "secure empty trash" command? I didn't see it under Finder or right-clicking the can. I was able to empty the grayed out folder. I restarted, remounted the drive and tried the copy process fresh again. It went for about 3 seconds and then I got the error message.


When I did the command on Terminal, I got this response:

zsh: no such file or directory: dot_clean/Volumes/MB

mb@Mariannes-Mac-mini ~ %


This error occurred after I updated to the current Sequoia version. I was running Ventura prior to this big update and didn't have an issue with copying to my portable hard drive. It is a WD elements drive, if that means anything. I am able to copy other folders to this drive without issue. Just not the one I want to copy.


I really your help. Hoping you have some other tips that might do the trick.





May 1, 2025 1:02 PM in response to Tesserax

Hi Tesserax — I ran the corrected dot_clean command in Terminal and got this response:


Failed trying to change dir to .DocumentRevisions-V100

Bad Pathname: Operation not permitted

Failed trying to change dir to .Spotlight-V100

Bad Pathname: Operation not permitted

Failed trying to change dir to .TemporaryItems

Bad Pathname: Operation not permitted

Failed trying to change dir to .Trashes

Bad Pathname: Operation not permitted


What does this mean? Also, it is two folders that generate the -8062 error. All other folders copy to just fine. Sorry I am being a pest. Just trying to fix this. I am greatful for your help.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

How do I resolve error code -8062 on Mac mini 2023 running macOS Sequoia 15.4?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.