Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f875W-0005go-5J for pgsql-bugs@arkaria.postgresql.org; Mon, 16 Apr 2018 16:34:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f875T-0000Wc-UT for pgsql-bugs@arkaria.postgresql.org; Mon, 16 Apr 2018 16:34:39 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f86HF-0008A5-Ox for pgsql-bugs@lists.postgresql.org; Mon, 16 Apr 2018 15:42:45 +0000 Received: from forward1j.cmail.yandex.net ([5.255.227.19]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f86H9-0005gR-O6 for pgsql-bugs@lists.postgresql.org; Mon, 16 Apr 2018 15:42:44 +0000 Received: from mxback3j.mail.yandex.net (mxback3j.mail.yandex.net [IPv6:2a02:6b8:0:1619::10c]) by forward1j.cmail.yandex.net (Yandex) with ESMTP id 827A720EC9; Mon, 16 Apr 2018 18:42:34 +0300 (MSK) Received: from localhost (localhost [::1]) by mxback3j.mail.yandex.net (nwsmtp/Yandex) with ESMTP id JmBLeyneMR-gWKiF0vs; Mon, 16 Apr 2018 18:42:33 +0300 Received: by web12o.yandex.ru with HTTP; Mon, 16 Apr 2018 18:42:32 +0300 From: Vitaly V. Voronov To: Peter Geoghegan Cc: PostgreSQL mailing lists In-Reply-To: References: <152296798225.31227.6026116154621550125@wrigleys.postgresql.org> <3343581523000521@web56o.yandex.ru> Subject: Re: BUG #15144: *** glibc detected *** postgres: postgres smsconsole [local] SELECT: double free or corruption (!pre MIME-Version: 1.0 Message-Id: <1935021523893352@web12o.yandex.ru> X-Mailer: Yamail [ http://yandex.ru ] 5.0 Date: Mon, 16 Apr 2018 18:42:32 +0300 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=utf-8 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Hello, Peter. We have cat crash at our secondary server. This full stack trace from crash dump: (gdb) bt full #0 0x0000003d22232495 in raise () from /lib64/libc.so.6 No symbol table info available. #1 0x0000003d22233c75 in abort () from /lib64/libc.so.6 No symbol table info available. #2 0x0000003d222703a7 in __libc_message () from /lib64/libc.so.6 No symbol table info available. #3 0x0000003d22275dee in malloc_printerr () from /lib64/libc.so.6 No symbol table info available. #4 0x0000003d22278c80 in _int_free () from /lib64/libc.so.6 No symbol table info available. #5 0x0000000000808887 in tuplestore_end (state=0x1794898) at tuplestore.c:455 i = #6 0x00000000005e94e5 in ExecEndFunctionScan (node=0x178e3d8) at nodeFunctionscan.c:550 fs = 0x178e388 i = #7 0x00000000005cbaae in ExecEndPlan (queryDesc=0x16c6a38) at execMain.c:1451 resultRelInfo = i = l = #8 standard_ExecutorEnd (queryDesc=0x16c6a38) at execMain.c:468 estate = 0x178e278 oldcontext = 0x1677e48 #9 0x0000000000593d6e in PortalCleanup (portal=0x16c3138) at portalcmds.c:280 save_exception_stack = 0x7fff07538610 save_context_stack = 0x0 local_sigjmp_buf = {{__jmpbuf = {23867704, 2475436528305129399, 24351312, 24686200, 2, 24686152, -2475701272642631753, 2475437018370099127}, __mask_was_saved = 0, __saved_mask = {__val = {24686152, 15971042801079502775, 2475436856846141367, 0, 8280655, 0, 24149016, 9856140, 2, 1, 23867704, 140733316302126, 88, 23867704, 24351312, 9377246}}}} saveResourceOwner = 0x1678878 queryDesc = 0x16c6a38 #10 0x00000000007fcaca in PortalDrop (portal=0x16c3138, isTopCommit=0 '\000') at portalmem.c:510 __func__ = "PortalDrop" #11 0x00000000006e0eb2 in exec_simple_query (query_string=0x1738468 "select count(*) from pg_buffercache where isdirty") at postgres.c:1095 parsetree = 0x1739140 portal = 0x16c3138 snapshot_set = commandTag = completionTag = "SELECT 1\000\000\000\000\000\000\000\000h\204s\001\000\000\000\000h\204s\001\000\000\000\000m pg_buf\220!\002\"=\000\000\000\336\000\000\000\000\000\000\000\205\312~\000\000\000\000" querytree_list = plantree_list = 0x178ae48 receiver = 0x178ae78 format = 0 dest = DestRemote oldcontext = 0x1677e48 ---Type to continue, or q to quit--- parsetree_list = 0x1739270 parsetree_item = 0x1739250 save_log_statement_stats = 0 '\000' was_logged = 0 '\000' isTopLevel = 1 '\001' msec_str = "\220\205S\a\377\177\000\000\000\207S\a\377\177\000\000h\204s\001", '\000' __func__ = "exec_simple_query" #12 0x00000000006e256c in PostgresMain (argc=, argv=, dbname=0x16c8f08 "smsconsole", username=) at postgres.c:4072 query_string = 0x1738468 "select count(*) from pg_buffercache where isdirty" firstchar = 81 input_message = {data = 0x1738468 "select count(*) from pg_buffercache where isdirty", len = 50, maxlen = 1024, cursor = 50} local_sigjmp_buf = {{__jmpbuf = {140733316302560, 2475436528304998327, 1, 1523890764, -9187201950435737471, 0, -2475701272437110857, 2475436853937391543}, __mask_was_saved = 1, __saved_mask = {__val = {0, 0, 4294967295, 12667896, 1, 12667240, 0, 9259542123273814145, 0, 0, 1024, 23891912, 12732800, 1523890764, 8372124, 140733316302592}}}} send_ready_for_query = 0 '\000' disable_idle_in_transaction_timeout = 0 '\000' __func__ = "PostgresMain" #13 0x00000000006823e5 in BackendRun (argc=, argv=) at postmaster.c:4342 ac = 1 usecs = 446360 i = 1 av = 0x16c8fc8 maxac = #14 BackendStartup (argc=, argv=) at postmaster.c:4016 bn = pid = 0 #15 ServerLoop (argc=, argv=) at postmaster.c:1721 rmask = {fds_bits = {32, 0 }} selres = now = readmask = {fds_bits = {120, 0 }} nSockets = 7 last_lockfile_recheck_time = 1523890764 last_touch_time = 1523887759 #16 PostmasterMain (argc=, argv=) at postmaster.c:1329 opt = status = userDoption = listen_addr_saved = i = output_config_variable = __func__ = "PostmasterMain" #17 0x0000000000609fe8 in main (argc=3, argv=0x1676990) at main.c:228 No locals. 10.04.2018, 22:56, "Peter Geoghegan" : > On Fri, Apr 6, 2018 at 12:42 AM, Vitaly V. Voronov wrote: >>  Sorry. I can't do this. Because, 1s - this is production and 2nd - it had been initialized as replica. >>  We use 2 server, and this server (with error) now initialized as secondary. >>  We use pgpool for switching servers. >>  And i posted full log from Postgres logs. >>  All other logs is clear. > > I won't be able to help you without this information. > > -- > Peter Geoghegan