Re: [sqlite] Database backup with writers present?

2019-02-28 Thread Wout Mertens
I meant reflinks not extents. I should go to bed ;) Wout. On Thu, Feb 28, 2019 at 11:57 PM Wout Mertens wrote: > One option, if you are on a filesystem supporting extents (macOS's apfs > and Linux's btrfs only, currently, with xfs and bcachefs support on the > horizon): do a copy with

Re: [sqlite] Database backup with writers present?

2019-02-28 Thread Wout Mertens
One option, if you are on a filesystem supporting extents (macOS's apfs and Linux's btrfs only, currently, with xfs and bcachefs support on the horizon): do a copy with reflinks (cp -c on macOS, cp --reflink=auto elsewhere). That should be super fast since all it does is point to existing data and

Re: [sqlite] Database backup with writers present?

2019-02-27 Thread Simon Slavin
On 27 Feb 2019, at 4:16pm, Richard Hipp wrote: > On 2/27/19, Stephen Chrzanowski wrote: >> Does write blocking still come into play when using "vaccum into", > > The VACUUM INTO command is a reader. So (in WAL mode) some other > process can continue writing while the VACUUM INTO is running.

Re: [sqlite] Database backup with writers present?

2019-02-27 Thread Richard Hipp
On 2/27/19, Stephen Chrzanowski wrote: > Does write blocking still come into play when using "vaccum into", The VACUUM INTO command is a reader. So (in WAL mode) some other process can continue writing while the VACUUM INTO is running. -- D. Richard Hipp d...@sqlite.org

Re: [sqlite] Database backup with writers present?

2019-02-27 Thread Stephen Chrzanowski
Does write blocking still come into play when using "vaccum into", or are writes put into the WAL file? I know that with the regular backup API, any writes to the DB restarts the backup process, but I hadn't thought about putting either into a transaction. (I'm an I-D-TEN-T, I know) On Wed, Feb

Re: [sqlite] Database backup with writers present?

2019-02-27 Thread Richard Hipp
On 2/27/19, Daniel Polski wrote: > > Is there some way to take a snapshot of a database regardless if there > comes new writes / transactions while doing the backup, and just write a > copy of that snapshot as it was into a new database file? I assume you are using WAL mode? If not, you should

[sqlite] Database backup with writers present?

2019-02-27 Thread Daniel Polski
Hello, When reading the docs I don't get a clear understanding on what strategy I could/should use to backup a heavily used database (with frequent reads & writes). I have one application (A) with multiple threads reading & writing to the database. Application (A) handles write locking