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 1k0DYk-0004hd-Av for pgsql-hackers@arkaria.postgresql.org; Tue, 28 Jul 2020 00:33:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1k0DYi-0003yc-LP for pgsql-hackers@arkaria.postgresql.org; Tue, 28 Jul 2020 00:33:32 +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 1k0DYi-0003yV-DR for pgsql-hackers@lists.postgresql.org; Tue, 28 Jul 2020 00:33:32 +0000 Received: from mail.postgrespro.ru ([93.174.131.139]) by makus.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1k0DYa-0000yy-TT for pgsql-hackers@postgresql.org; Tue, 28 Jul 2020 00:33:31 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.postgrespro.ru (Postfix) with ESMTP id 5773B21C2C08; Tue, 28 Jul 2020 03:33:22 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at postgrespro.ru X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=x tagged_above=-99 required=4 WHITELISTED tests=[] autolearn=unavailable Received: from [192.168.0.104] (pool-77-222-105-198.is74.ru [77.222.105.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mail.postgrespro.ru (Postfix) with ESMTPSA id C197A21C2C07; Tue, 28 Jul 2020 03:33:21 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=postgrespro.ru; s=mail; t=1595896402; bh=dyG++vm2GXNGzTLErHmBJIP97JPOsiWH7sVBR4rH6HQ=; h=Subject:To:Cc:References:From:Date:In-Reply-To; b=c12LT47Xjh+uvmkgppecxTz0Mmb/gwdCpclOZJoojFCTiGo67ZKEXC7mmWrqkq9ay RnNVVqQUyaTYUVsEulpV/tdzEoPDq20I20RtanQ6moAeABnX6pGPevGpxGdFcodsqe qAwpsjY68T5zvI0Jtm03gq/2KAM2RC2Wjt6NEbRc= Subject: Re: [POC] Fast COPY FROM command for the table with foreign partitions To: Alexey Kondratov Cc: Amit Langote , Ashutosh Bapat , Ashutosh Bapat , Etsuro Fujita , PostgreSQL-Dev References: <3d0909dc-3691-a576-208a-90986e55489f@postgrespro.ru> <7a3c3bdd-dc43-68a7-7cc5-ae139f1de4a7@postgrespro.ru> <08721da1dc2da7c0e275593b4f8d9037@postgrespro.ru> From: Andrey Lepikhov Organization: Postgres Professional Message-ID: Date: Tue, 28 Jul 2020 05:33:19 +0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <08721da1dc2da7c0e275593b4f8d9037@postgrespro.ru> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk 27.07.2020 21:34, Alexey Kondratov пишет: > Hi Andrey, > > On 2020-07-23 09:23, Andrey V. Lepikhov wrote: >> On 7/16/20 2:14 PM, Amit Langote wrote: >>> Amit Langote >>> EnterpriseDB: http://www.enterprisedb.com >>> >> >> Version 5 of the patch. With changes caused by Amit's comments. > > Just got a segfault with your v5 patch by deleting from a foreign table. > It seems that ShutdownForeignScan inside node->fdwroutine doesn't have a > correct pointer to the required function. > > I haven't had a chance to look closer on the code, but you can easily > reproduce this error with the attached script (patched Postgres binaries > should be available in the PATH). It works well with master and fails > with your patch applied. I used master a3ab7a707d and v5 version of the patch with your script. No errors found. Can you check your test case? -- regards, Andrey Lepikhov Postgres Professional