Stuck on Loading cache

I am on Win10 and Obsidian no longer opens. Gets stuck on “loading cache.” In the past, if I reinstalled or open and closed a few times, it would eventually open. Now it doesn’t open at all. I have it trying to open the background and let it run for a few days to see what happens. I am currently using iA writer to navigate my vault. I hope this gets fixed at some point.

Solution on MacOS, possibly useful on Windows/Linux

I was able to clear out the cache by

  1. Exiting Obsidian ← important
  2. going to the ~/Library/Application\ Support/obsidian/Cache/Cache_Data directory and remove all its files, either in the Finder:

or in the terminal with

if [[ -d ~/Library/Application\ Support/obsidian/Cache/Cache_Data ]] ; then
    rm -rf ~/Library/Application\ Support/obsidian/Cache/Cache_Data/*
else
    echo "Something odd has happened"
fi
  1. Restarting Obsidian and voila!

I hope this helps

3 Likes

Thanks @wealthychef . I don’t have that folder or file except in the roaming folder. I deleted that, but no change.

I’m sure you realized it, but the key piece would be the obsidian/Cache/Cache_Data part; the rest is highly mac-specific. The equivalent folder must exist somewhere on your machine! :slight_smile:

Cheers, that’s all I know for now. :slight_smile:

Yeah, that’s what’s weird. No such directory or file—anywhere. I have an obsidian roaming folder I deleted, but that didn’t help. Thanks for trying.

Try the %%APPDATA%% directory. How Obsidian stores data - Obsidian Help

C:\Users\rcook>cd %APPDATA%\Obsidian\

C:\Users\rcook\AppData\Roaming\obsidian>dir
 Volume in drive C has no label.
 Volume Serial Number is 4607-95DA

 Directory of C:\Users\rcook\AppData\Roaming\obsidian

12/21/2022  09:52 AM    <DIR>          .
12/21/2022  09:47 AM    <DIR>          ..
12/21/2022  09:47 AM    <DIR>          blob_storage
12/21/2022  09:47 AM    <DIR>          Cache
12/21/2022  09:47 AM    <DIR>          Code Cache
12/21/2022  09:51 AM    <DIR>          databases
12/21/2022  09:47 AM    <DIR>          GPUCache
12/21/2022  09:47 AM                32 id
12/21/2022  09:51 AM    <DIR>          IndexedDB
12/21/2022  09:47 AM               389 Local State
12/21/2022  09:47 AM    <DIR>          Local Storage
12/21/2022  09:47 AM                 0 lockfile
12/21/2022  09:48 AM    <DIR>          Network
12/21/2022  09:51 AM               121 obsidian.json
12/21/2022  09:47 AM                 0 obsidian.log
12/21/2022  09:52 AM                97 Preferences
12/21/2022  09:52 AM            40,960 QuotaManager
12/21/2022  09:52 AM                 0 QuotaManager-journal
12/21/2022  09:51 AM    <DIR>          Session Storage
               8 File(s)         41,599 bytes
              11 Dir(s)  248,776,716,288 bytes free

C:\Users\rcook\AppData\Roaming\obsidian>

Yes, that’s the one I deleted. Unfortunately, didn’t help. Frustrating.

1 Like

Have you tried removing the IndexedDB folder? If you use Obsidian Sync, you will have to connect it to the remote vault again. Alternatively you can delete just the -cache listings from within Obsidian and restart (in Developer tools).

If that doesn’t work, I’d get rid of that whole directory and reinstall. (Make backups of your vaults, etc)

1 Like

I know this may be another obvious thing, but have you tried renaming $VAULT_DIR/.obsidian to $VAULT_DIR/.obisidan.tmp and see if that fixes it? I don’t see that you’ve checked the possibility of a corruption somewhere there.
If that allows normal startup, then you know wehere the problem is physically on disk.

I just encountered this issue and this seems to help. Renamed the vault and copied back the plugins and themes. Seems to work.

@cs-mshah I am curious, how did you change the vault name? What do you mean by “copied back the plugins and themes?” I would like to try this but don’t want to create a mess. Thanks for the tips.

Sorry, I meant I renamed the .obsidian to .obsidian.tmp and copied back the plugins and themes. Basically I found that a few json files were causing the issue. So you can basically delete some of your json files and they will get regenerated. But anything works.

1 Like

Thank you. I will give this a try.

Has anyone actually managed to solve this once and for all?

Not yet

Has anyone else tried Divide and Conquer or Plugin Groups to narrow it down? I did but somehow wasn’t successful

I was facing the same problem.
I tried deleted the cache folder, but that didn’t work.
What did the trick (and then some!) was changing the obsidian project file to [obsidianvault].temp, opening the vault, closing the vault, and renaming it back to the original. It’s been lagging for a few days, and now it’s fast as heck, once again.
Someone above mentioned they had moved around a lot of folders and files–I had done the same right before this issue came up. Sync was overloaded past the 10GB limit, and the whole thing was slowing down substantially. Glad to know this fix.

3 Likes

When you say change the obsidian project file name, do you mean the vault name?

1 Like

No the name of the hidden .obsidian file that sits at the root of your vaults directory.

On Mac in the finder press shift + cmd + . to show hidden files.

So changing the folder .obsidian to .obsidian.temp on a mac? That didn’t do anything

1 Like