Disable auto-save or change frequency

yes, you can change the shortcuts in the hotkey section of settings.

Got it! Thanks @WhiteNoise. Save was ⌘+S all along :slight_smile:

As I said, I’m new to Obsidian. But really, really liking it. Thanks to everyone.

I am fairly certain the overly high frequency of iCloud writes is causing Apple to pause my obsidian folder when using my windows machine. Hugely annoying because I have to reboot my machine to resolve the issue, and end up losing my recent notes.

It would be great if we had the option to lower the frequency to 1, 5, 15, 30, 60 etc second intervals.

2 Likes

I signed up for this forum to say I’m having the same issue. Mid sentence I’ll lose content and then have to hit Ctrl-Z. I have a Windows machine connected to iCloud.

If I could just turn off auto-save then I could hit ctrl-s whenever I needed to save. Instead it’s just syncing all the time and causes this really weird typing bug where it goes back in time as I’m typing a sentence.

3 Likes

I’m bumping up on this as well. I sync to Google Drive using InSync on Linux which works great for a work-related vault (I use Obsidian Sync for personal work). However, since Obsidian saves every key type, Google Drive will only store the last 100 versions which is basically my last 100 key types.

Can we get a throttling concept built into auto-save? It really doesn’t make sense to save every key type, at least wait a second for typing activity on the file to come to a stop before saving.

5 Likes

Agreed! There are many reasons why the ability to disable the autosave feature would be wanted. Some are undeniably valid, some are personal preference.

  • A syncing system can get thrown off by constant saves (either making massive numbers of backups, or throttling due to overaccess).
  • Working on a media with limited write cycle per lifetime (flash drives, SSD, etc). This may be not worth stressing about, but knowing each type of a character triggers a resave of the entire file: the concern is reasonable.
  • Just not wanting forced into a workflow that you do not prefer. Ctrl-S has worked fine for many people for many years. There’s a reason it has stuck around.

… and, finally, a toggle in the settings to turn on/off autosaving seems like such a simple feature to add.

Such a hard line reminds me of how IOS hides file/folder structure to the point where apps like Obsidian can’t take advantage of things like syncing apps, without special programming to add custom interoperability.

2 Likes

Having the same issue here.
I’m using mega.nz software for syncing between devices. After some period of time it won’t sync your files, moreover, you can’t figure out when exactly this is happening. I have’to relaunch the app to be sure all my files are synced correctly, and due to the app need’s to rescan all my files, it can take up to 10 minutes.

1 Like

Autosave makes me depressed.
I set the obsidian folder as sync folder. So when I write the note, Obsidian always promoting: EBUSY:resouce busy or locked, open.

2 Likes

Please, please add the option to turn off Autosave.

Using Obsidian on Windows with iCloud providing the sync produces constant conflicts which are irritating but more significantly each conflict produces a locked file which must be manually deleted. In 20 minutes of editing I have just had 7 of these files created and all have to be manually deleted. Ignoring them doesn’t work because they interfere with backups and they interfere with Obsidian indexing - I guess because they can’t be indexed.

I know I could use the ‘default app’ which, in my case would be Typora where the autosave can be switched off, but the markdown formatting doesn’t precisely match text edited directly in Obsidian so needs re-editing to get the formatting right. This re-editing is not only a waste of time but also goes back to the original problem.

4 Likes

I agree wholeheartedly that this is a sorely lacking feature, but

I now believe that Obsidian’s functionality is closely tied to the auto-save. It does a lot of different things during saving that are intended to feel seamless to the user, and at least a few of them would break badly if the loaded note were to remain out of sync with the note file’s contents. That’s my impression anyway, now that I’ve written a decently involved plugin for Obsidian.


One workaround, for people who are really struggling with the constant saving, would be to put your vault onto a RAM disk, then copy it back to the hard-disk whenever you really want to save.

