RE: Vacuum Question - Mailing list pgsql-admin

From Murthy Nunna
Subject RE: Vacuum Question
Date
Msg-id SJ0PR09MB668856CA64315E24A67F49BBB812A@SJ0PR09MB6688.namprd09.prod.outlook.com
Whole thread Raw
In response to Re: Vacuum Question  (Ron Johnson <ronljohnsonjr@gmail.com>)
List pgsql-admin

 

 

From: Ron Johnson <ronljohnsonjr@gmail.com>
Sent: Monday, September 22, 2025 10:39 AM
To: pgsql-admin <pgsql-admin@postgresql.org>; Murthy Nunna <mnunna@fnal.gov>
Subject: Re: Vacuum Question

 

[EXTERNAL] – This message is from an external sender

I think you asked the same question 11 years ago. 😀

  • Seriously, though, 200GB is less than 1% of 22TB.  There are bigger problems if you're running that razor-thin on disk space.
    • I have 10 TB disk for WALs which is separate from /pgdata disk. But with the amount of WALs vacuum is generating, even 10 TB could fill up.
  • Is the transaction rate on the active tables sooo high that there's a real chance of wrap-around?
    • Given the xid numbers, I would say it is high. It went from 786089 to 965376038 in 12 months
  • According to my interpretation of the docs, if you VACUUM FREEZE the big static tables, then you won't need to vacuum them again, nor worry about wrap-around problems.
    • About a year ago, I did pgdump/restore. But I did not perform vacuum though. So, may be I should complete my table by table vacuum at least once then.

PostgreSQL reserves a special XID, FrozenTransactionId, which does not follow the normal XID comparison rules and is always considered older than every normal XID. Frozen row versions are treated as if the inserting XID were FrozenTransactionId, so that they will appear to be “in the past” to all normal transactions regardless of wraparound issues, and so such row versions will be valid until deleted, no matter how long that is.

 

pgsql-admin by date:

Previous
From: Ron Johnson
Date:
Subject: Re: Vacuum Question
Next
From: soumen rana
Date:
Subject: Anti virus scanning for Postgres database servers