Large vault - Obsidian not closing properly- not able to re-open (stuck in IndexedDB.open)

Steps to reproduce

  1. Ensure fresh start to avoid any weird contamination (delete .obsidian folder, delete AppData obsidian folder, fresh install, etc.)
  2. Open an Obsidian vault with ~90k notes.
  3. Close Obsidian.

Did you follow the troubleshooting guide? [Y/N]

Y

Expected result

Nothing involving Obsidian shows in Task Manager:

Screenshot 2025-02-01 204029

Obsidian is able to open as normal on a re-launch.

Actual result

Obsidian.exe remains in Task Manager:

Screenshot 2025-02-01 203650|200

If you try and re-open Obsidian with that task still there, you get this error:

An error occured while loading Obsidian. UnknownError: Internal error opening backing store for indexedDB.open.

Environment

SYSTEM INFO:
Obsidian version: v1.8.4
Installer version: v1.8.4
Operating system: Windows 11 Home 10.0.26100
Login status: not logged in
Language: en
Insider build toggle: off
Live preview: on
Base theme: adapt to system
Community theme: none
Snippets enabled: 0
Restricted mode: off
Plugins installed: 0
Plugins enabled: 0

RECOMMENDATIONS:
none


Current Workaround(s)

Open Task Manager and close Obsidian between each launch.

Additional information

What happened immediately before this issue showed up

I haven’t added anything recently that could have caused this, just notes in plain English; it just randomly decided to start playing up as I was adding notes and moving links around.

The first clue that something was wrong was that the Omnisearch plug-in stopped working, it just showed as blank when I tried to open it, then after a restart to try and fix it I started getting that error message and had the most confusing time trying to fix things.

Assumptions

I have gone with a fresh installation with no plug-ins and the issue remains, so I’m not sure if Omnisearch just knew what was up or whether that was somehow related.

Obsidian is able to properly close and be re-opened normally using the test vault, so I’m assuming the issue is to do with the amount of files in my vault.

I’m presuming this IndexedDB error shows up when you load Obsidian because IndexedDB is already being read, and so the application is unable to open it twice.

Most likely an OS-independent issue

I actually uninstalled Fedora OS (Linux) and installed Windows 11 on my laptop to try and fix this: same issue, so I’m assuming this is an OS-independent issue. I imagine the task stayed on Fedora as well, though I wasn’t able to check at the time.

Vault information

The exact number of notes is 89,822 notes.

I have two base sub-folders, 10_Meta and 90_Notes:
Screenshot 2025-02-01 205739

10_Meta folder (attachments: JPG, PNG, JPEG):
Screenshot 2025-02-01 210200

In 10_Templates (Scripts has JS files, Templates has .md files):
Screenshot 2025-02-01 210218

All other markdown notes are contained within a single folder (90_Notes):
Screenshot 2025-02-01 205739

In the vault I have basic image attachments (JPG, JPEG, PNG), and a bunch of notes that are linked together, though I don’t have any fancy files in there or really much in terms of weird characters. The vault is predominately English (some German), though includes generally long file names and some file names contain emoji characters.

I suspect that I may have done something to cause Obsidian to need to re-index everything, and the issue stems from that. I’ll know more for sure once it’s completed.

thanks, I have been able to reproduce something similar.

1 Like

This also seems to corrupt Obsidian if you attempt to load your vault again; not totally sure on this though it seems to be repeatedly happening for me.

It just gets stuck on “Loading workspace…” and doesn’t actually load.

Do you have any solution to this?
I just re-downloaded (using Obsidian Sync) my whole 30k file vault… And now it’s broken again.

In the meantime, you an leave Obsidian open and let if finish the indexing process.

Thank you for your reply.
I removed some plugins, and now it looks like it’s working. Not sure if it’s related but, what I have now is:

SYSTEM INFO:
	Obsidian version: v1.8.5
	Installer version: v1.8.4
	Operating system: Windows 11 Pro 10.0.26100
	Login status: logged in
	Language: en
	Catalyst license: insider
	Insider build toggle: on
	Live preview: on
	Base theme: dark
	Community theme: none
	Snippets enabled: 4
	Restricted mode: off
	Plugins installed: 15
	Plugins enabled: 9
		1: Calendar v1.5.10
		2: Natural Language Dates v0.6.2
		3: Tasks v7.14.0
		4: Templater v2.9.2
		5: Text Format v3.1.0
		6: Settings Search v1.3.10
		7: Tag Wrangler v0.6.1
		8: Git v2.31.1
		9: Homepage v4.1

And before I had also installed/enabled:

  • Dataview
  • Enhancing Export
  • Excalidraw
  • Omnisearch
  • Plugin Update Tracker (this one was updated today)
  • Text Extractor

Platform:

  • Operating System: Fedora Linux 41 (X11)
  • Kernel: 6.12.11-200.fc41.x86_64
  • Processor: Ryzen 7 3700X
  • RAM: 32GB
  • Disk: 512GB SSD

Obsidian Version:

  • Application version: v1.8.4
  • Installer version: v1.8.4

Issue Description

