Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gP97a-0000x9-H5 for pgsql-admin@arkaria.postgresql.org; Tue, 20 Nov 2018 16:43:31 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gP97Y-00026U-TR for pgsql-admin@arkaria.postgresql.org; Tue, 20 Nov 2018 16:43:28 +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_SHA1:256) (Exim 4.89) (envelope-from ) id 1gP95R-0008F5-57 for pgsql-admin@lists.postgresql.org; Tue, 20 Nov 2018 16:41:17 +0000 Received: from r0.smtpout1.paris1.alwaysdata.com ([2a00:b6e0:1:40:1:0:10:1]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gP95I-00077E-Lq for pgsql-admin@postgresql.org; Tue, 20 Nov 2018 16:41:15 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=alwaysdata.net; s=hexack; h=In-Reply-To:Content-Transfer-Encoding: Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Sender:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=mwlQjcuhFRltAVliOQrNuCcuHJ3x9gCeitbdY1y9zFQ=; b=DjoxhpocnNdMwUYYcpTfz2BYR3 AwmhsWD+FTZh/OhhiVKjy6beHADicj/FDqSinGpL3dOC+jOSBwkWjdF8hruGG/z8KyqVdk3fWamAl qHqngjOhcVjRogOe54baFj0scTJjM937aUX8vKC/5lDlt1bfNQhBtJ7+fWjZOm5mYIM4=; Received: from mas01-1-78-225-200-186.fbx.proxad.net ([78.225.200.186] helo=office.hexack.fr) by smtpout1.paris1.alwaysdata.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1gP95F-0002GK-2o; Tue, 20 Nov 2018 17:41:05 +0100 Date: Tue, 20 Nov 2018 17:41:03 +0100 From: =?utf-8?B?U3TDqXBoYW5l?= KANSCHINE To: David Modica Cc: "pgsql-admin@postgresql.org" Subject: Re: inserts take longer and longer Message-ID: <20181120164103.plefj3qzvgt6pd53@office.hexack.fr> References: <9a645d6c8749483c90f5f109889ea8ce@imaginesoftware.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <9a645d6c8749483c90f5f109889ea8ce@imaginesoftware.com> Organization: HexACK User-Agent: NeoMutt/20180716 X-alwaysdata-ID: 372945534 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Le mar. 20 nov., vers 15:55, David Modica exprimait : > hi all. Hi, > I hope this is the correct way to get help from the list. [...] > we have a developer who is doing batch inserts 20 at a time and each > subsequent batch is taking longer to the point where it is a > critical problem. I recently changed the out of the box config to > see if that would help but it hasn’t: [...] > any direction as to what to look at would be appreciated. When you're doing bulk insert, it's a good practice to drop index and recreate it after. Regards, -- Stéphane KANSCHINE - https://www.hexack.fr./ - https://www.nuajik.io./ @ stephane@hexack.fr  +33 6 64 31 72 52