Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

The Finder can’t complete the operation because some data in “filename.m4a” can’t be read or written. (Error code -36)" Can't fix

This has been asked before and nobody replied. I am hoping somebody does this time as this is causing me hours of wasted time and I can't solve it.


I am running OS Sierra and I am trying to move my iTunes music folders onto a Sandisk 64GB SD card (micro SD actually, in an SD adapter).


I have tried around 15 times, each time trying some tip I read about online, mainly the dot_clean function (on the source folder, destination volume, iTunes folder and dragged them out again etc). Nothing works, every time I get the error "

The Finder can’t complete the operation because some data in “filename.m4a” can’t be read or written. (Error code -36)"

N.B. THE FILE NAME CHANGES EVERY TIME. What I did the first few times was just delete the file, I can go without one track in the car! I did this many times and every time, the file transfer runs half the day then fails on a new filename unlike one seen before. I could go on forever like this so I tried to solve it using dot clean and this hasn't helped or changed any behaviour at all.


The SD Card is formatted to EXFAT, but I tried MSDOS too and that did the same thing.


Would greatly appreciate any ideas. The only thing I know of which I have not tried is the dot_clean terminal command which deletes ALL .DS_Store files on the whole machine. That seems a bit drastic to do before asking for advice on the forums, so I am waiting on that, also I am not sure it's actually a problem with .DS_Store files, as the filename is always an xxxx.m4a file.


Hoping someone can suggest something? thanks

iMac, Mac OS X (10.7.4), 12 Gig RAM, 3.1ghw i5

Posted on Mar 25, 2018 2:56 AM

Reply
Question marked as Best reply

Posted on Mar 25, 2018 4:42 AM

Here are some things worth trying:

  1. Run Disk Utility : First Aid on that SanDisk microSD card.
  2. If you have the ability to perform the Finder copy to an SD card not in the microSD adapter, try that too. Sometimes, and it happened to me, that micro to SD adapter causes write issues.
  3. The dot_clean(1) utilty says nothing about removing .DS_Store files. It is after “._” files on the target media — if they exist.

Similar questions

17 replies
Question marked as Best reply

Mar 25, 2018 4:42 AM in response to joeyjohnson

Here are some things worth trying:

  1. Run Disk Utility : First Aid on that SanDisk microSD card.
  2. If you have the ability to perform the Finder copy to an SD card not in the microSD adapter, try that too. Sometimes, and it happened to me, that micro to SD adapter causes write issues.
  3. The dot_clean(1) utilty says nothing about removing .DS_Store files. It is after “._” files on the target media — if they exist.

Apr 28, 2018 9:13 AM in response to joeyjohnson

Probably a long shot, but try setting up another admin user account to see if the same problem continues. Also try the Safe Mode.


Isolating an issue by using another user account


Safe Mode - About


Safe Mode Startup – El Capitan. also Sierra


If it works in the Safe Mode, try running this program when booted normally and then copy and paste the output in a reply. The program was created by Etresoft, a frequent contributor. Please use copy and paste as screen shots can be hard to read. Click “Share Report” button in the toolbar, select “Copy to Clipboard” and then paste into a reply. This will show what is running on your computer. No personal information is shown.

Etrecheck – System Information

Mar 25, 2018 5:15 AM in response to joeyjohnson

The things you've read about dot_clean would only apply to ._ files. If the error message lists a file name that doesn't begin with ._, then the file is corrupt and can't be read (or written). Dot underbar files are macOS's way of passing metadata to a non metadata-capable file system.


Finder quits when it runs into an error. You may want to try using ditto in the Terminal as it will continue the copy operation for most errors. Since you are copying to ExFAT, use the options to exclude metadata and extended attributes.

ditto --norsrc --noextattr --noacl src_directory dst_directory

Type man ditto in the Terminal to learn how to use. Also likely there are some tutorials online.

Mar 25, 2018 5:50 AM in response to Barney-15E

Excellent thanks. Ditto in Terminal - hmm that's a new one on me.

If the destination directory if the root of SD card, I assume I just need /Volumes/SDcard in there?

Thanks, I am running it again at the moment but when it fails (99% sure it will!) I will try that, as I wouldn't care if it just skipped the bad file and carried on, it's a real pain with Finder quitting on me!

thanks again

Mar 25, 2018 2:34 PM in response to VikingOSX

ditto --norsrc src_directory dst_directory does the same thing because --norsrc also implies --noextattr and --noacl. Probably could additionally use the no quarantine flag though --noqtn.


Yeah, that's what I read (and remember from previous OS's), but it also says it does so to match 10.4 behavior. At this point it still implies both, but I wonder if it will change in the future.

Apr 17, 2018 4:05 AM in response to Barney-15E

Ok, this is rapidly turning into a real nightmare! I will try to give as much detail and some context in case something is missing from my explanation, but I can not fathom any reason why I can't do what I am trying to do, and after maybe 50+ attempts, I am ready to give up but I can't, so here goes! Hope someone has some ideas, truly grateful if so...


I have a Mercedes car which has a stereo with SD Card slot. I am trying to move my entire iTunes library onto a MicroSD card, which when used with an SD card adapter should work in the stereo. I have managed to test it and it all works when I just dropped 10 tracks onto a micro SD card, so I know it will work, IF I can get my entire library on there. This is where the problem lies.