I’ve done this, and it works better than you’d expect! Here’s how I did it on windows.

  1. I setup a ram disk:
    1. I installed the open-source software ImDisk Toolkit.
    2. I made the new start menu item “Mount Image File” easy to run. Then I ran it.
    3. In the window that pops up, I clicked the “Switch to Driver Interface” button at the bottom left.
    4. I set the “Size of virtual disk” to 250mb (it’s a safe bet for MY vault anyway)
    5. I set the “Device type” to “Harddisk volume”
    6. I clicked the ok button and… bam! A new hard-disk made entirely of ram.
  2. I copied the vault I wanted to work with onto the ram disk.
  3. I opened the vault from the ram disk.
  4. I setup the ability to quickly and easily save my changes using “xcopy”.
    1. I opened CMD (a command-line window).
    2. I navigated (using the CD command) to within the vault’s folder on my ram disk.
    3. I typed this command:
      • xcopy . {path to the vault folder on the real hard-disk} /s /d /e /f /y
    4. I tested it by running it again (just hit the up arrow key, then enter), noting that no files were copied. I then changing one note in the vault and ran it again, confirming that the single note was copied.

FYI, that long xcopy command includes flags to ensure that the only files that are copied are the ones that are newer on the ram-disk than on the real hard-disk.

Also, if you are handy, you can create a batch script to run that xcopy command, rather than needing to remember it.

Hope that helps. If you are on Linux or Mac, the steps are similar, but you’d use different software and command.

1 Like

This is correct.

What are the consequences of using the “default app” with auto-save switched off and doing a manual save every minute or so?

I can’t say for certain what the consequences are for not auto-saving, because I’m just basing my supposition on some things I’ve noticed while making my plugin, such as how much data Obsidian is caching behind the scenes, much of which is re-calculated when files are saved.

I know that many plugins, both core and community, use that cached data. Tags, links and YAML-front-matter all rely on it. It is interesting to note that the popular plugin “DataView” keeps its own cached data, but re-calculates it when navigating away from a note instead of when saving. This makes it kind of quirky in that you need to move to a different note, then back again before certain changes will take effect.

Now, as to why all that caching needs to be done at save, rather than just be triggered whenever a note is changed? I can’t be sure. I have a couple of theories, though:

  1. It’s possible that some of the data is cached to disk, thus requiring that either (a) the notes are saved too, or (b) the cache on disk is allowed to be in-sync with the notes in memory, while being out-of-sync with the notes on disk. If (b) is true, then if Obsidian crashes and loses unsaved data, the data cache on the disk becomes out-of-sync in an indeterminate way. This issue could be fixed by recaching all data each time the vault is opened, but it’s possible that this would take a long time, especially for bigger vaults (which would explain why the cache would be written to disk in the first place). Another fix could be to recognize when a crash happens and only re-calculate the entire cache after a crash. This might be a viable solution, to this particular theory. In fact, I think some software does do it this way.
  2. It’s possible that data for each note is pulled in and out of memory as needed. I do know that extra-long notes are internally segmented into smaller parts. It’s likely that this segmenting is done to load and unloaded parts of the note from memory as the user moves around the note. In fact, if you think about it, the ability to quickly navigate from note to note, regardless of how big the vault is, would necessitate keeping only visible notes in memory. Removing auto-save would require explicitly asking the user if they want to save when you navigate away from a changed note (like document editing software does), but Obsidian isn’t document editing software, it’s note-taking and mind-mapping software, which relies on the ability to quickly and effortlessly move from note to note.

