codenotary / immudb

immudb - immutable database based on zero trust, SQL/Key-Value/Document model, tamperproof, data change history
https://immudb.io
Other
8.55k stars 343 forks source link

How to archive/backup #722

Closed hasanAjsf closed 3 years ago

hasanAjsf commented 3 years ago

How can I archive or backup my immudb, I may need to have it in case there is any issue with my host device.

mmeloni commented 3 years ago

Hi @hajsf, at the moment the easiest way to backup immudb is explained here Please note that we have recently migrate from 0.8 family to the new 0.9 one and immuadmin backap and restore commands are not yet ready for the last version but we are working on them.

hasanAjsf commented 3 years ago

Thanks, in the documents it is mentioned the file is saved at /var/lib/immudb but in my one it was saved at ./data by default

image

mmeloni commented 3 years ago

@hajsf yes, in the documentation a docker container was used. It's ok data in your case

hasanAjsf commented 3 years ago

@mmeloni how can I change it, I saw something configs/immudb.toml but do not know where it is saved.

In the documents it is taking about /etc/immudb/immudb.toml but in my system wsl at win 10 I can see:

image

mmeloni commented 3 years ago

You can use --dir flag or IMMUDB_DIR= environment variable. If you want to use a config file you can specify the path with --config flag. Let me know if it works for you

hasanAjsf commented 3 years ago

mm, I'm new to linux so not sure if I capture it correctly. once I run $ ./immudb --config, I got

--config string           config file (default path are configs or $HOME. Default filename is immudb.toml)

I could not see anything at $HOME, and configs does not looks to be a directory!

I'm interested to see the saved one, before creating my own.

mmeloni commented 3 years ago

Ok, got it. here you find the config shipped with sources of immudb. You can specify config path with:

immudb --config /home/user/myconfig.toml
hasanAjsf commented 3 years ago

Thanks