Re: Temporary tables versus wraparound... again

From: Greg Stark <stark(at)mit(dot)edu>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Justin Pryzby <pryzby(at)telsasoft(dot)com>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Noah Misch <noah(at)leadboat(dot)com>, Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Temporary tables versus wraparound... again
Date: 2023-04-18 15:09:44
Message-ID: CAM-w4HNyZYKDWjd9DSbiqwpmg-g8Lqv6VdGC3b3r9ivSYdFYgw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hm, in an optimized build using kernel perf I see this. But I don't
know how to find what the call sites are for LWLockAcquire/Release. If
it's the locks on pgproc that would be kind of bad.

I wonder if I should be gathering horizons once in the
PrecommitActions and then just using those for every temp table
somehow. Perhaps only actually doing an update if the relfrozenxid is
actually at least vacuum_freeze_table_age old.

3.98% postgres LWLockAcquire
3.51% postgres LWLockRelease
3.18% postgres hash_search_with_hash_value
2.20% postgres DropRelationLocalBuffers
1.80% [kernel] check_preemption_disabled
1.52% postgres hash_bytes
1.27% postgres LockAcquireExtended
0.97% postgres _bt_compare
0.95% [kernel] kmem_cache_alloc

I still think we should be applying the vacuum warning messages to
stable and probably backpatching. I've actually heard from other users
who have faced the same surprise wraparound shutdown.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2023-04-18 15:20:06 constants for tar header offsets
Previous Message Aleksander Alekseev 2023-04-18 14:27:48 Re: [PATCH] Compression dictionaries for JSONB