Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ncRgF-0005t1-8p for pgsql-hackers@arkaria.postgresql.org; Thu, 07 Apr 2022 12:56:07 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ncRgE-0005Wj-4n for pgsql-hackers@arkaria.postgresql.org; Thu, 07 Apr 2022 12:56:06 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ncRgD-0005Wa-RU for pgsql-hackers@lists.postgresql.org; Thu, 07 Apr 2022 12:56:05 +0000 Received: from mail-io1-xd35.google.com ([2607:f8b0:4864:20::d35]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1ncRg7-0001JH-I5 for pgsql-hackers@postgresql.org; Thu, 07 Apr 2022 12:56:05 +0000 Received: by mail-io1-xd35.google.com with SMTP id 125so6565159iov.10 for ; Thu, 07 Apr 2022 05:55:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=rvXrMPRhA3Bgcr3sxAk8SmoTb3gssXHfZHd05BNR1R4=; b=BhG0fqpz9l2LgIMBZ/eh0OLgh5fIZCfMPxGedktLfkO73PaPTrhGifD1YCH+cmDg2V WU8hF2GlBP8EPda6dC+GqyGFfs0RJw/Otyt/9v+07aewIr/Xv2u6zN2+h75xr7SmzjuF CK6eItcVmHRYoP3PTHHRIg8QRynGVXPj8CX8nnraqOG2ANAGD8NlR9ikd8N/JBI8lkic GiKDKm+RKJMhv+skjDvHmcfV/cK7l8CbI12Wpvutv6nbrte+ypAhMs+KGRMXhd4uDI07 PxVOPsEl0d3sOXG8fZ+UliyPZkPlDyoDO4wXZCI4eOwHkbya7BMkIHGkincSAhTZMZME E1rQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=rvXrMPRhA3Bgcr3sxAk8SmoTb3gssXHfZHd05BNR1R4=; b=6qBp3HJYWsrcevzWbiW2f4PxOl79GAbONA038iIDLZaz38xtcp1IqOfc7/yyP9z9NL uKmudTVE9R0l2geek5oGf+WUxr3VlMozhVd5FloK96iHgpOSYpslcsv4LVotpHTjAYJl 6+Vhpjk8B4bqGyLv/dh1zO4V58WT/r9AjlPCmF8L63/4lRhnev7E7zZ/G5g+ZLHmsVyC zE3GEez9hegec+fn9xgoiLN+EAE9fOPNltLrmpeVxGYyE/IMRVK809b0wNwgMkN221Nl R29mW4ZwPXprrWIsA/miW29oCfGbRoCmWtFEXXMUQrE9sQG+pseHR4xzZhubCgutaeT5 8yqQ== X-Gm-Message-State: AOAM53251/69o/RK6K9+EJhMs0mz6xh/v+MyuAgqh1tD3MoQcQkaqFeh EkU/ZQ39IGTK/PFR0UQvQinT0g== X-Google-Smtp-Source: ABdhPJxAyLxYfqf883sYvE4bqVwYByahQjSOZnfO1vhoU9iLgoRC9gzgfdN3Rzb5Qk6Hy0kJrb09XQ== X-Received: by 2002:a05:6638:4093:b0:323:99b8:c2c4 with SMTP id m19-20020a056638409300b0032399b8c2c4mr7102074jam.127.1649336157449; Thu, 07 Apr 2022 05:55:57 -0700 (PDT) Received: from pryzbyj.telsasoft (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id s11-20020a92d90b000000b002ca53f52b7fsm5413338iln.26.2022.04.07.05.55.56 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 07 Apr 2022 05:55:57 -0700 (PDT) Received: by pryzbyj.telsasoft (Postfix, from userid 1000) id 1528F800D87; Thu, 7 Apr 2022 07:55:56 -0500 (CDT) Date: Thu, 7 Apr 2022 07:55:55 -0500 From: Justin Pryzby To: Thomas Munro Cc: Tomas Vondra , Stephen Frost , Andres Freund , Jakub Wartak , Alvaro Herrera , Tomas Vondra , Dmitry Dolgov <9erthalion6@gmail.com>, David Steele , pgsql-hackers@postgresql.org Subject: Re: WIP: WAL prefetch (another approach) Message-ID: <20220407125555.GC24419@telsasoft.com> References: <20210214231815.GO27507@tamriel.snowman.net> <17b3f450-048c-f3a6-7086-259523f33cbc@enterprisedb.com> <20210317214331.GF20766@tamriel.snowman.net> <28c3352e-5388-6410-aae7-05907079e6c9@enterprisedb.com> <8dd2dcc2-0b6b-a4ab-c1b3-032c0a5ab1c3@enterprisedb.com> <20210409033703.GP6592@telsasoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210409033703.GP6592@telsasoft.com> User-Agent: Mutt/1.9.4 (2018-02-28) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk The docs seem to be wrong about the default. + are not yet in the buffer pool, during recovery. Valid values are + off (the default), on and + try. The setting try enables + concurrency and distance, respectively. By default, it is set to + try, which enabled the feature on systems where + posix_fadvise is available. Should say "which enables". + { + {"recovery_prefetch", PGC_SIGHUP, WAL_RECOVERY, + gettext_noop("Prefetch referenced blocks during recovery"), + gettext_noop("Look ahead in the WAL to find references to uncached data.") + }, + &recovery_prefetch, + RECOVERY_PREFETCH_TRY, recovery_prefetch_options, + check_recovery_prefetch, assign_recovery_prefetch, NULL + }, Curiously, I reported a similar issue last year. On Thu, Apr 08, 2021 at 10:37:04PM -0500, Justin Pryzby wrote: > --- a/doc/src/sgml/wal.sgml > +++ b/doc/src/sgml/wal.sgml > @@ -816,9 +816,7 @@ > prefetching mechanism is most likely to be effective on systems > with full_page_writes set to > off (where that is safe), and where the working > - set is larger than RAM. By default, prefetching in recovery is enabled > - on operating systems that have posix_fadvise > - support. > + set is larger than RAM. By default, prefetching in recovery is disabled. > >