It takes too long for Obsidian to come out from background

Steps to reproduce

Obsidian works for some time in the background. I'm not sure what is the precise time but it's rather long. Probably enough for the app itself or the OS to unload the app from RAM. I use other applications and then switch to Obsidian.

Expected result

I expect Obsidian to be ready for use right after switching to it.

Actual result

Obsidian unfreezes and becomes usable only after 40 seconds (I measured the time) or sometimes more (subjectively).

Environment

  • Operating system: Ubuntu 20.04
  • Obsidian version: 0.10.8

Additional information

As I understand, Obsidian uses Electron. No other app on my laptop that uses this technology takes so long to unfreeze after some time of inactivity in the background. Zettlr and VSCode are ready to use right after switching to them no matter how much time they were inactive. So I figured the cause may be not Electron or my slow computer. There is a topic [Obsidian on Linux is Slow to point of Unusable](https://forum.obsidian.md/t/obsidian-on-linux-is-slow-to-point-of-unusable/10804) an author of which experienced slow work in all situations. Solution to use --disable-gpu key from that topic didn't help me.

This is quite a generic description of the matter. How big is your vault, what are your computer specs? where are the files stored? etc

I’ve tried running Obsidian with AppImage instead of snap and now it works fine and doesn’t freeze. It is still not as quickly restoring itself from the background as other apps, but I feel 3 seconds of freeze are tolerable.

Can’t say that I’ve seen that with the AppImage. What’s your installer version? What do you mean exactly by “comes out from background”? The steps to reproduce are a bit vague. And how many notes do you have?

I don’t exactly understand what you meant by “installer”. Obsidian version is 0.10.8 as it is stated in the opening post. The vault size is about 350 Kb. By the background I mean a state in which an app is not used at the moment but is running. E. g. I launch two applications. One is Obsidian, another is Chrome. I switch to Chrome and work in it for some time. Meanwhile Obsidian is running in the background. Then I switch from Chrome to Obsidian and find Obsidian in a frozen state. Ubuntu sometimes shows a notification saying the app is unresponsive and offering to end an unresponsive process.

Using AppImage ended this trouble. Although the app still lags a bit, as I mentioned previously, 0 to 3 seconds are drastically different from 40 seconds.

The installer version is different from the app, you can see it in Settings > About right below the Current version of the app.

image

Your vault doesn’t sound too big, but can’t say without knowing the number of files, so the small delay is a bit surprising to me and not something I’ve experienced with the AppImage and my vault. Depending on the number of files you have, and whether or not you have some search executed or the backlinks/unlinked mentions open could be playing a role.

Since obsidian is a chrome browser you must have an sdd.