How to restore a Backup

I synced not encrypted to my NAS. This was cleaned, so I copied the directory Joplin.

Now I have restarted Joplin and saw a note. I don’t know form where. Possibly its made during reinstalling NAS.
But I thougt it’s no problem. I closed Joplin. Copied my backup to the same location at the NAS. Opended Joplin and did a sync. But the old notes were gone. I see only the new one.

I thougt, it is enough to backup this directory and restore it. What’s wrong. Perhaps you can help me and than explain how to backup correct. Especially, when using encryption and sync with e.g. a webDAV.

Thanks

are you sure you point on the right joplin profile folder ?

Yes I did. I checked this copying the path from Joplin/Einstellungen to FileBrowser and there I get the Joplin-Dir with the data

I’m back from vacation and try again to get my data. Joplin would be great, but if my data lost so easy and there is no possibility to get back it from my backup I think its not useable. This can happen all the time…

So - does anyone have a solution?

What I tried today is to import my backup dir via Menue “file - import - md (directory)”. This will import my backuped files. But only in one notebook and with the filename e.g. ffae3d15d81f4628b1c7658fc1db17d9 as a title. So this is not usable.
I also tried to make a new, different location on NAS with the backuped files and use this as sync location. But this also didn’t work. The files there are ignored.

So one again, how can I get back my backup of original stored files from joplin sync directory ?
I can provide log-files (eMail, upload), if this will help.

If you move sync directories around, restore them, etc. you really have to know what you’re doing because you might get the clients and sync dir out of sync.

So is there a place where you definitely have all your data - either on the NAS or on a Joplin client?

  • If you have the complete data on the NAS, follow these steps:

    • Close the Joplin client
    • Delete the Joplin profile (~/.config/joplin-desktop)
    • Restart Joplin and re-sync - you should then get back all your files
  • If you have the complete data on a Joplin client:

    • Export all your data from Joplin as a JEX file
    • Close Joplin
    • Delete the Joplin profile (~/.config/joplin-desktop)
    • Delete the sync dir on the NAS
    • Open Joplin and re-sync to restore all the data on the NAS
1 Like

Many thanks, this works :-).

Perhaps it will be a good idea to write some lines to your FAQ and explain how to backup the data. I assume the best will be to export as JEX file. Indirectly it is written in the second FAQ with WebDAV. But as a single poit it’s perhaps more understandable.

1 Like

I’m still confused. Should I backup the sync directory or the ~/.config/joplin-desktop directory or both? Backup and restore should not be so complex. I have 4 devices using the same notebook and that is a bunch of steps to restore a backup.

Of course, the JEX file solution only works for desktop clients. How to do and what to backup on android and IOS?

1 Like

Export the data to JEX from the desktop client and that’s all you need.

No need to backup on mobile since logically you have the same data on desktop.

That works great if the desktop client hasn’t been gotten out of sync. My problem was that my desktop got wiped after adding a new device. I restored my backup of the sync directory, still no notes on my desktop app but my android showed all notes. Hmm, no JEX export from android.

The solution was to delete the user…config\joplin-desktop directory, which is NOT the same as the sync directory, from the desktop machine and resync. This is a rather nerve-wracking experience considering how easy it was to lose the data while adding a device.

The average Joplin user really shouldn’t be mucking around deleting directories in his user directory. Restoring a backup is a last ditch effort to retrieving lost notes. The solution would be to have a button somewhere that says “Sync from restored backup” that ignores dates and basically just reloads the data in the sync directory.

Some notes created after the restored notes were created might be lost. That is always the case with restoring from a backup. The recovery of the bulk of the notes is preferable.

1 Like