Now that I’ve written it up, theory 2 seems probable to me. However, I could see a few ways around it:

  • Auto-saving a note whenever an unsaved segment of the note is moved out of memory, rather than as soon as it is changed. This solution could get hairy for the user, since it requires saving the note (a very important action to the user, thus this entire thread) whenever segments of the note are moved in and out of memory (something the user has no concept of, nor should). Thus, this solution would cause notes to be saved at perceptually random points.
  • Saving unsaved segments of the note to backup files, until the user explicitly saves. Some software works this way, such as Notepad++. Thus if a segment has a backup file (i.e. it has not been user-saved) then load from the backup file, instead of from the note file directly. This would, in fact, resolve both theories 1 and 2 above. However…
    • It’s a complicated system, and may not be implemented simply for that reason.
    • The backup files could pile up if a user never bothers to save their notes. This is especially true of a large vault. Again, Obsidian is a note-taking and mind-mapping software. The concept of requiring explicit user-saving runs antithetical to that purpose.
    • One of Obsidian’s strengths is that it’s primarily a simple folder-tree, with a hidden “.obsidian” folder to handle the extra stuff. Having notes being out-of-date unless you take into account a bunch of backup files in the “.obsidian” folder runs counter to that concept.
    • Whether save-spamming happens to the notes or to backup files makes no difference to syncing software, meaning it wouldn’t resolve what seems to be the primary issue people have with auto-saving. Of course, you could tell the syncing software to ignore any changes within the folder where backup files are stored. Any decent syncing solution should let you do this. Yeah, this particular issue could be worked around.

So I guess the gist of this is: it’s a lot more complicated than it seems on the surface. There might be a viable solution, but it’s not obvious (at least to me). One question Obsidian devs might ask: is it worth the effort? People who struggle with jamming syncing systems would argue that, yes, it is worth it! Obsidian devs might be convinced if this was a strong enough concern to counterbalance what is obviously a sticky problem to solve. I’m guessing that it’s not.

I think that the ram-disk idea that I proposed above (and have been actively using) is a workable solution. It might seem like a big deal to implement, but it really isn’t that bad. I admit to having had moments of concern that I hadn’t “saved” my data recently (from the ram disk to the hard disk). One solution would be to have a script that auto-saves (auto-calls xcopy) on a regular basis. THAT seems like more work than it’s worth to me, but it’s all relative. Someone else could see that being perfectly reasonable.

4 Likes

I just found a better solution than using xcopy to sync the ram-disk with the hard-disk.
FreeFileSync is software to sync two folders, either manually, or at regular intervals. This includes a “mirror” mode, which is what we want in this situation.

2 Likes

Obsidian is very flexible but not in this regard?
All those things done during saving should not care wether the saving is triggered automatically or manually.

Not having the option is sad… I was looking through all the options and then looked online to find this thread.

Back to Ghostwriter for me it is then :frowning:

1 Like

+1 for this “feature”. Mostly for fun (having the option to analyze my editing in the future) I have a simple script which commits my vault regularly to git. I used to simply create a new commit every X seconds, but it’s much better to tie it to save since this breaks the edits up in more coherent blocks. I’m an old man so pressing ctrl-s is ingrained in my fingers after doing a “chunk” of editing/writing. The autosave messes up this chunking. At least make the delay configurable?

EDIT: I guess an option is to create a simple plugin to trigger such commits

1 Like

+1 for this.
Seems a bit extreme to have autosave run for each letter we type. (pretty much, it seems)

I know the following is not for everyone, but my “personal cloud” solution syncs these files on every save.
This makes it a hell of a workout for the local disk, the app, the network - and my NAS.

The sad part is that I finally feel like I found the perfect note-taking app, but this doesn’t sit right with me.

6 Likes

The default autosave gap is 2 seconds later while I stop writing.
I need to configure the autosave time gap. When I save the vault in Dropbox or Onedrive, I can setup my own sync frequency.

15 Likes

Very simply, for me having hundreds or thousands of versions for a longer note with many edits over time is way too much. I’d like to set my version history save frequency to something more like 10 minutes rather than having it save a new version every time I pause for two seconds.

When I want to recover a previous version, I’m going for “close enough,” not for a precise recovery at a specific clock time. Having a bigger gap will make the versions stored have a much higher rate of utility.

7 Likes

would love this! I was downloading pdfs into my obsidian directory and obsidian sync saved the chrome download files bc it synced it too fast :upside_down_face:

1 Like