I have pulled out all folders from the home/Music/iTunes/iTunes Music folder and dropped them (copied) into a folder on my desktop, just for ease. I have bought THREE brand new micro SD cards, two Samsung Evo+ and one Sandisk. I have the same problem with all, suggesting it's not a card issue. I suspect the issue is formatting problems as I have tried on Mac and Win7 laptop. I have tried using the in built card reader (iMac 2011) and a third party USB card reader, and the built in Dell card reader on laptop, again, nothing helps so I don't think it's a card reader/slot issue.


I began by inserting the micro SD into the SD card adapter, and into the iMac. I formatted to EXFAT with MBR (running OSX 10.12.6), I then tried dragging (copying) all my 52GB of music folders onto the 64GB micro SD card. After around 10 minutes it errors, and ejects the card. Various reasons given and the reasons seem to change. The first time was given above in this thread, suggesting its a DS STORE file issue. I ran dot_clean on the music folder on my desktop to clear all those hidden files (honesty not sure it worked, but did it a few times and hoped it did). But after that first error, the card couldn't be read. It was like the SD slot on the iMac switched off. Rebooting didn't help. That's when the Win7 Dell Laptop came into play. I inserted card in there and formatted it on Windows. I could then (sometimes) manage to see it on the iMac when plugged in again on here. So, I ran the whole process again, again getting another error on a different file name but a similar error - "error code -36".


I then tried another card in case it was a card issue. Same thing happened. I then tried 3rd card, same thing happened. I tried different SD card adapters, and my USB card port, nothing changed any of the results. It would take hours to get the card to be readable in the mac before I could try transferring files again. Again failing on some file within 10-30 minutes.


tearing hair out, I decided the mac just can't do it. I then moved all the music folders to the laptop using a Sandisk Extreme USB thumb drive. I then tried formatting the cards on windows and dragging and dropping on Win7 instead. Then I get "semaphore timeout period has expired" or other errors and it all goes wrong again. I spent a day or two trying to fix the Windows problems, but nothing worked. I also found HUNDREDS of hidden files in the music folders on Windows, when I viewed hidden files. Many of them were DS Store files, so much for dot_clean terminal command clearing the music folder of all those?! (And i ran it again just before moving the folders to the thumb drive.)


So, back to the mac! yesterday I started anew. I had a few days off and came back to the problem with a clear head, Googling all the while and reading all the Apple threads I could find on this stuff. I tried formatting to MSDOS file system, no change, all the same problems when transferring files. I then tried EXFAT again, and started dragging all the folders across to the micro SD card. Another "new" error was the excuse this time for failure! see screenshot (remove ****) https:****//snag.gy/9eiEhq.jpg


I then (having done this many times already) tried the ditto terminal command. This is the command i used :


ditto --norsrc --noextattr --noacl sourcefolder onto\ destfolder


I was advised this would skip over any errors (which is fine, I don't care if a few files can't be moved, just as many as possible would be great. But even this fails with tons of errors: (remove ****) https:****//snag.gy/D1y0XQ.jpg


I am really now out of any ideas. Can anyone offer some guidance please?

Thanks

Apr 17, 2018 7:28 AM in response to joeyjohnson

As I mentioned previously, dot_clean only removes ._ files, not .DS_Store files or any other .files.


It would appear that ditto is trying to download the files linked at the URLs. I can’t find anything in the man page to indicate it follows hyperlinks. Not sure where it is finding them, though, but there is likely a ton of stuff in the iTunes Library. Did you copy the album folders, or the entire Library?

Apr 17, 2018 6:26 PM in response to joeyjohnson

The permission denied lines on your screenshot seems to indicate that it fails because where it needs to write doesn’t have write permission (for you).

Either the SD card is locked or the SD volume or your source files and folders have permissions that block it.

A read-only locked SD card would show a pencil with a slash through it in one of the corners in the Finder window.

Apr 18, 2018 3:46 AM in response to Barney-15E

Thanks Barney. Do you think I need to remove ALL ._ files or is that unlikely to be the problem?


"It would appear that ditto is trying to download the files linked at the URLs" - Sorry, what URLs? I don't understand, I don't see any URLs and don't see how the web is involved. These files are locally stored in folder and going on locally inserted SD card, bit confused here.


Does anyone know a way to put all iTunes music onto a Micro SD Card successfully?

Apr 26, 2018 5:41 AM in response to joeyjohnson

Anybody? Please?!


I really wonder whether using an SD card on a mac KILLS it, can anyone comment?

I have bought no less than FOUR brand new microSD cards now, all of which have been formatted on the Mac, and NONE of which are usable in ANY form any more. Undetected when inserted in mac OR PC 😟


I am starting to wonder, if you have any requirements for use of an SD card (driving camera, digital photo frame.... anything non mac based), then just by plugging it in ONCE into an Apple machine permanently destroys it. That appears to be whats going on here, and its not a hardware issue.

The Finder can’t complete the operation because some data in “filename.m4a” can’t be read or written. (Error code -36)" Can't fix

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