Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1foTg4-0000zE-4I for pgsql-hackers@arkaria.postgresql.org; Sat, 11 Aug 2018 13:11:32 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1foTg1-0002xq-OQ for pgsql-hackers@arkaria.postgresql.org; Sat, 11 Aug 2018 13:11:29 +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.89) (envelope-from ) id 1foTg1-0002xj-Ck for pgsql-hackers@lists.postgresql.org; Sat, 11 Aug 2018 13:11:29 +0000 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1foTfx-0005n3-7z for pgsql-hackers@postgresql.org; Sat, 11 Aug 2018 13:11:28 +0000 Received: by mail-wr1-x442.google.com with SMTP id h15-v6so10500267wrs.7 for ; Sat, 11 Aug 2018 06:11:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=ucCq6IPEOTOp4KW5YvRkXg5zMMnhJ+pT5SUEZxa3+IY=; b=JNeLqaLoTmYl+EOM4ilforPO61cZUU4V35C+2fMnD7yELhH2RE7ft2fouQTratVJS8 tKpx2U+6qIt6mC5hSsdshacMeTP7XmaXsZRSDO6Ly3tbIKCrIWTL1lU2T6Npflx/G8A6 i1ZLqHsbmBQeT+vByZ9dwkqXmb6e8PAvZokcmAlI4WydjuwVVqZj9hERlF4+Wc93xLih puMDHiURW0zByxgXFXWj2MdnzBOvZ61iTDbASijiOPeHMPvphov4hV9401WVMKnQ6Tjo bW6ievDZXA9Zqwqwa9Mbc3Q3QcoruLE3ZbjcSjmmopoCj2rFeRENlwAilWcay2fKdvjD aMMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=ucCq6IPEOTOp4KW5YvRkXg5zMMnhJ+pT5SUEZxa3+IY=; b=ZN+81CKwYygtQ3nyRzB8nigbD5had/w/r7eEF16gaQy5b6bJtTG7GHnlZVutE0JGkr NKOYwKxMKN+pxqptnWY51KiSEERwzysMopLbLT673MEN8YXkbBft/K2TYPwC/cybkt2+ 7I6w/uCcSsI0DV5NS9xj4e76IMSfaSbh7grgb3dzk/le67ioSyx5E10DIn9DiUd22Vcl L54ggAkFCLghdIjtQY/3XwW0DzuPkHXteIp45oHYwzocldBZTC8Rm1jhwNevbfXUwsXo vHnzlzrOHPqXdBQthUsmN5ZiK5158HT/qwlTygl0026ejyKdznv4SxW9k0cMUiwbCLsD yT/g== X-Gm-Message-State: AOUpUlHpPgg0m0EzbdawT+9GMyRrzxIKux//0njLiHJOmfhdQclxo36A B0JAbKYgMq+SyXys+wA1CbXJzjIFrX6QLA3xLMn3cgN2FYJJV0jlIPApszz5sGQ0HHD3y2+VsvN 27+p4+CRXIL2n81px69oZNOf0qAp0fgDCti+z4Vi8eIQlF6rnGzpZWm+8ngVH5UBh0S2FhyRjBD K2cN4VxLEHjEo= X-Google-Smtp-Source: AA+uWPxlgfHPj8um14M6BSbJg4DDiCHVLqGypsY+id4YnD2rsUokhubOtAYO4gUBToroJyUe4VrUIg== X-Received: by 2002:adf:8276:: with SMTP id 109-v6mr6760178wrb.127.1533993083633; Sat, 11 Aug 2018 06:11:23 -0700 (PDT) Received: from [10.137.2.19] (ip-78-102-97-226.net.upcbroadband.cz. [78.102.97.226]) by smtp.gmail.com with ESMTPSA id v124-v6sm5418711wma.18.2018.08.11.06.11.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 11 Aug 2018 06:11:22 -0700 (PDT) Subject: Re: logical decoding / rewrite map vs. maxAllocatedDescs To: Andres Freund Cc: Alvaro Herrera , PostgreSQL-development References: <20180809174746.aa6rbpsu4zjipzif@alvherre.pgsql> <20180810211340.nlgyfa7jlmkjcs5m@alap3.anarazel.de> <470adb65-5101-4659-d213-41bde1eef8f2@2ndquadrant.com> <0328ccdf-17d6-911b-ae35-c6dc4c76708a@2ndquadrant.com> <20180811073415.laximmjm4d67rxuh@alap3.anarazel.de> From: Tomas Vondra Message-ID: Date: Sat, 11 Aug 2018 15:11:19 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 MIME-Version: 1.0 In-Reply-To: <20180811073415.laximmjm4d67rxuh@alap3.anarazel.de> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 08/11/2018 09:34 AM, Andres Freund wrote: > Hi, > > On 2018-08-11 01:55:43 +0200, Tomas Vondra wrote: >> On 08/10/2018 11:59 PM, Tomas Vondra wrote: >>> >>> ... >>> >>> I suspect there's some other ingredient, e.g. some manipulation with the >>> subscription. Or maybe it's not needed at all and I'm just imagining things. >>> >> >> Indeed, the manipulation with the subscription seems to be the key here. >> I pretty reliably get the 'could not read block' error when doing this: >> >> 1) start the insert pgbench >> >> pgbench -n -c 4 -T 300 -p 5433 -f insert.sql test >> >> 2) start the vacuum full pgbench >> >> pgbench -n -f vacuum.sql -T 300 -p 5433 test > > Just to be clear: 5433 is the subscriber, right? I tried it with both, > but it's not clear what you meant with either the previous or the this > email. > Sorry for the confusion, 5433 was the publisher - I reinitialized the cluster sometime after the initial report, and happened to swap the port numbers. That is, both pgbench commands run on the publisher, while the subscriber tries to sync the table (and fails due to duplicate values). I can reproduce it pretty reliably, although it may take a couple of sync tries from the subscriber. regards -- Tomas Vondra http://www.2ndQuadrant.com PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services