Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ciM8Z-0007w8-TO for pgsql-bugs@arkaria.postgresql.org; Mon, 27 Feb 2017 14:18:52 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1ciM8Z-0007HS-D2 for pgsql-bugs@arkaria.postgresql.org; Mon, 27 Feb 2017 14:18:51 +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 1ciM8Y-0007H2-SN for pgsql-bugs@postgresql.org; Mon, 27 Feb 2017 14:18:50 +0000 Received: from mail-wm0-x230.google.com ([2a00:1450:400c:c09::230]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1ciM8U-0002M2-Hl for pgsql-bugs@postgresql.org; Mon, 27 Feb 2017 14:18:50 +0000 Received: by mail-wm0-x230.google.com with SMTP id v77so63686544wmv.0 for ; Mon, 27 Feb 2017 06:18:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding; bh=jiVBbNcZ2enPLuuIR3EkoVOVhNsSsySxELAhS6mbASw=; b=Un8bzC1GmN5InXfdIZLRoOhHsK497JLUDSsZPJZ7825/1YCn+bCpG6eGzKkfPvq42V L3xTVFVQA/yFES5vMrq6c3GhDzZFoueX9D0UidCX7JAvZCaGuSZlPgF8ZZUsIknMGmmZ LuZhzRAhszfohcLLK6oJ/YQwMkLUhLubxakRcAlaiYjlXIb4hWJGN3iOvaXvhJH/NYTS z1QpcTJRbslpcOIzd2qqD0F8gooOK9BNTlmdH6WKVO0/MtNZb4sMas0Ox5UB9KEmejSK quzJf9UK8CSBGwLJXuNtzycPVzqREmhgrk2/WUufPaV+ZrPanzsndD6zFaJwYL5J52xP KqeQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=jiVBbNcZ2enPLuuIR3EkoVOVhNsSsySxELAhS6mbASw=; b=RGNSBlnxA7G1yGyWuovIHcOMa9aH6ohAGUeYKI6ZdEmr4Mv028qol+tCTiJyTWV83C P9B84snJIKEpBS1H2om2K3U4IJoPoa6TffV8th/IeMGjJNIBSnLEc7m7/mZqKVCObWTg egX8blXJHXDZQUXhFo+vP2JTJnV8RIFmUA9M6lZYkD1nkj+cp7Ak6s9aEI3PxDpY4lIh E8tI50Ty+WrGMQ4MA/1ULP8VN+4+GYrfPYKw140F8AVj6JnM/pVMiBNvUR5poP498/zM oVEVEMxPY7b1PtSz4cR5CRdBWJ73LV4GhDNDG4YcmpOSTyKZFwtQ1lSAzQJaNiM8/mHS Q7uw== X-Gm-Message-State: AMke39kXH8LtHeRsr0jq0grRPMiLF76GqnNjlynCHi0p8qzQxHihk68qQjXnbc5GHWyWZsTiuxx+dtBOUXVa3QtnnJ+7vuZ1s7jF7TM0H+79c3hTIfk+E5CUC1I5U4azYSphhLCoAed2Zg+1tOfWMGfwZw4YZjC4U9kvYpg+wg6nIWdYCBpakaVb7neuBtoS6xRSWdoH X-Received: by 10.28.109.147 with SMTP id b19mr13210748wmi.69.1488205125714; Mon, 27 Feb 2017 06:18:45 -0800 (PST) Received: from [192.168.0.105] (150.123.broadband11.iol.cz. [90.178.123.150]) by smtp.gmail.com with ESMTPSA id q5sm22525977wrd.32.2017.02.27.06.18.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 27 Feb 2017 06:18:44 -0800 (PST) Subject: Re: BUG #14571: 10.0 devel hang when create subscription To: digoal@126.com, pgsql-bugs@postgresql.org References: <20170227081338.25057.52204@wrigleys.postgresql.org> From: Petr Jelinek Message-ID: <7a291899-090b-78c4-c39d-4988bbdb51e9@2ndquadrant.com> Date: Mon, 27 Feb 2017 15:18:44 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: <20170227081338.25057.52204@wrigleys.postgresql.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org On 27/02/17 09:13, digoal@126.com wrote: > The following bug has been logged on the website: > > Bug reference: 14571 > Logged by: Zhou Digoal > Email address: digoal@126.com > PostgreSQL version: Unsupported/Unknown > Operating system: CentOS 6.x x64 > Description: > > HI, > i use this commit: > https://git.postgresql.org/gitweb/?p=postgresql.git;a=snapshot;h=1513dbea7f89053476a5e95e2f2e952135a5b34c;sf=tgz > > when i create subscription , client hang . > > this is bt: > > (gdb) bt > #0 0x00007f0ab9e7df13 in __epoll_wait_nocancel () from /lib64/libc.so.6 > #1 0x0000000000846636 in WaitEventSetWait () > #2 0x0000000000846a83 in WaitLatchOrSocket () > #3 0x00007f0aaad5fed1 in libpqrcv_PQexec () from > /home/digoal/pgsql10/lib/libpqwalreceiver.so > #4 0x00007f0aaad5fff7 in libpqrcv_create_slot () from > /home/dege.zzz/pgsql10/lib/libpqwalreceiver.so > #5 0x000000000059e101 in CreateSubscription () > #6 0x00000000005e1f09 in ProcessUtilitySlow.isra.7 () > #7 0x00000000005e2f19 in standard_ProcessUtility () > #8 0x00000000005e3ab5 in PortalRunUtility () > #9 0x00000000005e7a8f in PortalRunMulti () > #10 0x00000000005e8550 in PortalRun () > #11 0x00000000005eb2d9 in exec_simple_query () > #12 0x00000000005ee4e5 in PostgresMain () > #13 0x0000000000471cc1 in ServerLoop () > #14 0x0000000000674e1b in PostmasterMain () > #15 0x000000000087ad32 in main () > Hi, okay so it hangs on slot creation. Slot creation can usually hang in two possible cases, a) either you tried to make loopback replication connection (the connection string given to CREATE SUBSCRIPTION points to same database you are executing it in) or b) there is a long running transaction on the PUBLICATION side. Does either of these explain what you see? -- Petr Jelinek http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs