Navaneeth Sen B wrote:

> Hi all,
> 
> I just want to know whether SQLite support automatic backup of the DB 
> contents.
> Or is there any other DBs which support this feature?
> 
> Regards,
> Sen

a command that you could run from cron to backup an sqlite3
database automatically would be something like:

  sqlite3 /path/to/database .dump > /path/to/backups/`date +%Y%m%d`.sql

but bear in mind that if the database is too busy you can
get an effectively empty file that just begins and ends a
transaction with no sql in between. there will be no
indication that anything went wrong, just a tiny file.

btw, all databases support having a client connect to it
and retrieve all data (to which the connecting user has
permission to access). most of then probably have a command
to make it easy (such as the .dump command above). how you
automate such backup connections is up to you.

otoh, if you are referring to keeping a warm standby or hot
standby rather than a backup, have a look at postgresql
or something expensive (or the above .dump command followed
by an rsync). :-)

cheers,
raf

_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to