Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1uZQ9n-003NDb-6Z for pgsql-general@arkaria.postgresql.org; Wed, 09 Jul 2025 08:27:59 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1uZQ9k-00EWZi-I2 for pgsql-general@arkaria.postgresql.org; Wed, 09 Jul 2025 08:27:57 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1uZQ9k-00EWZV-05 for pgsql-general@lists.postgresql.org; Wed, 09 Jul 2025 08:27:56 +0000 Received: from mail-oi1-x234.google.com ([2607:f8b0:4864:20::234]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1uZQ9i-006MO4-2I for pgsql-general@lists.postgresql.org; Wed, 09 Jul 2025 08:27:55 +0000 Received: by mail-oi1-x234.google.com with SMTP id 5614622812f47-40a4de175a3so3007038b6e.0 for ; Wed, 09 Jul 2025 01:27:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1752049674; x=1752654474; darn=lists.postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=GHM5L15h7raSGr4bA/QaD2MZaXpysn+7QZn+z5QF4gE=; b=JQ8eN9phYuVZm/IpiCVD57g/hiJA9hM/4dKSQqTJFfIPmGAQv+lYfZOTvbnjY4w/Zb fErI+k+fEMJUhkwEPqeTG6+xltmOelN09prIXp93wIFfm/QNprCUC/ImvoCWwqVk9ZTx +IFJ50wTH0mfUm9j0lfzeN9fbNbUGlyJqFLDmRZyKfxK9YG16psLvL1VLME+D7Bx1yMs hrh04vc/LUAvO2V4vbd9N2m1rOcz6KzQ3P8OoSV3D0V0KYkhK/2DJAt9hdGmG1HMHrKL TX1aCPbMC4008CfPGSGW/zcKUucsRb/CwV74t13NlzWmBh2izt/qALmc33UzRjSHCBo2 b8KA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752049674; x=1752654474; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=GHM5L15h7raSGr4bA/QaD2MZaXpysn+7QZn+z5QF4gE=; b=h64d0SqAWCZ+leOfNPG9nedmRhxkx+8ayDbsRvwRwW8SIVHuY2CtLlyatP0uFvrIjf 368UFic0CgtkylT/gmlSPHCQ2kvJ2PbERLDrmb0Sk9l4axcJdl5yH+K2f/xcUOM8T95U ljNlwwAw8Os356YqUDzb7rnNJRyVqz3l5vtA9kZTE8NhmfGjsvWKI50A1XftreGwyJZq 8RVi+zH0pZCZmVV02aF1LUYa3Db/VyYAkRl+f5jV2IiRUMsp0VdtMYXEobNguJ1GA3cX NKQR+iQWm99U6j9QFPqjkvgJMGoz6GeIiBi3TLxRvEeseW6MVv60Dy+tyPIdRklKEoMe +zMg== X-Gm-Message-State: AOJu0YxlS9CiNepaPipj8pQLyw03lvMUR9BCqixwC7v+Zw4SlvVucvr0 g7r7iB8sCHGsuwdLLDGm9/JMMNsmueu8IEH8GDeqLuhJx1Q1PFrTzx0oMCbTHoVLbtRLIbtTLGm sek5T72f9DDnVUq6E73XFLWPdC2umBJk= X-Gm-Gg: ASbGncsR3KRRV5x35fTrWGPLgzYVYaAp4M3COaMC32X3jhReEJ88NvcFs4Z2o3+nwCv 0n0P5sO1909RivQhi4xnuhRbXT+mTDdT9pqZ4YtSd87uMyh1kj7bnZerqFR5ggOJ7Fbj+Mss0mV m826DW9s2oDhvnxxeqYN5ugI0MxDnF7tWdpBuUm8DZi9hdXw== X-Google-Smtp-Source: AGHT+IFUNFM/4nwaAxPiWhZBLKBVKpc72YPm4pHC2Y3yRbPZyEskNv+26A1XE7vT28gYxvx78AcLFoRT54VcpMVJoF0= X-Received: by 2002:a05:6808:470a:b0:406:3370:3bc6 with SMTP id 5614622812f47-412ba37c5aemr1180126b6e.2.1752049673775; Wed, 09 Jul 2025 01:27:53 -0700 (PDT) MIME-Version: 1.0 References: <2138039822.1224213.1751997247151.ref@mail.yahoo.com> <2138039822.1224213.1751997247151@mail.yahoo.com> In-Reply-To: From: Shlok Kyal Date: Wed, 9 Jul 2025 13:57:42 +0530 X-Gm-Features: Ac12FXyGzY4Vo6Trrv9C5l3rXJ7MXEXL7fXWREoSVhF6TRvg03iqIUEdyjEwt00 Message-ID: Subject: =?UTF-8?Q?Re=3A_error_=E2=80=9Cserver_process_was_terminated_by_signal?= =?UTF-8?Q?_11=3A_Segmentation_fault=E2=80=9D_running_pg=5Fcreate=5Flogical=5Freplica?= =?UTF-8?Q?tion=5Fslot_using_pgoutput_plugin?= To: abrahim abrahao Cc: "pgsql-general@lists.postgresql.org" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, 9 Jul 2025 at 12:19, Shlok Kyal wrote: > > On Wed, 9 Jul 2025 at 11:43, abrahim abrahao wro= te: > > > > I got error =E2=80=9Cserver process was terminated by signal 11: Segmen= tation fault=E2=80=9D using pg_create_logical_replication_slot with pgoutpu= t plugin parameter and using test_decoding worked fine, any idea that is wr= ong? > > > > Note: I am using docker container and I also updated shm-size from 1024= mb to 2g and I am using shared_buffers=3D1.5GB. > > This is a test server and there is nothing else running. IT is the firs= t time I am working with logical replication. > > > > See details below > > > > postgresql.conf file: > > wal_level =3D logical > > max_replication_slots =3D 10 > > max_wal_senders =3D 20 > > listen_addresses =3D '*' > > > > > > > > psql -U postgres -h postgres -c "SELECT pg_create_logical_replication_= slot('support7561_repslot', 'pgoutput');" > > SSL SYSCALL error: EOF detected > > connection to server was lost > > > > > > < 2025-07-08 14:57:08.653 UTC psql postgres postgres 172.18.0.94(53414)= SELECT 00000 2025-07-08 14:57:07 UTC 1096 686d31c3.448 2025-07-08 14:57:08= .653 UTC > LOG: Initializing CDC decoder > > < 2025-07-08 14:57:08.653 UTC psql postgres postgres 172.18.0.94(53414)= SELECT 00000 2025-07-08 14:57:07 UTC 1096 686d31c3.448 2025-07-08 14:57:08= .653 UTC > STATEMENT: SELECT pg_create_logical_replication_slot('support75= 61_repslot', 'pgoutput'); > > < 2025-07-08 14:57:08.821 UTC 00000 2025-07-08 14:55:38 UTC 923 68= 6d316a.39b 2025-07-08 14:57:08.821 UTC > LOG: server process (PID 1096) wa= s terminated by signal 11: Segmentation fault > > < 2025-07-08 14:57:08.821 UTC 00000 2025-07-08 14:55:38 UTC 923 68= 6d316a.39b 2025-07-08 14:57:08.821 UTC > DETAIL: Failed process was runnin= g: SELECT pg_create_logical_replication_slot('support7561_repslot', 'pgoutp= ut'); > > < 2025-07-08 14:57:08.821 UTC 00000 2025-07-08 14:55:38 UTC 923 68= 6d316a.39b 2025-07-08 14:57:08.821 UTC > LOG: terminating any other active= server processes > > < 2025-07-08 14:57:08.829 UTC 00000 2025-07-08 14:55:38 UTC 923 68= 6d316a.39b 2025-07-08 14:57:08.829 UTC > LOG: all server processes termina= ted; reinitializing > > < 2025-07-08 14:57:09.215 UTC 00000 2025-07-08 14:57:09 UTC 1098 6= 86d31c5.44a 2025-07-08 14:57:09.215 UTC > LOG: database system was interru= pted; last known up at 2025-07-08 14:55:39 UTC > > < 2025-07-08 14:57:10.037 UTC [unknown] postgres postgres 172.18.0.217(= 33506) 57P03 2025-07-08 14:57:10 UTC 1101 686d31c6.44d 2025-07-08 14:57:10= .037 UTC > FATAL: the database system is in recovery mode > > < 2025-07-08 14:57:10.437 UTC 00000 2025-07-08 14:57:09 UTC 1098 6= 86d31c5.44a 2025-07-08 14:57:10.437 UTC > LOG: database system was not pro= perly shut down; automatic recovery in progress > > < 2025-07-08 14:57:10.450 UTC 00000 2025-07-08 14:57:09 UTC 1098 6= 86d31c5.44a 2025-07-08 14:57:10.450 UTC > LOG: redo starts at 1FB9/C0000A0 > > < 2025-07-08 14:57:10.456 UTC 00000 2025-07-08 14:57:09 UTC 1098 6= 86d31c5.44a 2025-07-08 14:57:10.456 UTC > LOG: invalid record length at 1F= B9/C054DF8: wanted 24, got 0 > > < 2025-07-08 14:57:10.456 UTC 00000 2025-07-08 14:57:09 UTC 1098 6= 86d31c5.44a 2025-07-08 14:57:10.456 UTC > LOG: redo done at 1FB9/C054DC0 s= ystem usage: CPU: user: 0.00 s, system: 0.00 s, elapsed: 0.00 s > > < 2025-07-08 14:57:10.475 UTC 00000 2025-07-08 14:57:09 UTC 1099 6= 86d31c5.44b 2025-07-08 14:57:10.475 UTC > LOG: checkpoint starting: end-of= -recovery immediate wait > > < 2025-07-08 14:57:10.501 UTC 00000 2025-07-08 14:57:09 UTC 1099 6= 86d31c5.44b 2025-07-08 14:57:10.501 UTC > LOG: checkpoint complete: wrote = 86 buffers (0.0%); 0 WAL file(s) added, 0 removed, 2 recycled; write=3D0.01= 0 s, sync=3D0.007 s, total=3D0.028 s; sync files=3D18, longest=3D0.003 s, a= verage=3D0.001 s; distance=3D339 kB, estimate=3D339 kB > > < 2025-07-08 14:57:10.510 UTC 00000 2025-07-08 14:55:38 UTC 923 68= 6d316a.39b 2025-07-08 14:57:10.510 UTC > LOG: database system is ready to = accept connections > > > > > > psql -U postgres -h postgres -c "SELECT pg_create_logical_replication_= slot('support7561_repslot', 'test_decoding');" > > pg_create_logical_replication_slot > > ------------------------------------ > > (support7561_repslot,1FB9/C081668) > > (1 row) > > > > postgres@support7560_postgres:/var/lib/postgresql/15/main$ psql -U post= gres -h postgres -c "SELECT slot_name, plugin, slot_type, database, active,= restart_lsn, confirmed_flush_lsn FROM pg_replication_slots;" > > slot_name | plugin | slot_type | database | active | = restart_lsn | confirmed_flush_lsn > > ---------------------+---------------+-----------+----------+--------+-= -------------+--------------------- > > support7561_repslot | test_decoding | logical | postgres | f | = 1FB9/C081630 | 1FB9/C081668 > > > > > > SHOW shared_buffers; > > shared_buffers > > ---------------- > > 1532512kB > > (1 row) > > > > postgres=3D# \! uname -a > > Linux support7560_postgres 6.8.0-1030-gcp #32~22.04.1-Ubuntu SMP Tue Ap= r 29 23:17:09 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux > > > > psql -U postgres -h postgres -c "select version()" > > version > > -----------------------------------------------------------------------= -------------------------------------------------------------- > > PostgreSQL 15.13 (Ubuntu 15.13-1.pgdg24.04+1) on x86_64-pc-linux-gnu, = compiled by gcc (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0, 64-bit > > Hi Abrahim, > > Can you also share the stack trace for the crash? > Also can you share the exact steps used to reproduce the issue? > Also, I was going to the logs on found: > > < 2025-07-08 14:57:08.653 UTC psql postgres postgres 172.18.0.94(53414)= SELECT 00000 2025-07-08 14:57:07 UTC 1096 686d31c3.448 2025-07-08 14:57:08= .653 UTC > LOG: Initializing CDC decoder This log is not present in Postgres source code. Why is this log appearing = here? Also I would suggest you to post this issue in pgsql-hackers mailing list [= 1]. [1]: pgsql-hackers@lists.postgresql.org Thanks and Regards, Shlok Kyal