Apparently table locks are the key issue to see red flags

Started by Shaozhong SHIabout 4 years ago6 messagesgeneral
Jump to latest
#1Shaozhong SHI
shishaozhong@gmail.com

Apparently table locks are the key issue to see red flags.

As we observe, every time, red marking occurs, there must be some tables
are locked.

Can anyone shed light into this?

Regards,

David

#2Shaozhong SHI
shishaozhong@gmail.com
In reply to: Shaozhong SHI (#1)

Apparently table locks are the key issue to see red flags.

As we observe, every time, red marking occurs, there must be some tables
are locked.

Can anyone shed light into this?

Regards,

David

#3Ron
ronljohnsonjr@gmail.com
In reply to: Shaozhong SHI (#2)
Re: Apparently table locks are the key issue to see red flags

On 3/16/22 15:15, Shaozhong SHI wrote:

Apparently table locks are the key issue to see red flags.

As we observe, every time, red marking occurs, there must be some tables
are locked.

Where do these red markings occur?  (It is physically impossible for them to
occur in Postgresql because Postgresql is a daemon, and therefore does not
have a GUI.)

--
Angular momentum makes the world go 'round.

#4Adrian Klaver
adrian.klaver@aklaver.com
In reply to: Shaozhong SHI (#2)
Re: Apparently table locks are the key issue to see red flags

On 3/16/22 13:15, Shaozhong SHI wrote:

Apparently table locks are the key issue to see red flags.

As we observe, every time, red marking occurs, there must be some tables
are locked.

Can anyone shed light into this?

Not with the information provided.

Needed info(and you should know this by now):

1) Postgres version

2) Definition of red flags?

3) How do you observe the tables locked?

4) The results of the process you use in 3)

Regards,

David

--
Adrian Klaver
adrian.klaver@aklaver.com

#5Shaozhong SHI
shishaozhong@gmail.com
In reply to: Shaozhong SHI (#1)

Apparently table locks are the key issue to see red flags.

As we observe, every time, red marking occurs, there must be some tables
are locked.

Can anyone shed light into this?

Regards,

David

#6Jayson Hreczuck
jayson.hreczuck@studentuniverse.com
In reply to: Shaozhong SHI (#5)
Re: Apparently table locks are the key issue to see red flags

Need more detail on this. Locks are generally caused by long updates or
writes or perhaps a hung transaction. Can you reply with a bit more detail
of what you are seeing, perhaps pg_stat_activity list?

Rule of thumb for high trx environments is to batch updates especially for
larger tables to avoid excessive locking.

On Wed, Mar 16, 2022 at 4:32 PM Shaozhong SHI <shishaozhong@gmail.com>
wrote:

Apparently table locks are the key issue to see red flags.

As we observe, every time, red marking occurs, there must be some tables
are locked.

Can anyone shed light into this?

Regards,

David

--

*Jayson Hreczuck | Principal Database AdministratorC: +1 617.571.9861*130
Turner St, Ste 530, Waltham, MA 02453