iCloud sync issues

Looking at the iCloud log might also help with troubleshooting.
For reference, the log files for iCloud for Windows can be found at

C:\Users\USERNAME\AppData\Local\Packages\AppleInc.iCloud_HASHCODE\LocalCache\Local\Logs

there is also a iCloud sync issue with the “recent files” plugin. Especially when renaming files on a PC this can cause issues because the old file still shows up in the “recent file” list on the mobile app and then gets recreated.
Otherwise not a big issue in my opinion.

4 Likes

I had the same problem with the iCloud sync. I managed to solve it by uninstalling the Microsoft store version of iCloud app… instead I installed a desktop iCloud app. It’s been working great so far, no duplicates are appearing.

3 Likes

do you have a link for where to download the “desktop iCloud app”?

You have to download iCloud on the Microsoft store.

I went to the official website, Download iCloud for Windows - Apple Support, and there I used the link for a non-store version of the app designed for Windows 8 and above (I have windows 10 and had no problem installing it). This way you install iCloud version outside of the Microsoft store.

10 Likes

Just adding a few more observations for future reference:
I use the “homepage” plugin to open my home note every time I launch obsidian. The home note has a couple of embedded graphics on top.
On the iPhone and iPad app I sometimes get an error “file note created” for one of the graphics. When I do a command/reload it shows the graphic.

So it seems it’s not a “syncing issue” with new or updated files, more of an issue locating existing files. Is there a developer option to display all the files obsidian has indexed?

Another issue I had on the iphone where the contents of the daily note disappeared before my eyes, the screen just went blank. I checked the iCloud drive and confirmed that the iphone had created an emtpy …(1).md version of that note. But when clicking “copy Obsidian URL” it was showing the original .md file without the (1).

So the app tries to read a .md file but can’t find or access it? Then it tries to create that file but the iCloud drive knows it’s there an creates a …(1) copy.
Maybe the app should check for the file location of any newly created file and if it contains a (1), etc it should show a warning to the user because this should never occur.

1 Like

it happened again, I was appending text to my daily notes/2021-12-24.md file on the iphone app. Then the note suddenly closed. I checked the iphone “files app” and the file was not in the iCloud drive.
On the PC the file showed fine with a green checkmark and it includes the last word I typed on the iphone just before it closed. Timestamp of file is 11:20am

iCloud log for that file:

[11584 @ Fri Dec 24 2021 07:48:08.940]	12972	ERROR	BRC::DocDownloadOp::DoMove	Error 5 moving file C:\Users\uwe\AppData\Local\Packages\AppleInc.iCloud_nzyj5cx40ttqa\LocalCache\Local\Apple Inc\iCloudDrive\Staging\03B62F90-2FB2-43A8-8A4C-6D564B584B84.bin to C:\Users\uwe\iCloudDrive\iCloud~md~obsidian\Obsidian\Daily Notes\2021-12-24.md

[11584 @ Fri Dec 24 2021 09:10:11.275]	12832	ERROR	SetPlaceholderSyncState	Failed to mark 'C:\Users\uwe\iCloudDrive\iCloud~md~obsidian\Obsidian\Daily Notes\2021-12-24.md' sync state: 0x80070178: The file is not a cloud file.

(C:\Users\uwe\iCloudDrive\iCloud~md~obsidian\Obsidian\Daily Notes\2021-12-24.md): Signature changed after upload: (17,3002)
[11584 @ Fri Dec 24 2021 09:09:50.671]	12624	ERROR	CKW::ModifyRecordsOperation::UploadAssets	Failed to upload asset |fileContent|2021-12-24.md for record 

At the same time the obsidian on my PC froze for the top 4 buttons, not sure if that’s related.
Screenshot 2021-12-24 114120

command/reload fixed the issue with frozen nav.
When editing that note on the PC it synced again and showed up on the iphone app …

I do have automated backups from the iCloud to dropbox with the dropbox plugin and it ran 5 minutes before the issue started …

