Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c8SZL-0002BQ-IN for pgsql-hackers@arkaria.postgresql.org; Sun, 20 Nov 2016 13:54:07 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1c8SZK-0008N7-2l for pgsql-hackers@arkaria.postgresql.org; Sun, 20 Nov 2016 13:54:06 +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.84_2) (envelope-from ) id 1c8SZI-0008Lr-45 for pgsql-hackers@postgresql.org; Sun, 20 Nov 2016 13:54:04 +0000 Received: from gauss.credativ.com ([93.94.130.89]) by makus.postgresql.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1c8SZF-0004Ax-C9 for pgsql-hackers@postgresql.org; Sun, 20 Nov 2016 13:54:02 +0000 Received: from gauss.credativ.com (localhost [127.0.0.1]) by gauss.credativ.com (Postfix) with ESMTP id 8A38A1B4009; Sun, 20 Nov 2016 14:53:58 +0100 (CET) Received: from ex (ip-109-44-0-167.web.vodafone.de [109.44.0.167]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: ase@gauss.credativ.com) by gauss.credativ.com (Postfix) with ESMTPSA id 3F6F31B4008 for ; Sun, 20 Nov 2016 14:53:58 +0100 (CET) From: Andreas Seltenreich To: pgsql-hackers@postgresql.org Subject: [sqlsmith] Parallel worker crash on seqscan Date: Sun, 20 Nov 2016 14:53:56 +0100 Message-ID: <878tse6yvf.fsf@credativ.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Hi, the following query appears to reliably crash parallel workers on master as of 0832f2d. --8<---------------cut here---------------start------------->8--- set max_parallel_workers_per_gather to 2; set force_parallel_mode to 1; select subq.context from pg_settings, lateral (select context from pg_opclass limit 1) as subq limit 1; --8<---------------cut here---------------end--------------->8--- Backtrace of a worker below. regards, Andreas Core was generated by `postgres: bgworker: parallel worker for PID 27448 '. Program terminated with signal SIGSEGV, Segmentation fault. #0 MakeExpandedObjectReadOnlyInternal (d=0) at expandeddatum.c:100 100 if (!VARATT_IS_EXTERNAL_EXPANDED_RW(DatumGetPointer(d))) (gdb) bt #0 MakeExpandedObjectReadOnlyInternal (d=0) at expandeddatum.c:100 #1 0x0000563b0c9a4e98 in ExecTargetList (tupdesc=, isDone=0x7ffdd20400ac, itemIsDone=0x563b0e6a8b50, isnull=0x563b0e6a8ae0 "", values=0x563b0e6a8ac0, econtext=0x563b0e6a7db8, targetlist=0x563b0e6a8498) at execQual.c:5491 #2 ExecProject (projInfo=projInfo@entry=0x563b0e6a8368, isDone=isDone@entry=0x7ffdd20400ac) at execQual.c:5710 #3 0x0000563b0c9a514f in ExecScan (node=node@entry=0x563b0e6a8038, accessMtd=accessMtd@entry=0x563b0c9bc910 , recheckMtd=recheckMtd@entry=0x563b0c9bc900 ) at execScan.c:220 #4 0x0000563b0c9bc9c3 in ExecSeqScan (node=node@entry=0x563b0e6a8038) at nodeSeqscan.c:127 #5 0x0000563b0c99d6e8 in ExecProcNode (node=node@entry=0x563b0e6a8038) at execProcnode.c:419 #6 0x0000563b0c9995be in ExecutePlan (dest=0x563b0e67da40, direction=, numberTuples=0, sendTuples=, operation=CMD_SELECT, use_parallel_mode=, planstate=0x563b0e6a8038, estate=0x563b0e6a77f8) at execMain.c:1567 #7 standard_ExecutorRun (queryDesc=0x563b0e6a2828, direction=, count=0) at execMain.c:338 #8 0x0000563b0c99c911 in ParallelQueryMain (seg=, toc=0x7f55173aa000) at execParallel.c:745 #9 0x0000563b0c898b02 in ParallelWorkerMain (main_arg=) at parallel.c:1108 #10 0x0000563b0ca49cad in StartBackgroundWorker () at bgworker.c:726 #11 0x0000563b0ca55770 in do_start_bgworker (rw=0x563b0e621080) at postmaster.c:5535 #12 maybe_start_bgworker () at postmaster.c:5710 #13 0x0000563b0ca56238 in sigusr1_handler (postgres_signal_arg=) at postmaster.c:4959 #14 #15 0x00007f5516788293 in __select_nocancel () at ../sysdeps/unix/syscall-template.S:84 #16 0x0000563b0c818249 in ServerLoop () at postmaster.c:1665 #17 0x0000563b0ca577e2 in PostmasterMain (argc=3, argv=0x563b0e5fa490) at postmaster.c:1309 #18 0x0000563b0c819f6d in main (argc=3, argv=0x563b0e5fa490) at main.c:228 -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers