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 1lbuU9-0001G4-Ug for pgsql-hackers@arkaria.postgresql.org; Thu, 29 Apr 2021 00:24:53 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lbuU8-0001ou-J5 for pgsql-hackers@arkaria.postgresql.org; Thu, 29 Apr 2021 00:24:52 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lbuU7-0001om-OE for pgsql-hackers@lists.postgresql.org; Thu, 29 Apr 2021 00:24:51 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lbuU5-0003n9-GS for pgsql-hackers@postgresql.org; Thu, 29 Apr 2021 00:24:50 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 13T0Ohdi2949951; Wed, 28 Apr 2021 20:24:43 -0400 From: Tom Lane To: Andres Freund cc: Thomas Munro , Stephen Frost , Alvaro Herrera , David Steele , Dmitry Dolgov <9erthalion6@gmail.com>, Jakub Wartak , Tomas Vondra , pgsql-hackers Subject: Re: WIP: WAL prefetch (another approach) In-reply-to: <20210429001224.cdkef4ybkw7gramv@alap3.anarazel.de> References: <773932.1619022622@sss.pgh.pa.us> <892344.1619054465@sss.pgh.pa.us> <20210428163245.ff67pb2ii5irr5zr@alap3.anarazel.de> <2808045.1619628335@sss.pgh.pa.us> <2947529.1619652293@sss.pgh.pa.us> <20210429001224.cdkef4ybkw7gramv@alap3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Wed, 28 Apr 2021 17:12:24 -0700" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2949949.1619655883.1@sss.pgh.pa.us> Date: Wed, 28 Apr 2021 20:24:43 -0400 Message-ID: <2949950.1619655883@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Andres Freund writes: > On 2021-04-28 19:24:53 -0400, Tom Lane wrote: >> IOW, we've spent over twice as many CPU cycles shipping data to the >> standby as we did in applying the WAL on the standby. > I don't really know how the time calculation works on mac. Is there a > chance it includes time spent doing IO? I'd be pretty astonished if it did. This is basically a NetBSD system remember (in fact, this ancient macOS release is a good deal closer to those roots than modern versions). BSDen have never accounted for time that way AFAIK. Also, the "ps" man page says specifically that that column is CPU time. > Oh! I was about to ask how much shared buffers your primary / standby > have. And I think I may actually have reproduce a variant of the issue! Default configurations, so 128MB each. regards, tom lane