Re: PostgreSQL hot standby Hangs due to AccessExclusiveLock on pg_attribute or pg_type tables

From: Kyotaro HORIGUCHI <horiguchi(dot)kyotaro(at)lab(dot)ntt(dot)co(dot)jp>
To: bruno(dot)richard(at)broadsign(dot)com
Cc: jeff(dot)janes(at)gmail(dot)com, pgsql-bugs(at)postgresql(dot)org
Subject: Re: PostgreSQL hot standby Hangs due to AccessExclusiveLock on pg_attribute or pg_type tables
Date: 2017-07-13 04:19:23
Message-ID: 20170713.131923.147789413.horiguchi.kyotaro@lab.ntt.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

At Tue, 11 Jul 2017 16:48:11 -0400, Bruno Richard <bruno(dot)richard(at)broadsign(dot)com> wrote in <CAB-EU3St=O+FoXt-i8OkCp3A36Xft6TTOX6DO1okp=0Ub47n5w(at)mail(dot)gmail(dot)com>
> Thanks for the replies.
>
> Jeff, there were no long-lived transactions in pg_stat_activity while
> pg_attribute was locked. We were able to query it from another database on
> the same instance.
>
> I can't say if it would correct after 20 minutes since it causes us major
> issues in our application.
>
> Five days ago, we tried the hot_standy_feedback=on setting on one of our
> hot standbys and we don't get locks anymore. We even don't get locks from
> hot standbys not having the setting enabled.

That's because a feedback from a standby prevents vacuum on the
master from emitting WAL records
possiblly-conflicts-with-all-standbys at the time. So a low
chance to see the locks was still remaining.

> We will enable it on those later this week.

This can eliminate the remaining chance.

regards,

--
Kyotaro Horiguchi
NTT Open Source Software Center

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Kyotaro HORIGUCHI 2017-07-13 04:42:49 Re: BUG #14738: ALTER SERVER for foregin servers not working
Previous Message Kyotaro HORIGUCHI 2017-07-13 04:10:43 Re: PostgreSQL hot standby Hangs due to AccessExclusiveLock on pg_attribute or pg_type tables