restore backup

zadam 2020-01-04 09:35:42 +01:00
parent 00c17e044b
commit 30a2fa6657
5 changed files with 20 additions and 1 deletions

@ -9,4 +9,17 @@ So in total you'll have at most 4 backups from different points in time which sh
This is only very basic backup solution and you're encouraged to add some better backup solution - e.g. backing up the [[document]] to cloud / different computer etc. This is only very basic backup solution and you're encouraged to add some better backup solution - e.g. backing up the [[document]] to cloud / different computer etc.
Note that [[synchronization]] provides also some backup capabilities by its nature of distributing the data to other computers. Note that [[synchronization]] provides also some backup capabilities by its nature of distributing the data to other computers.
# Restoring backup
Let's assume you want to restore the weekly backup, here's how to do it:
* find [[data directory]] Trilium uses - easy way is to open "About Trilium Notes" from "Menu" in upper left corner and looking at "data directory"
* I'll refer to `~/trilium-data` as data directory from now on
* find `~/trilium-data/backup/backup-weekly.db` - this is the [[document]] backup
* at this point stop/kill Trilium
* copy and rename this `~/trilium-data/backup/backup-weekly.db` to `~/trilium-data/document.db` - this will delete the current state of the [[document]] so you might want to back it up somewhere else
* start Trilium again
If you have configured sync then you need to do it across all members of the sync cluster, otherwise older version (restored backup) of the document will be detected and synced to the newer version.

@ -6,6 +6,12 @@ Data directory contains:
* `log` - contains application log files * `log` - contains application log files
## Location ## Location
Easy way how to find out which data directory Trilium uses is to look at the "About Trilium Notes" dialog (from "Menu" in upper left corner):
[[images/about-trilium-data-dir.png]]
Here's how the location is decided:
Data directory is normally named `trilium-data` and it is stored in: Data directory is normally named `trilium-data` and it is stored in:
* `/home/[user]/.local/share` for Linux * `/home/[user]/.local/share` for Linux

Binary file not shown.

After

Width:  |  Height:  |  Size: 127 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 115 KiB

After

Width:  |  Height:  |  Size: 126 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 66 KiB

After

Width:  |  Height:  |  Size: 99 KiB