unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Christopher Baines <mail@cbaines.net>
To: Mathieu Othacehe <othacehe@gnu.org>
Cc: guix-devel@gnu.org
Subject: Re: Cuirass WAL size issues
Date: Mon, 07 Dec 2020 09:32:20 +0000	[thread overview]
Message-ID: <877dpuq7vf.fsf@cbaines.net> (raw)
In-Reply-To: <874kkyvunc.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 1601 bytes --]


Mathieu Othacehe <othacehe@gnu.org> writes:

> Hello Chris,
>
>> I believe SQLite checkpoints the WAL file after transactions commit, if
>> the WAL is over 1000 pages in size. At least for the Guix Build
>> Coordinator though, that didn't seem to be working/happening as the WAL
>> file seemed to just grow and grow.
>
> I have noticed that the WAL file size had a strong impact on Cuirass
> performances on berlin[1].
>
> My conclusion was that, WAL file is nice when doing a lot of writing,
> but it makes reading really slow over time. I did set the checkpoint
> value to 16 pages of 32KiB as recommended here[2].
>
>> Switching focus to Cuirass, I think it's got similar issues. I've pushed
>> a few commits to this branch [1], the important one being [2] which
>> rewrites a few procedures to call sqlite-reset when the statement is
>> finished with, rather than calling it before starting to read from the
>> statement.
>
> The first two commits look nice. Regarding the third one, it makes sense
> to finalize or reset a statement once done with it, but I cannot find
> anything in SQLite documentation insisting on that point.
>
> Have you found some resources elaborating on that?

No, that's fustrated me as well. Given sqlite-prepare resets cached
statements, I did try removing most of the sqlite-reset calls from the
Guix Build Coordinator, but that went very badly so I reverted it
shortly after. I was also struggling to find documentation on what to
do/not do.

I'll neaten up these commits later and push them, hopefully it'll help
with the WAL size and/or query performance.

Chris

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 987 bytes --]

      reply	other threads:[~2020-12-07  9:32 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-06 11:19 Cuirass WAL size issues Christopher Baines
2020-12-07  9:21 ` Mathieu Othacehe
2020-12-07  9:32   ` Christopher Baines [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=877dpuq7vf.fsf@cbaines.net \
    --to=mail@cbaines.net \
    --cc=guix-devel@gnu.org \
    --cc=othacehe@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).