Re: reloption to prevent VACUUM from truncating empty pages at the end of relation
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
Cc: Robert Haas <robertmhaas@gmail.com>,
"Tsunakawa,
Takayuki" <tsunakawa.takay@jp.fujitsu.com>,
Alvaro Herrera <alvherre@2ndquadrant.com>,
Michael Paquier <michael@paquier.xyz>,
Julien Rouhaud <rjuju123@gmail.com>,
Laurenz Albe <laurenz.albe@cybertec.at>,
"Jamison,
Kirk" <k.jamison@jp.fujitsu.com>,
Amit Kapila <amit.kapila16@gmail.com>,
Fujii Masao <masao.fujii@gmail.com>,
pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2019-03-01T19:34:18Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Add TRUNCATE parameter to VACUUM.
- b84dbc8eb80b 12.0 landed
-
Add vacuum_truncate reloption.
- 119dcfad988d 12.0 landed
-
Allow VACUUM to be run with index cleanup disabled.
- a96c41feec6b 12.0 cited
Andrew Dunstan <andrew.dunstan@2ndquadrant.com> writes: > On 3/1/19 2:14 PM, Tom Lane wrote: >> Indeed, but I'm not sure that the use-cases are the same. In particular, >> unless somebody has done some rather impossible magic, it would be >> disastrous to apply DISABLE_INDEX_CLEANUP as a reloption, because then >> it would be persistent and you'd never get a real vacuum operation and >> soon your disk would be full. Permanently applying truncation disabling >> seems less insane. > You could allow an explicitly set command option to override the reloption. > It's important for us to be able to control the vacuum phases more. In > particular, the index cleanup phase can have significant system impact > but often doesn't need to be done immediately. I'm not objecting to having a manual command option to skip index cleanup (which basically reduces to "do nothing but tuple freezing", right? maybe it should be named/documented that way). Applying it as a reloption seems like a foot-gun, though. regards, tom lane