Obsidian does not close gracefully when exiting via the GUI, leading to an IndexedDB lock issue. This causes startup issues due to the locked database file (LOCK in the IndexedDB directory), preventing the LevelDB database from opening correctly.

Symptoms:

  1. Obsidian Process Remains Active

    • After closing Obsidian via the GUI, multiple obsidian processes remain running:
      pgrep -fl obsidian
      12555 obsidian
      12560 obsidian
      12561 obsidian
      12563 obsidian
      
    • Some processes remain as <defunct> (zombie processes) even after trying to restart the application.
  2. IndexedDB Lock Issue

    • When restarting, the following error appears repeatedly in logs:
      [13433:0210/143601.929800:ERROR:bucket_context.cc(357)] Failed to open LevelDB database from /home/v/.config/obsidian/IndexedDB/app_obsidian.md_0.indexeddb.leveldb, IO error: /home/v/.config/obsidian/IndexedDB/app_obsidian.md_0.indexeddb.leveldb/LOCK
      
    • Manually removing the LOCK file (rm -f ~/.config/obsidian/IndexedDB/app_obsidian.md_0.indexeddb.leveldb/LOCK) allows Obsidian to start again, but the issue recurs after closing the app.
  3. High CPU Usage & Long Startup Time

    • Upon launch, Obsidian takes 8,000ms to 16,000ms to start:
      - Total startup time: 7,998ms
      - Vault (114,211 files): 7,020ms
      
    • CPU usage for the obsidian process remains at 99%+ even after startup.

Steps to Reproduce:

  1. Open Obsidian normally.
  2. Work within a large vault (~114k files in my case).
  3. Exit the application via GUI.
  4. Observe lingering obsidian processes using pgrep -fl obsidian.
  5. Try restarting Obsidian, leading to IndexedDB errors.

Expected Behavior:

  • Obsidian should terminate cleanly when closed from the GUI.
  • No lingering processes should remain.
  • IndexedDB should not remain locked after closing the app.

Workaround:

  • Manually removing the IndexedDB lock file before restarting:
    rm -f ~/.config/obsidian/IndexedDB/app_obsidian.md_0.indexeddb.leveldb/LOCK
    
  • Forcibly killing all Obsidian processes:
    pkill -9 -f obsidian
    
    but this is not an ideal solution.

Additional Notes:

  • Running Obsidian with --disable-gpu does not resolve the issue.
  • Occurs on both X11 and Wayland.
  • Tested with both AppImage and tar.gz distributions, and the issue persists.

Would appreciate any insights or fixes for proper cleanup upon exit!

Something similar related to indexeddb lock already discussed on forum and the workaround suggested but I think no bug was reported.

With the new insider version 1.8.6 it seems to work faster and more reliably.
It loads faster my 30k files.

Obsidian start-up time breakdown

Obsidian version: v1.8.6
Installer version: v1.8.4
Operating system: Windows 11 Pro 10.0.26100

- Total startup time: 4,609ms
- Initialization: 424ms
- Vault (30,889 files): 3,171ms
- Workspace (11 tabs, 9 deferred): 436ms
- Core plugins: 84ms
- Community plugins (12 active): 493ms
  - Tasks (v7.15.1): 164ms
  - Plugin Update Tracker (v1.6.2): 94ms
  - Git (v2.31.1): 55ms
  - Dataview (v0.5.67): 48ms
  - Enhancing Export (v1.10.9): 28ms
  - Natural Language Dates (v0.6.2): 26ms
  - Templater (v2.9.3): 17ms
  - Text Format (v3.1.0): 15ms
  - Calendar (v1.5.10): 14ms
  - Tag Wrangler (v0.6.1): 6ms
  - Homepage (v4.1): 4ms
  - Settings Search (v1.3.10): 2ms
SYSTEM INFO:
	Obsidian version: v1.8.6
	Installer version: v1.8.4
	Operating system: Windows 11 Pro 10.0.26100
	Login status: logged in
	Language: en
	Catalyst license: insider
	Insider build toggle: on
	Live preview: on
	Base theme: dark
	Community theme: none
	Snippets enabled: 4
	Restricted mode: off
	Plugins installed: 15
	Plugins enabled: 12
		1: Calendar v1.5.10
		2: Natural Language Dates v0.6.2
		3: Tasks v7.15.1
		4: Templater v2.9.3
		5: Text Format v3.1.0
		6: Git v2.31.1
		7: Homepage v4.1
		8: Settings Search v1.3.10
		9: Tag Wrangler v0.6.1
		10: Enhancing Export v1.10.9
		11: Plugin Update Tracker v1.6.2
		12: Dataview v0.5.67

For now I found a workaround by using Obsidian v1.7.7 AppImage Installer rather than using v1.8.4 Installer. Also, Installer v1.7.7 updated my applicatioin version to v1.8.4
So it is working fine as of now. No indexeddb locks but startup time is still high.

@juanbretti the problem is not that obsidian starts slowly.

There were no improvements made in 1.8.6 regarding this problem (which we believe is a regression of electron).

Please, keep this thread in topic.

I thought the slowness on my Obsidian was related to not properly closing Vault’s database. Sorry for my confusion.

About the indexedDB.open error, it did not happen to me again.