Re: [PERFORM] 2 server with same configuration but huge difference in performance

From: Anthony Sotolongo <asotolongo(at)gmail(dot)com>
To: Keith <keith(at)keithf4(dot)com>, Sumeet Shukla <sumeet(dot)k(dot)shukla(at)gmail(dot)com>
Cc: pgsql-admin <pgsql-admin(at)postgresql(dot)org>, pgsql-performance(at)postgresql(dot)org
Subject: Re: [PERFORM] 2 server with same configuration but huge difference in performance
Date: 2017-08-01 14:21:02
Message-ID: 084c7a84-5035-10b7-80a0-f5c19968c485@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-performance

Hi Sumeet Shukla

While script is running check the pg_stat_activity, this view can be util

Regards

Anthony

On 01/08/17 10:16, Keith wrote:
>
> On Tue, Aug 1, 2017 at 9:41 AM, Sumeet Shukla
> <sumeet(dot)k(dot)shukla(at)gmail(dot)com <mailto:sumeet(dot)k(dot)shukla(at)gmail(dot)com>> wrote:
>
> Hi,
>
> I have 2 PG servers with same h/w and configuration and they are
> not in replication.
>
> On server A it takes 20 minutes to execute the script.
> On server B it takes more than 20 hours. (Seems to be stuck with
> create index and and create foreign key steps)
>
> Any guidance to troubleshoot this would be highly appreciated.
>
> Thanks & Regards,
> Sumeet Shukla
>
>
> Check for long running queries on the server that is taking longer. If
> it's things like CREATE INDEX or ALTER TABLE statements that are being
> blocked, a transaction running on the table involved will cause those
> commands to be held until those transactions complete.
>
> If it's normal read/write queries to that are taking longer, ensure
> the database statistics are up to date by running an analyze.
>
> Keith

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Thomas Poty 2017-08-01 14:53:53 phantom rights
Previous Message Keith 2017-08-01 14:16:04 Re: 2 server with same configuration but huge difference in performance

Browse pgsql-performance by date

  From Date Subject
Next Message Joshua D. Drake 2017-08-01 14:43:27 Re: How to access data of SQL server database from PostgreSQL
Previous Message Keith 2017-08-01 14:16:04 Re: 2 server with same configuration but huge difference in performance