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 1nuN1w-0004BM-An for pgsql-performance@arkaria.postgresql.org; Thu, 26 May 2022 23:36:36 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nuN0w-0002wo-R0 for pgsql-performance@arkaria.postgresql.org; Thu, 26 May 2022 23:35:34 +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 1nuN0w-0002we-Cm for pgsql-performance@lists.postgresql.org; Thu, 26 May 2022 23:35:34 +0000 Received: from mail-io1-xd2a.google.com ([2607:f8b0:4864:20::d2a]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1nuN0t-0004Pi-Ks for pgsql-performance@lists.postgresql.org; Thu, 26 May 2022 23:35:33 +0000 Received: by mail-io1-xd2a.google.com with SMTP id s23so3120543iog.13 for ; Thu, 26 May 2022 16:35:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=RnZNCNBa/jiC9qDUrmaUrrNiJbzhGnZ2RHy8BfsV3ww=; b=W0mqWB8v+anxnTr7IcuoxCUDkY05kSrYYK6JDzIVqPEWeN6UY96bw10I6JdPAyrKVU hsGcxfRjqA8Lv0blEQoq3h9rK1VeVX32xTs5k19ixT2R+6xj2W89/CVU0Nq6UHWcyn4+ su3Y9IjIR445ce1HQHw0dOwPIFwL1r3xIsVWu+VkqD2eiYgX0E6geCrhcY5MJOJQHyTR x7jICbd4DjbWtylbUvS5l40hfwO4QiMDmdQb5A4jMtFV0+ZLzF6J+ZGZC/3Dts8894cM t26uS1y0FXmJyMpQZ2xqAUuWmyaLR0dvLJsqhxCqKDIGJTKt9lbeUN/jsmn3sFhTLD4H z1vw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=RnZNCNBa/jiC9qDUrmaUrrNiJbzhGnZ2RHy8BfsV3ww=; b=7kWpfJwQ/vB6BjVm8Ze9sBK6tfj43aK3XYCXz6a1/k1d64z/NUAk+iXe/DVtC0fEuB Gus6oJZ0QVs5EWUmP4fjDCZ2UDGH1ZyGDhwAFck1Qy+0WXzN4HFOjJxVNswQH0odLW7T ZwLcsFEKyz6l8EincmeyuSbCKd80Fzn5VJV8eRv5bAFa84OdUtg+hNZvkkleyKSFq+uQ 9NaREs671A/B7zY74VZpwHqkUj2fcVbI+3U8NHfLb9cjKwqahp7XAyYUQgqH8i7Udzqo EWrp7m28lLnBVC4Z8r6Wbq45YQ8jOAAMT/zjWowJlaHgK/nZMSNkIAm/JgNdBWVGkQ9N uEBw== X-Gm-Message-State: AOAM5303DJwZZJe5qB0N3Ri2fqpx7RyeJRG5SZhlXC1yA3Q+BZN2NAsv C5Esqv2Wg5JeqM6ctG5RP7YiDA== X-Google-Smtp-Source: ABdhPJwfNJtPtCgHuvrEAAyFQEWndljR0bglSAQP3Jx4lJkM+a762bWfN8XbX1uzUy91pSJjaH3yJQ== X-Received: by 2002:a05:6638:371e:b0:32e:eefb:f7c5 with SMTP id k30-20020a056638371e00b0032eeefbf7c5mr7731804jav.255.1653608129811; Thu, 26 May 2022 16:35:29 -0700 (PDT) Received: from pryzbyj.telsasoft (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id n7-20020a056e02140700b002cde6e352d9sm871105ilo.35.2022.05.26.16.35.29 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 26 May 2022 16:35:29 -0700 (PDT) Received: by pryzbyj.telsasoft (Postfix, from userid 1000) id 45601800BC8; Thu, 26 May 2022 18:35:28 -0500 (CDT) Date: Thu, 26 May 2022 18:35:28 -0500 From: Justin Pryzby To: =?utf-8?B?5b6Q5b+X5a6H5b6Q?= Cc: pgsql-performance@lists.postgresql.org Subject: Re: How to monitor Postgres real memory usage Message-ID: <20220526233528.GD19626@telsasoft.com> References: <20220524174050.GI19626@telsasoft.com> <20220526160519.GB19626@telsasoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Fri, May 27, 2022 at 01:39:15AM +0800, 徐志宇徐 wrote: > Hi Justin > > Thanks for you explaination. > > > > What postgres version ? > > > How was it installed ? From souce? From a package ? > I am using Postgres 11.1 .It's installed by package. This is quite old, and missing ~4 years of bugfixes. What's the output of these commands? tail /proc/sys/vm/overcommit_* tail /proc/sys/vm/nr_*hugepages /proc/cmdline cat /proc/meminfo uname -a -- Justin