sqlite3-restore

command module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 25, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

README

sqlite3-restore

This is a repository for the sqlite3-restore utility that provides a way to restore a SQLite database online while other clients are connected. It acquires the necessary locks on the destination database before performing a file copy. This preserves the inodes so that existing clients can continue to read and write from the database after the copy is complete.

Usage

The utility accepts a source database file and a destination database file:

sqlite3-restore SRC DST

If the destination database file does not exist, then it will be created. If it does exist, the journal file will be removed, the WAL file truncated, and the SHM file will be invalidated.

You can also set a timeout to wait on locks. By default, it is set to 5 seconds:

sqlite3-restore -timeout 30s SRC DST

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL