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 1uTetN-007Y7Z-0a for pgsql-general@arkaria.postgresql.org; Mon, 23 Jun 2025 10:59:13 +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 1uTetL-001sPT-3U for pgsql-general@arkaria.postgresql.org; Mon, 23 Jun 2025 10:59:11 +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 1uTetK-001sPK-8b for pgsql-general@lists.postgresql.org; Mon, 23 Jun 2025 10:59:11 +0000 Received: from fhigh-b4-smtp.messagingengine.com ([202.12.124.155]) by makus.postgresql.org with smtp (Exim 4.96) (envelope-from ) id 1uTetI-003X6H-39 for pgsql-general@lists.postgresql.org; Mon, 23 Jun 2025 10:59:09 +0000 Received: from phl-compute-03.internal (phl-compute-03.phl.internal [10.202.2.43]) by mailfhigh.stl.internal (Postfix) with ESMTP id B9F0B254011D; Mon, 23 Jun 2025 06:59:07 -0400 (EDT) Received: from phl-mailfrontend-01 ([10.202.2.162]) by phl-compute-03.internal (MEProxy); Mon, 23 Jun 2025 06:59:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kurilemu.de; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:subject:subject:to:to; s=fm3; t=1750676347; x= 1750762747; bh=xBRA/7ieHGmJ96ysFBWcxzKQezuz9Qfr2riZaED/JJ4=; b=X QgIJV4LlNbqDAaYLrZpClnz0jMEAJB0LzN8U8tvlJWx6u/83bWy/SkoWKSzchTfi 5644ycj+c2LtysZ0NgLweTfso0b3B5ukjOC9/dChPSvFvu2+SkD6ZNxHS5HnZFUq BWDbvRVSlpTVni+wUXdH4GRyBClLXeQyGAQjUE20tmvJ1wQ6PSPScVM0v5kdJIkv F9gvoL9fGt8hhgOUMvILtq/LrDSH2GufdkKU/7logTSQyTG6ZQ6qtt+k4HjB/rCK RV1EhkDaLP0QZRbuP8/MefrSxRwF3MoigfKgnVJOELxItKC2Gd1Umd6pWqmu/Gj+ xs2hBPESubOHTcLNjywzg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:subject:subject:to:to:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm1; t=1750676347; x=1750762747; bh=x BRA/7ieHGmJ96ysFBWcxzKQezuz9Qfr2riZaED/JJ4=; b=D1/dgeP1lGolsu7j7 MLeR7rqeb4Ilzs7cLGThOTJ4TKVHTtbPRHstI+Jm8VWptB3KxKtWhe2yCBUkepks S9h11hSUUCxcWne76EvAOhX4ooadAyvgqUB/pctzSkAUQl88aglr0jX4j3zIC7J5 j/NdF+/qg2X2SzgtSEinT2H7klqGu9sORdkoTyDNzHHzpdDp7SmIX6E3Vx25Wm6A M4XpX080QpUpPJjpL3H95WQbi9nmMDnLK22H/KxHIr8rrv63Q4lPDQAUmCp4j36A TQfy2oBdxIWMdQiFUI8SESZnCRRTHJlNK+izMtdeGjepFMvFyOBR22YojQv1O7Bm Xtr0Q== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtddvgdduieekgecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpuffrtefokffrpgfnqfghnecuuegr ihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjug hrpeffhffvvefukfggtggugfgjsehtkeertddttdejnecuhfhrohhmpemllhhvrghrohcu jfgvrhhrvghrrgcuoegrlhhvhhgvrhhrvgeskhhurhhilhgvmhhurdguvgeqnecuggftrf grthhtvghrnhepteeuvdehffekvefgueehveetveekgfegtddtueefueehuddutdfhfeff hfejfeffnecuffhomhgrihhnpegvnhhtvghrphhrihhsvggusgdrtghomhenucevlhhush htvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrlhhvhhgvrhhrvges khhurhhilhgvmhhurdguvgdpnhgspghrtghpthhtohepvddpmhhouggvpehsmhhtphhouh htpdhrtghpthhtohepugguvghvihgvnhhnvgesghhmrghilhdrtghomhdprhgtphhtthho pehpghhsqhhlqdhgvghnvghrrghlsehlihhsthhsrdhpohhsthhgrhgvshhqlhdrohhrgh X-ME-Proxy: Feedback-ID: ie3de48e3:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 23 Jun 2025 06:59:07 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kurilemu.de; s=schmee; t=1750676344; bh=csW/hBDGrbFvoaK+zHWRfFVO8nVPb6mIRWJntuRTCaY=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=tLBazF7KOJjStGdQdMwv3hIfbJ9Tmwazfvax2XLWi6EZ2fjXe3eAoVi+XFHzC4UyB rrsNz0Wokku91KjKTt/5fFStISU9+aHGY8kImGf/an8wnRBK2k0DbaqApg9fMYQ6pN V4TaWJUbqlIScJle2O6bXQ+oPr7AqOMVCf7wbhZp4XCpac6+5nnOjX6uvapHCjbrm3 RhnH2h2hsrwBnJGzagmZe5xo4tXmD/wJia5+R7j3ZgweVm4YZIUvpK0ZiPr/oQBfTl 4HuHRAJPFlNXgONFKw3mEjSOnLC0pIpYBE81FzlWCQGoFiNEtZWN0uGM2FB6T1WHjQ EnpfBXbUxL7iA== Received: by schmee.kurilemu.local (Postfix, from userid 1000) id EE44B8F; Mon, 23 Jun 2025 12:59:04 +0200 (CEST) Date: Mon, 23 Jun 2025 12:59:04 +0200 From: =?utf-8?Q?=C3=81lvaro?= Herrera To: Dominique Devienne Cc: pgsql-general@lists.postgresql.org Subject: Re: Extension disappearing act Message-ID: <202506231059.eflzcnqg67rc@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2025-Jun-19, Dominique Devienne wrote: > Hi. Little mystery we don't understand. v17. > > Create new DB, owned by dedicated new ROLE. > Create extension (pgcrypto) in our case. Installed in public, owned by > DB owner role. > Create schemas and populate them inside the DB. I would investigate this using an event trigger attached to the sql_drop event. That should allow you to identify exactly when the extension is dropped. Something like CREATE OR REPLACE FUNCTION report_dropped() RETURNS event_trigger AS $$ DECLARE r record; BEGIN FOR r IN SELECT * from pg_event_trigger_dropped_objects() LOOP RAISE NOTICE 'orig=% normal=% istemp=% type=% identity=% name=% args=%', r.original, r.normal, r.is_temporary, r.object_type, r.object_identity, r.address_names, r.address_args; END LOOP; END; $$ LANGUAGE plpgsql; CREATE EVENT TRIGGER svar_regress_event_trigger_report_dropped ON sql_drop EXECUTE PROCEDURE report_dropped(); -- Álvaro Herrera Breisgau, Deutschland — https://www.EnterpriseDB.com/ "En las profundidades de nuestro inconsciente hay una obsesiva necesidad de un universo lógico y coherente. Pero el universo real se halla siempre un paso más allá de la lógica" (Irulan)