synchronization without pain

Pavel Spectr

Java developer

Good day, guys! The topic turned out to be quite relevant and interesting and, as promised, we will explore it today.

I won't describe which one Obsidian wonderful and what opportunities it gives – those who are in the know already understand that this is not just a program, but a whole 2nd brain and everyone has their own.

I started using it not long ago Obsidian and actually from the start I encountered the problem of synchronization between all devices. This prompted me to solve this issue – once and for all.

Plugin or third party application?

At first, I used a free cross-platform app that allowed me to connect my devices directly, via a tunnel. It's called SyncThing. We simply specify the folder on the device in the application that we will synchronize, configure the synchronization parameters, add our devices and that’s it.

There are a few caveats, though: this app wasn't available on Google Play – I had to install a third-party open source software store. F-Droidand what about AppStore I'm not sure at all.

But every time, after working on each device, you will have to open the program and keep it active so that the other device synchronizes the data. For a PC running on the network, there seem to be no problems, but… The electricity is sometimes turned off, the Internet may disappear or всеми любимый Windows may go into reboot for update… But current data is needed here and now!?

And a question to the audience: Does everyone like to launch one application first in order to normally use the one they need?

You already understood that this option did not suit me and I had to “dig” further.

The art of finding answers

Knowing how to ask the right questions leads to finding the right answers.

Is it really true that such a cool, as they say, application as Obsidian does not have plugins for easy synchronization? Not only do they exist, but there are quite a few of them, and besides, they are sorted by rating and number of downloads!

By myself Obsidian would not have become so popular if it had not had such a high possibility of expansion and adaptation to the most non-trivial tasks. Third-party plugins make it truly unique for everyone.

Remotely Save

This plugin is installed on both desktop and mobile Obsidian.

Here I will tell you step by step how to set everything up:

I will skip the installation and launch steps, as I am sure that the reader was able to install Obsidian and create a storage in the desired location on your device or devices, in anticipation of what is now все будет работать!? Будет! If you pay attention!

  1. We make a copy of the current database in case of unforeseen circumstances! I have not had such circumstances, but still, reinsurance will not be superfluous.

  1. Storage folder name Obsidian should be the same on all devices (for example, my folder is called: Obsidian).

  2. We need Облчный-сервис (also in Russian: Облако) with sufficient memory and no risk of blocking:

    • Яндекс.Диск;

    • Mail.Облако.

    It is possible too Google Drive And iCloud or any other normal cloud service that provides API remote access (TeraBoxfor example, is not suitable, and the connection speed is low).

    My advice: use a cloud that actually has enough free space, or create a separate account just for Obsidian I have a separate one for obsidian Яндекс.Диск.

  3. We create in Облаке a folder with the same name as on all devices.

!!! On all devices, including the cloud, with which the folders will be synchronized, they must have absolutely the same storage folder name!!!

  1. Now we go to Obsidian -> And then in order:
    On the left you should see a list of notes and folders, if it is not there, then open it by clicking here:

Buckwheat 1.

Buckwheat 1.

Click on the gear at the bottom of this panel:

Pearl barley 2.

Pearl barley 2.

Go to third-party plugins and enable them:

Semolina 3.

Semolina 3.

Next we go here:

Millet 4.

Millet 4.

In the search, enter Remotely Save, or you can do it the way I found this plugin – enter sync and was surprised by the number of different solutions for synchronizing not only the storage folder, but also many other things, you can even write notes to yourself in Telegram and they will fly in Obsidian):

Peas 5.

Peas 5.

We install:

Quinoa 6.

Quinoa 6.

