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 1l7i6R-0004B4-UY for pgsql-general@arkaria.postgresql.org; Thu, 04 Feb 2021 17:07: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 1l7i6Q-00028M-SQ for pgsql-general@arkaria.postgresql.org; Thu, 04 Feb 2021 17:07: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 1l7i6Q-00026W-L4 for pgsql-general@lists.postgresql.org; Thu, 04 Feb 2021 17:07:34 +0000 Received: from mail-ot1-x332.google.com ([2607:f8b0:4864:20::332]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1l7i6N-0000A0-BG for pgsql-general@lists.postgresql.org; Thu, 04 Feb 2021 17:07:34 +0000 Received: by mail-ot1-x332.google.com with SMTP id o12so4057578ote.12 for ; Thu, 04 Feb 2021 09:07:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-language; bh=DkgNNf8tjDbwa0/VrmYG9EhIwt191IDUE3icH0JVMfY=; b=p49nqtsw8pz1TzlfdKcBQq3TRHGqvidS2fbUYBNT0t01rFvqqp9mPoW1zUit1QR+mV imyAurSqNfYj45ElTCHeYVVluh9DQ6r62dwaTY7Xt0XZgnmmTCYc/1/L1Z4Lv3ifTQmV ZXfNCfBGvPnZtqYvDXwogugNMc0DWNB6ksiW4aq3meCKkLEJ2UUGtveZII4MRqo2PeEq jSyuqknS/mwGchuXiUkt8W9cKYutUmaFprnZWTDz+CS8EIWO8N5ZCfqF6xAr6y+oiZMQ 03ykid1ZlL25iKF4Kla5xXOY3QAHb1Gt82kyIEO/XsJc5eH3oy65VwORXMfNrT46uFWw +rKA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language; bh=DkgNNf8tjDbwa0/VrmYG9EhIwt191IDUE3icH0JVMfY=; b=a3f+DttvLB+KkZH76qAwC5hwXz6OYs65porFkLdWm3iqbYIKCRHXEi3yLlhwbH+R92 V3hyB0k5mLQPyJ2LYj1BH55Zbaq5Lwx4dcociEQrO2X1jJ4h9/4vSjVbRfDftCzYontQ ESY0yJIW9XsPsPaDfVwsz7PaXcK2rWZAayEdqD1hEKvZ0pnDKrXgFoWV7ybD4AxjWodL cGPnILu5MeH1a1B0A83gCBYSsmlUU+KQ08gBUQ/1FWsNDi2GUQM6/MrtCIjHeTAnhate a5Ex2YmfqB8HOGGCVVud7p5YwGZ6m4VRPkHUA8NJ1Pp4E+3H47SUmjLLVZxi8+sTFmg3 xUdw== X-Gm-Message-State: AOAM531dkPGdJMK/jEvp3UZT7z9TVd/0kTBRjBbGOiIEaeojTDV6vn7R Ee/oHHYA3KdTsA+BheElCnW5hkvsEyk= X-Google-Smtp-Source: ABdhPJzo9SfNy24Z1S7Ssc8ZubO5/7iSPjLpQnYucWL/4ZDeyD/ZbfSkEq1lPKo3d1F8MlhqJ3LeJQ== X-Received: by 2002:a05:6830:349a:: with SMTP id c26mr266588otu.112.1612458449171; Thu, 04 Feb 2021 09:07:29 -0800 (PST) Received: from [192.168.88.10] (ip174-67-141-204.no.no.cox.net. [174.67.141.204]) by smtp.googlemail.com with ESMTPSA id x187sm1233567oig.3.2021.02.04.09.07.27 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 04 Feb 2021 09:07:28 -0800 (PST) Subject: Re: vacuumdb not letting me connect to db To: pgsql-general@lists.postgresql.org References: From: Ron Message-ID: Date: Thu, 4 Feb 2021 11:07:27 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/alternative; boundary="------------54C295738CEE09942E30694F" Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk This is a multi-part message in MIME format. --------------54C295738CEE09942E30694F Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit What about disk IO?  That's what really gets saturated when running 300 threads. On 2/4/21 11:00 AM, Atul Kumar wrote: > Hi, > > The CPU and RAM are normal even on 300 jobs ( only 1-4% of consumption) > but I don’t understand one thing here that if max_connections is set to > 700 then why I am not able to connect the db. > > As the running jobs (300) are lesser than half of max_connections. > > > Regards > Atul > > > On Thursday, February 4, 2021, Laurenz Albe > wrote: > > On Thu, 2021-02-04 at 16:56 +0530, Atul Kumar wrote: > > I have 160 GB of RAM, postgres 9.6 is running on the server. > > > > after upgrade I ran the below command: > > > > "/usr/edb/as9.6/bin/vacuumdb" -U 'enterprisedb' --verbose --all -j 300 > > --analyze-only > > > > after running that  command I was not able to connect the database > > using psql for few minutes. > > That is to be expected. > > If you have 300 processes performing I/O and using CPU, your machine > will vertainly be overloaded. > > Yours, > Laurenz Albe > -- > Cybertec | https://www.cybertec-postgresql.com > > -- Angular momentum makes the world go 'round. --------------54C295738CEE09942E30694F Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 8bit What about disk IO?  That's what really gets saturated when running 300 threads.

On 2/4/21 11:00 AM, Atul Kumar wrote:
Hi,

The CPU and RAM are normal even on 300 jobs ( only 1-4% of consumption) but I don’t understand one thing here that if max_connections is set to 700 then why I am not able to connect the db.

As the running jobs (300) are lesser than half of max_connections.


Regards 
Atul


On Thursday, February 4, 2021, Laurenz Albe <laurenz.albe@cybertec.at> wrote:
On Thu, 2021-02-04 at 16:56 +0530, Atul Kumar wrote:
> I have 160 GB of RAM, postgres 9.6 is running on the server.
>
> after upgrade I ran the below command:
>
> "/usr/edb/as9.6/bin/vacuumdb" -U 'enterprisedb' --verbose --all -j 300
> --analyze-only
>
> after running that  command I was not able to connect the database
> using psql for few minutes.

That is to be expected.

If you have 300 processes performing I/O and using CPU, your machine
will vertainly be overloaded.

Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com


--
Angular momentum makes the world go 'round.
--------------54C295738CEE09942E30694F--