Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1p28kb-0007ye-77 for pgsql-general@arkaria.postgresql.org; Mon, 05 Dec 2022 10:31:05 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1p28kZ-00030B-Hh for pgsql-general@arkaria.postgresql.org; Mon, 05 Dec 2022 10:31:03 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1p28kZ-000302-4h for pgsql-general@lists.postgresql.org; Mon, 05 Dec 2022 10:31:03 +0000 Received: from mout.gmx.net ([212.227.17.21]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1p28kW-0001g9-FJ for pgsql-general@postgresql.org; Mon, 05 Dec 2022 10:31:02 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=s31663417; t=1670236258; bh=/8woFOG1QLL2HaKkmYjgivkEnlRcSdBFR2XYWGnxSdk=; h=X-UI-Sender-Class:Date:From:To:Cc:Subject:References:In-Reply-To; b=FRN6yy5qN3MW33FYn4P0HOM9MkZNYszoahLpXkBuhZ8QOYn3qTgvgfCX5TvE7vnC3 zTwDgEzNP/lE6lRMJhgk5lmXoSqK6PSaxRTTZVXOCn8/dnXKhPC03wMZj1zhTO5UYM RwaV+P38TpKbeD1WWyvVbyoLrNU6voRkgz2AYyQkMeK7WfiMH0mZcKW15h03YZVMAp BnMiRF87PqD7Hm9ZWIFSnGU4MreuNx5rsa4BeeSoaazeLTmmNLkxIw+8e5wSib2voI o4QgUdOLqD3alzN6vL8xpqNj4TSPJAAEyx9fmFifWFmxlgPUzfyJ+gOY0ZqjhHvvwm jc+phBzNmFyLA== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from hermes ([91.9.21.195]) by mail.gmx.net (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1N63VY-1ovNT00J6u-016L3C; Mon, 05 Dec 2022 11:30:58 +0100 Received: from ncq by hermes with local (Exim 4.94.2) (envelope-from ) id 1p28kS-0002Cq-NR; Mon, 05 Dec 2022 11:30:56 +0100 Date: Mon, 5 Dec 2022 11:30:56 +0100 From: Karsten Hilbert To: shashidhar Reddy Cc: Pavel Stehule , pgsql-general Subject: Re: plpgsql_check_function issue after upgrade Message-ID: Mail-Followup-To: shashidhar Reddy , Pavel Stehule , pgsql-general References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: Ma_X_il-Followup-to: d Re_X_turn-receipt-to: Karsten.Hilbert@gmx.net Di_X_sposition-Notification-To: Karsten.Hilbert@gmx.net X-Confi_X_rm-Reading-To: Karsten.Hilbert@gmx.net X-Pri_X_ority: 2 (High) Sender: X-Provags-ID: V03:K1:7QCI0d2v/D5ApiyC3TSVD0F+yTVulSISK7Z8mqYDLLQtiC3YpRE 9pijlRlFYkAJfcmubxz5VOlBcuDc2Vr5FwBTs7ByNHttfjLqzuLHTHrYQKZAD1Jd2n6OcXm gLLM2VJpMzqovpsMrnc7vjbbHNrByBW5J9uvduKVtr/mWGfTMocdNPN5tVdusSxVAB5+UHW fsXwM9GyOKKQFm01VBbww== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:B0MQ61cdCvo=;KwhWcixTVuNVUprGiShPHl0MiW6 7PQpmtJ6qwuO/nKb7UIFcn5cJkxlVVxYWYngYpK3mbpQLKkBN6FtdB4CgrFfsuHLjD4Jk3uo0 UWcKjUZuwg6Z/LYwCVLavcp2Oh3RdQpaYqISHJ1KumSxzqN8hxrUx34A7ecrNvtYcLZDeh7UV YFYSuXms3r1THQOMETyxXgfKuZAUOC8vW7XrcP+N7Sko2l7KUgC8zjAIYmUj3sEHNNIOFr7C6 gAW/puXNRI4hHSw3QEaNF9PpAXpgBke1QpcLHoV7qwZhFCv6KZzRCouV5LKVaWooH4AYE+sWN NG7ShzXydwBN8rV9rMk4YNxMNhuY5TYR1nn/fNlKt86pUzeMO1rp1Gh88XVDCIrvfESpHtR2N WRGCyt+Un1iGiXyjwJRSmwHMVxm3kWsNxSD0fq8tU09GR7x+cmg7jBu0nP9JLFwbpa0cJUy7E TIWCdlneMLM1filN5rQw7rTRIJcgmpdxZ3Pd5UFYLAPcHuEJpOXDjzYOyNvwymHFKZxxwM4UD PN5sNgZ30q/kMGIKnivvk0F6kT8VIi6YjUQkA7D264TlWWrI+wtBQCOJWlW7TB2FzA/+OLOTg aAJebSNe8ucrCj0kiLSBO1qsDgGhLdlCuObcehv1Y5UuWWT1OgoIuPja1RQQocRhgwWB6isGu LJIdI8LQ0qwKA9WquZEX1wjSCjfXvDpF+2w98E/auPWWDQadPRRWg/7ZueRIfcISBzvkmizO/ 8KDwxhqWkIq7Wtjeim6XMyKcSD/6plYgQMQaplC0T8ZJdivMzm4YQ+FOKJ/vkebJst2jarWho LFiVSbSOpoJ/NnV84nhj194QRW/STzVRQKDfAbplT+DYjX/ecbCbU5g1vwcSzgomOaEzN6rER yB5JQLUaqVGrXysK0IMvwOTAZfNpPURPDCHMEJEay+RqeDGvn3fZmvsEUsFnv4nVfqWFZNIp4 IrNEDQ== List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Am Mon, Dec 05, 2022 at 03:54:28PM +0530 schrieb shashidhar Reddy: > Is there any way to get the older version 1.1 of plpgsql_check to instal= l > it? Is there any way to get you to respect the kind requests to follow this list's posting customs as expressed by the very people you want to help you ? Such as not to top post. Best regards, Karsten > On Mon, 5 Dec, 2022, 1:36 pm Pavel Stehule, wr= ote: > > > > > > > po 5. 12. 2022 v 8:42 odes=EDlatel shashidhar Reddy < > > shashidharreddy001@gmail.com> napsal: > > > >> Pavel, > >> > >> Below is the back trace result > >> > >> libffi6-dbg libgcc1-dbg libkrb5-dbg libstdc++6-8-dbg libxml2-dbg > >> postgresql-13-dbgsym postgresql-13-pldeb > >> ugger-dbgsym zlib1g-dbg > >> > > > > I am sorry, I don't anything > > > > > > > >> > >> On Mon, Dec 5, 2022 at 11:28 AM Pavel Stehule > >> wrote: > >> > >>> Hi > >>> > >>> > >>> po 5. 12. 2022 v 6:49 odes=EDlatel shashidhar Reddy < > >>> shashidharreddy001@gmail.com> napsal: > >>> > >>>> Pavel, > >>>> > >>>> Where can I get list-dbgsym-packages.sh script? > >>>> > >>> > >>> > >>> https://manpages.debian.org/testing/debian-goodies/find-dbgsym-packa= ges.1.en.html > >>> > >>> https://wiki.ubuntu.com/DebuggingProgramCrash > >>> > >>> please, don't use top-post style in this mailing list > >>> https://en.wikipedia.org/wiki/Posting_style > >>> > >>> Regards > >>> > >>> Pavel > >>> > >>> > >>> > >>>> On Wed, Nov 30, 2022 at 10:04 AM Pavel Stehule > >>>> wrote: > >>>> > >>>>> > >>>>> > >>>>> st 30. 11. 2022 v 5:28 odes=EDlatel Pavel Stehule < > >>>>> pavel.stehule@gmail.com> napsal: > >>>>> > >>>>>> > >>>>>> > >>>>>> st 30. 11. 2022 v 1:38 odes=EDlatel shashidhar Reddy < > >>>>>> shashidharreddy001@gmail.com> napsal: > >>>>>> > >>>>>>> I have tried updating after upgrade but that wasn't working, so= I > >>>>>>> have dropped and recreated the extension. > >>>>>>> Now it is crashing every time when we call the function. > >>>>>>> > >>>>>> > >>>>>> what is version od plpgsql_check on Postgres 12, what is version = of > >>>>>> plpgsql_check on Postgres 13 (with version of minor release)? > >>>>>> > >>>>>> Can you send backtrace? > >>>>>> https://wiki.postgresql.org/wiki/Getting_a_stack_trace_of_a_runni= ng_PostgreSQL_backend_on_Linux/BSD > >>>>>> > >>>>> > >>>>> Do you have installed some other extensions? > >>>>> > >>>>> > >>>>> > >>>>>> > >>>>>> > >>>>>> > >>>>>> > >>>>>> > >>>>>>> > >>>>>>> On Tue, 29 Nov, 2022, 9:58 pm Pavel Stehule, < > >>>>>>> pavel.stehule@gmail.com> wrote: > >>>>>>> > >>>>>>>> > >>>>>>>> > >>>>>>>> =FAt 29. 11. 2022 v 16:37 odes=EDlatel shashidhar Reddy < > >>>>>>>> shashidharreddy001@gmail.com> napsal: > >>>>>>>> > >>>>>>>>> Plogsql check version is 2.2 and one more finding is before > >>>>>>>>> calling the function if we drop and recreate the plpgsql_check= extension > >>>>>>>>> there is no issue, but each time we can't drop and create. > >>>>>>>>> > >>>>>>>> > >>>>>>>> Maybe you need to run ALTER EXTENSION plpgsql_check UPDATE befo= re > >>>>>>>> first usage in pg 13 > >>>>>>>> > >>>>>>>> If the extension works after re-installation, then the problem = is > >>>>>>>> not in an extension. > >>>>>>>> > >>>>>>>> > >>>>>>>> > >>>>>>>>> On Tue, 29 Nov, 2022, 7:19 pm shashidhar Reddy, < > >>>>>>>>> shashidharreddy001@gmail.com> wrote: > >>>>>>>>> > >>>>>>>>>> Hello Pavel, > >>>>>>>>>> > >>>>>>>>>> This is the function causing the issue on all servers, and al= so i > >>>>>>>>>> noticed when I use *plpgsql_check_function *in any function I= am > >>>>>>>>>> facing the same issue. > >>>>>>>>>> > >>>>>>>>>> > >>>>>>>>>> On Tue, Nov 29, 2022 at 6:43 PM Pavel Stehule < > >>>>>>>>>> pavel.stehule@gmail.com> wrote: > >>>>>>>>>> > >>>>>>>>>>> Hi > >>>>>>>>>>> > >>>>>>>>>>> > >>>>>>>>>>> =FAt 29. 11. 2022 v 13:49 odes=EDlatel shashidhar Reddy < > >>>>>>>>>>> shashidharreddy001@gmail.com> napsal: > >>>>>>>>>>> > >>>>>>>>>>>> Hello, > >>>>>>>>>>>> > >>>>>>>>>>>> Recently we have upgraded postgres from version 12 to 13 an= d > >>>>>>>>>>>> upgraded plpgsql_check to the latest version but > >>>>>>>>>>>> after upgrade when calling the below function causing postg= res restart . > >>>>>>>>>>>> > >>>>>>>>>>>> CREATE OR REPLACE FUNCTION pro.po_check( > >>>>>>>>>>>> ) > >>>>>>>>>>>> RETURNS void > >>>>>>>>>>>> LANGUAGE 'plpgsql' > >>>>>>>>>>>> COST 100 > >>>>>>>>>>>> VOLATILE SECURITY DEFINER PARALLEL UNSAFE > >>>>>>>>>>>> AS $BODY$ > >>>>>>>>>>>> DECLARE > >>>>>>>>>>>> BEGIN > >>>>>>>>>>>> > >>>>>>>>>>>> PERFORM p.oid, n.nspname, p.proname, > >>>>>>>>>>>> plpgsql_check_function(p.oid) > >>>>>>>>>>>> FROM pg_catalog.pg_namespace n > >>>>>>>>>>>> JOIN pg_catalog.pg_proc p ON pronamespace =3D n.oid > >>>>>>>>>>>> JOIN pg_catalog.pg_language l ON p.prolang =3D l.oid > >>>>>>>>>>>> WHERE l.lanname =3D 'plpgsql' AND p.prorettype <> 2279 > >>>>>>>>>>>> and upper(n.nspname) like upper('Pro'); > >>>>>>>>>>>> > >>>>>>>>>>>> END; > >>>>>>>>>>>> $BODY$; > >>>>>>>>>>>> > >>>>>>>>>>>> and the error in syslogs shows > >>>>>>>>>>>> kernel: [93631.415790] postgres[86383]: segfault at 80 ip > >>>>>>>>>>>> 00007f07f3e3eefd sp 00007fffcf1db500 error 4 in > >>>>>>>>>>>> plpgsql_check.so[7f07f3e2e000+34000] > >>>>>>>>>>>> > >>>>>>>>>>> > >>>>>>>>>>> it can be a bug in plpgsql_check. But I am not able to fix i= t > >>>>>>>>>>> without some information. Can you send the reproducer (minim= al example of > >>>>>>>>>>> your code, that reproduce this error)? > >>>>>>>>>>> > >>>>>>>>>>> Regards > >>>>>>>>>>> > >>>>>>>>>>> Pavel > >>>>>>>>>>> > >>>>>>>>>>>> > >>>>>>>>>>>> -- > >>>>>>>>>>>> Shashidhar > >>>>>>>>>>>> > >>>>>>>>>>> > >>>>>>>>>> > >>>>>>>>>> -- > >>>>>>>>>> Shashidhar > >>>>>>>>>> > >>>>>>>>> > >>>> > >>>> -- > >>>> Shashidhar > >>>> > >>> > >> > >> -- > >> Shashidhar > >> > > =2D- GPG 40BE 5B0E C98E 1713 AFA6 5BC0 3BEA AC80 7D4F C89B