Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eWU79-0007su-8d for pgsql-general@arkaria.postgresql.org; Tue, 02 Jan 2018 21:28:51 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eWU78-0001Gg-S7 for pgsql-general@arkaria.postgresql.org; Tue, 02 Jan 2018 21:28:50 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1eWU78-0001GX-Hc for pgsql-general@lists.postgresql.org; Tue, 02 Jan 2018 21:28:50 +0000 Received: from mail-wr0-x241.google.com ([2a00:1450:400c:c0c::241]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1eWU72-0002nb-MS for pgsql-general@lists.postgresql.org; Tue, 02 Jan 2018 21:28:49 +0000 Received: by mail-wr0-x241.google.com with SMTP id 36so16475735wrh.1 for ; Tue, 02 Jan 2018 13:28:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=avbrief-com.20150623.gappssmtp.com; s=20150623; h=user-agent:date:subject:from:to:message-id:thread-topic:references :in-reply-to:mime-version:content-transfer-encoding; bh=A1m0Y8VV3a5WqXNdSDfSdkY02Cwe6mZG+J7l1fvrAqo=; b=r+JjCXrw+5MHmsmv5+XFfS5Bx0ztInVO/2ATozCaY5DZg8Uh9fFsf8zDHLbfA59+hz iNpXJ+/5EZqMWkVTlyY1jX+cUmH+BWuggu1aY5jPmyE3Kfm+aypxIvM5ctTcC273LVkR DZCvgglpwkZFIBgp4wnudd76QvZy/ZkM5TCMNoqm2c5h20iL21HUTXk4CdxDNJgRzV/z PqkqA/5yR/IG7+N/yEZZAjoaYI+8OPWqGyhuNSDG5BGAWaIKWP+p3g6fKE7wFfXDOnqG bD9LH6eJuMl9H1tR2dC9ueArEoX8MLfRev6+3EeZrrDjP52Q+Sh2ZznOwEztcqtsV4Z0 JmuA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:user-agent:date:subject:from:to:message-id :thread-topic:references:in-reply-to:mime-version :content-transfer-encoding; bh=A1m0Y8VV3a5WqXNdSDfSdkY02Cwe6mZG+J7l1fvrAqo=; b=K6srH6UlH0h46t4Z/99mKoOI7DHpeDjQUYaQo6NfPxgpovDP9rFrlPemgAR+x+5ium vplYikb5wAGqwWNhU1w2M3HLHf8i8cuGucBwzTNmHRC7nsHL5bsDqcWfMfmBpR9HncEY OHN/PUNUC/pm01c1RkUiDu79LSYSW2MMBuCOWPl2lbGRim2A2tNwdgfaBp6+TaO64Xg0 +sDqm8e2wrxPDxtOM2xrAdIxXxtaTh81gzlDpRoktBjNcJ2hxx3SKyxwBJrdOGsBTezp kBH+3J75UOea7kewM2EzEMaNmVndKHdhJ/Y3MLezVkMMs+K583Hey7+KbP5/EmmW227l 9Maw== X-Gm-Message-State: AKGB3mJYrfu9LtBEr0uIKh0ID+XHjWhjTslYIFQD+UvwgMdBshlChcuL zs9klKvAdaR+RUtAqIK0mAYV3RZqEZz3EWg8Bx9n/xq1cvqa1Qk6o4UK20SL0sID0VgtErmIMVn 7mYKCe3+esbdA1Ak6OCswRDlkYetGEDWAqhRUnK0qc0FbkPmzl+ry7qa2/MIuiCeJYUIT0uMFn1 OBgcVOWwPdh64= X-Google-Smtp-Source: ACJfBotUM6t3SYu8KChW/9/gXychIAf0MyN+ttgn09yFaNFQSktibDeT9vIYD7CdHSkGA/Io8rrmtA== X-Received: by 10.223.147.132 with SMTP id 4mr36609778wrp.92.1514928521906; Tue, 02 Jan 2018 13:28:41 -0800 (PST) Received: from [192.168.0.202] (cpc134188-nail4-2-0-cust164.know.cable.virginm.net. [77.99.14.165]) by smtp.gmail.com with ESMTPSA id i66sm22765002wmf.3.2018.01.02.13.28.40 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 02 Jan 2018 13:28:41 -0800 (PST) User-Agent: Microsoft-MacOutlook/f.29.0.171205 Date: Tue, 02 Jan 2018 21:28:39 +0000 Subject: Re: Slow system due to ReorderBufferGetTupleBuf? From: Martin Moore To: Message-ID: <57C5B258-0EB7-4DDF-8152-F2A03A1087EE@avbrief.com> Thread-Topic: Slow system due to ReorderBufferGetTupleBuf? References: <34E81031-B9DC-4626-97F6-B78AC45959D1@avbrief.com> <9097DCB4-E742-46A9-B72D-D902598CD1FC@avbrief.com> In-Reply-To: <9097DCB4-E742-46A9-B72D-D902598CD1FC@avbrief.com> Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 02/01/2018, 12:09, "Martin Moore" wrote: =20 =20 On 01/01/2018, 17:45, "Peter Geoghegan" wrote: =20 On Mon, Jan 1, 2018 at 8:56 AM, Martin Moore wrote: > Can someone shed some light on this and advise how to prevent it = reoccurring? =20 You're using v10, which has these two commits: =20 https://git.postgresql.org/gitweb/?p=3Dpostgresql.git;a=3Dcommit;h=3D58b2= 5e98106dbe062cec0f3d31d64977bffaa4af =20 https://git.postgresql.org/gitweb/?p=3Dpostgresql.git;a=3Dcommit;h=3D9fab= 40ad32efa4038d19eaed975bb4c1713ccbc0 =20 Unfortunately, per the commit message of the first commit, it doesn= 't look like the tuple allocator uses any new strategy, at least until this v11 commit: =20 https://git.postgresql.org/gitweb/?p=3Dpostgresql.git;a=3Dcommit;h=3Da4cc= c1cef5a04cc054af83bc4582a045d5232cb3 =20 My guess is that that would make a noticeable difference, once v11 becomes available. Could you test this yourself by building from th= e master branch? =20 --=20 Peter Geoghegan =20 =20 =20 =20 =20 Thanks Peter. I don=E2=80=99t really want to go down that route for various r= easons. There=E2=80=99s a task that copies =E2=80=98old=E2=80=99 rows to various old_ tables = and then deletes from the main tables, then does a vaccum and analyse. Table= s only have 20-30k rows. I=E2=80=99m guessing this may be the trigger for the prob= lem so have changed the timing from every 20 mins to once in the middle of t= he night when things are quiet. =20 Would this explain the problem? =20 =20 Martin. =20 =20 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Having stopped the suspect task, I=E2=80=99m still getting the same problem. Can=E2= =80=99t even stop postgres: waiting for server to shut down............................................= ................... failed pg_ctl: server does not shut down We=E2=80=99ve spent 2 yrs and a chunk of cash on a total system redesign and this= is going to stop it from being released. Can someone give me an idea what may be causing this =E2=80=93 and what ReorderBu= fferGetTupleBuf is actually doing in case it gives me a clue. Thanks. =20 =20 =20