I also discovered that a 2021-12-14.md file is in the iCloud Drive/.trash folder with the same 11:20 timestamp and a “blue cloud” (the file is stored in iCloud drive and hasn’t been downloaded to your computer). When opening the file it shows one more word that I typed before the iphone app closed the note.
That .trash folder is 2 levels higher than my obsidian iCloud vault (which is at iCloud Drive/Obsidian/Obsidian)

Not sure what that all means, just documenting for future reference, maybe a core developer can use it to find the issue.

Obsidian requires all the files in its open vaults to be local and available.
afaics, your iCloud setup may not sustain that.

Users using problem-free Google Drive systems found problems start when Drive switched to streaming from the cloud; and disappeared again when they kept the vaults local.

2 Likes

not sure if I understand. Are you saying that there are different ways to setup the vault in an iCloud drive?

I too am dying in the land of iCloud syncing. Mined stopped working yesterday. Ironically just as I was committing to go all in on Obsidian.

I’ve rebooted, deleted Obsidian out of my cloud drive. Reenabled it and copied the data back. …

What magic is there left to invoke? I can tell deleting from the iCloud worked since both my phone and iPad have lost access to the vault.

1 Like

idk, having avoided iCloud for a long time. Some users appear to have no problems with Obsidian but others have recurrent issues. If it shifts files to cloud expecting to stream them fast enough on demand, then that might not always work with Obsidian; but I don’t know enough to know that’s what is going on.

You can try to check by having a purely local vault, only syncing when Obsidian has closed the vault. Maybe your Dropbox backup clashes with Obsidian (or with iCloud).

I think it’s most likely to be an iCloud issue rather than an Obsidian one though. I doubt Obsidian works the way iCloud expects.

I’m too starting to get really tired of this issue with iCloud. In my case, it works fine for everything else except Obsidian files!

Once every week I have to try a few times of enable/disable the service, reboot, force kill…etc to get things back to work.

I was experiencing this issue on Windows 11 where iCloud would create multiple copies instead of updating the original copy. I followed @erik1131 post and installed the non-Microsoft version of iCloud. And that seemed to have solved the issue.

4 Likes

Hi, there. I’m also tyring this win7/8 version iCloud.

May I know can you still see the update status of files in the “iCloud Drive” folder?
It seems to take forever to upload any file from windows :cry:

To check upload status quickly, you can look for the iCloud icon in the taskbar (right side of taskbar), and click on it. It gives you an idea of whether it’s uploading or has updated. I also checked the number of files on iCloud.com for what files are actually on iCloud (vs what just exists in the Windows folder) → as a indicator of whether syncing was actually progressing.

Also trying the installer from the Apple website and from preliminary tests with a new vault all the problems seem to be fixed! Vis a vis seemingly random file duplication and reverting of files to older versions while editing.
However, what I’ve found is that there will be file duplication if the vault isn’t fully synced before opening in Obsidian. When it seemed like the upload was stalling (still the same number of files displayed on iCloud.com over a few minutes), I restarted the computer and within a few minutes my vault (~1.6k notes) was fully synced.
I haven’t experienced any problems since! But as it’s only been an hour or two, will report back if there’s more problems.

I believe I have found the cause of the problem!
According to my observation, the synchronization period of iCloud on windows is much longer than expected (10 minutes+). It will only attempt to synchronize after the file has been modified on the windows side, and at that time, a conflict has occurred.
The solution is simple, you can try to create a temporary file and delete it when you open obsidian, this will trigger the iCloud sync, and then you can take your notes. (This function can be considered to write a plug-in implementation)
Hope useful.

2 Likes

I don’t know what you mean, could you explain it more clearly?

Wow. That’s very detailed. Much appreciated!

Luckily after 1 or 2 days, the whole process is working great for me on this win7/8 version.

I do need to check the status on iCloud icon with roughly how many files are syncing, although we can check the exact upload status of every file on the win10 from the Microsoft store.

I haven’t came across the problem you’re facing, maybe try @bbluray method?

1 Like

Does the version downloaded from Apple’s website has the same functionality as the windows version ? Or to put it differently are they somewhat the same or is there are a lot of discrepancy? Asking, because I do use the bookmarks and passwords sync from icloud.