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 1tjlPF-00DCCn-Tg for pgsql-general@arkaria.postgresql.org; Sun, 16 Feb 2025 20:38:26 +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 1tjlPE-00AhKn-FK for pgsql-general@arkaria.postgresql.org; Sun, 16 Feb 2025 20:38:24 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tjlPD-00AhKe-2L for pgsql-general@lists.postgresql.org; Sun, 16 Feb 2025 20:38:24 +0000 Received: from fout-b5-smtp.messagingengine.com ([202.12.124.148]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1tjlP9-001DTn-25 for pgsql-general@lists.postgresql.org; Sun, 16 Feb 2025 20:38:22 +0000 Received: from phl-compute-06.internal (phl-compute-06.phl.internal [10.202.2.46]) by mailfout.stl.internal (Postfix) with ESMTP id 4A78F1140103; Sun, 16 Feb 2025 15:38:17 -0500 (EST) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-06.internal (MEProxy); Sun, 16 Feb 2025 15:38:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm2; t=1739738297; x=1739824697; bh=fjMpY8Duf2l4m+G76eHnu/nmULmXHO5CYkxNnNDpZPA=; b= UXJOOTc8hnPMcHLc8zUwYN3lyc9QTQFOEu4pnhI/WJkq9KRMg4YXvj7CTIg7b4Z8 SdPui1yxXfrUZ9L+Tk2/rzNSsP9IzHf3hNbSjumD0hfo5Ci/69omEa+k7sL5iJu6 Rdc8yeL7MY4yl2ObbGzXT1kesvzUyR+NDz3u1XJGDUoyjLU/5BuLOeaGhcardijG 0YvJ8tcHitFe6kxpd1ZqY6XBjYcd4uqnQ8ILKeP5He1V+njdPcgPZqfUHUQkJ6ZI 65SmAZ0u4pVN/5+UUeKGXSLZv2q30pZiIraf2TK3YoJ/h6aZpi6dypx1usv6sBOa uVb9pqjcZkP2x7rGBh0vBA== 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 :references:reply-to:subject:subject:to:to:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1739738297; x= 1739824697; bh=fjMpY8Duf2l4m+G76eHnu/nmULmXHO5CYkxNnNDpZPA=; b=j ZTko0eyjdNSMKz3KmkYyQejJG8uBgkP+PeoK/KNLrkQUBVC1j/lb2u5n/TbAcV7q 2IdjoLhKZ7hiiiJJ7MFAf/Q0JumVq6Vr2g4gbwKTUsntQGITStQs6ELrYtIU1FMo K/y8jVkDbzfayavI4QlFOfnG9Ow5YQCoDBlgJdF3GSkktIFK02hHNW1FvPP/z0OG 8A+UKOrk6x7fVzhf9iUVJ0orrrVO/66Frx+VTI5kfrMVphM1BZDEP7sYjheQquPz a2g8KGqf+iRiNjLuEaBoGQAvkjlCcy6dd3nOqYD7WZVqxBJkcnUAnVxvNrsSv7ee LnH/7q9rd1tzRMGnfwunQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgdehieeghecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdp uffrtefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivg hnthhsucdlqddutddtmdenucfjughrpefkffggfgfuvfevfhfhjggtgfesthekredttddv jeenucfhrhhomheptegurhhirghnucfmlhgrvhgvrhcuoegrughrihgrnhdrkhhlrghvvg hrsegrkhhlrghvvghrrdgtohhmqeenucggtffrrghtthgvrhhnpeefgeefieeutdfggfet gefgheekjeehteeileeigfetieekjedvieeviefgheevtdenucevlhhushhtvghrufhiii gvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrughrihgrnhdrkhhlrghvvghrsegr khhlrghvvghrrdgtohhmpdhnsggprhgtphhtthhopeefpdhmohguvgepshhmthhpohhuth dprhgtphhtthhopehsuhgushdugeefgeesghhmrghilhdrtghomhdprhgtphhtthhopehg uhhilhhlrghumhgvrdhlvghlrghrghgvsegurghlihgsohdrtghomhdprhgtphhtthhope hpghhsqhhlqdhgvghnvghrrghlsehlihhsthhsrdhpohhsthhgrhgvshhqlhdrohhrgh X-ME-Proxy: Feedback-ID: i76984098:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 16 Feb 2025 15:38:16 -0500 (EST) Message-ID: <14e43d83-fce5-4ba9-84af-7bff78e99f20@aklaver.com> Date: Sun, 16 Feb 2025 12:38:15 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Question on Alerts To: sud , Guillaume Lelarge Cc: pgsql-general@lists.postgresql.org References: <54274170-49f7-4c88-8c23-431d50dd6a9f@dalibo.com> Content-Language: en-US From: Adrian Klaver In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2/16/25 12:31, sud wrote: > > On Sun, Feb 16, 2025 at 10:05 PM Guillaume Lelarge > > wrote: > > > You should probably look at check_postgres and check_pgactivity. Their > source code contain numerous SQL queries, that could help you write > your > own. > > Regards. > > > Thank you very much. I am a bit new to postgres here. Can you please > guide me , where exactly I can get the source code for  check_postgres > and check_pgactivity? The way you generally find this information, search on check_postgres and check_pgactivity. -- Adrian Klaver adrian.klaver@aklaver.com