I highly recommend reading the description. The plugin is really well made and has support for a variety of protocols for synchronization with different cloud services.

  1. Setting up synchronization:

    I will show the setup through WebDAV by example Яндекс.Диск and I will touch Cloud.Mail. To configure via other services you will have to figure it out yourself, but I am sure that there is nothing beyond the possible.

    So:
    We have an account on Яндекс or Mail.Ru.
    I have it on Яндекс by default 30Гб space – somehow they suggested increasing it, and Mail.Ru by default gives 8Гбbut once for free and forever increased it to as much as 100Гб!!! Sometimes there are such promotions and it is advisable not to miss them.

    We need an access token from an external application – in other words, we need to go in and generate an access key. This key is one and it is enough to generate it once, and then use it for a variety of purposes (for example: to connect a network drive).

    Yandex:
    Let's go here https://id.yandex.ru/security/app-passwords and generate a key WebDAV:

    Lentils 7.

    Lentils 7.

It is better to save this key in a safe place, from where it can be easily copied and reused later. Otherwise, you will have to generate a new one each time. If the service does not support multiple working keys, then services with the old key will no longer work.

Mail.Ru:
Let's go here: https://account.mail.ru/user/2-step-auth/passwords/
Everything is the same as for Яндекс.
If something is not clear, then read “How to create a password”.

  1. The hardest part is over and all that's left is to set up synchronization for yourself. I'll tell you about all the settings in order.
    Let's go to Obsidian -> in settings (that same gear) -> click on the bottom left Remotely Save and we start to set up:

    Bulgur 8.

    Bulgur 8.

Chickpeas 9.

Chickpeas 9.

  • Choose A Remote Service: we choose WebDAV;

  • Server Address:
    For Yandex: https://webdav.yandex.ru/
    For Mail.Ru: https://webdav.cloud.mail.ru/

  • Username:
    For Yandex: email address, without @yandex.ru (eg: obsidian@yandex.ru)
    For Mail.Ru: e-mail address in full (for example: obsidian@mail.ru)

  • Password: insert the generated token here;

  • Auth Type: leave basic;

  • Depth Header Sent To Servers: this parameter is responsible for the depth of directory headers. I have it by default depth="1" and everything is fine. depth="infinity" I can't recommend it because I haven't tested it myself yet. The description of this parameter says that not all cloud services support a deep directory system.

  • Custom Header Sent To Servers: leave it as is;

  • Change The Remote Base Directory: write the name of the storage folder – as on all devices: write or copy your name (for example, for me: Obsidian) and click Confirm – a folder with this name will be created in the cloud if it has not been created before;

  • Check Connectivity: click Check and a message will appear in the upper right corner Checking... and after Great! The webdav server can be accessed.if everything was done strictly according to the instructions.

There are also a few more useful settings here:

  • Schedule For Auto Run: Automatic synchronization schedule – it's up to you. I disabled it so as not to cause unnecessary connections, especially for my phone;

  • Run Once On Start Up Automatically: start synchronization when the program starts. I was satisfied with this option sync once after 1 second of start up;

  • Sync On Save (experimental): starts synchronization on any change;

  • Skip Large Files: an option for those who do not want to upload large files to the cloud, larger than the set value;

  • Show Last Successful Sync Time: a useful option that shows the time of the last synchronization;

  • Concurrency: synchronization in multi-threaded mode. By default, 5 threads are allocated from the connection pool. I tried 1, 5 and 10 threads for myself – I recommend leaving the default and changing this value only for certain conditions, for example: you need to load the entire database and clouds from scratch – 10 threads will be great, with a good Internet connection, and if you need to pull data to an old computer that runs on HDD, then it is better to do it in one thread, this option is also suitable for saving the device's battery, although everything is very relative here and will directly depend on the volume of received / transmitted changes.

  • I won't touch on the rest of the settings – with a minimum of English and an unwavering desire for optimization, you can handle it yourself just fine. I just want to note that Remotely Save you will have to configure it separately on each device, but it is for the better. There is of course an option Sync Config Dir (experimental)which can greatly help some and break the configuration of others – it is better to use it when identical plugins are installed on all devices.

You can start synchronization manually using the button that appears on the left panel:

That's all, guys!

This tutorial has been tested by me personally and works great on 3 devices under Linux, Windows And Android. I think that on devices Apple there won't be any special differences. And if you have any problems, write in the comments.

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *