Toggle navigation
类型: integer
默认: 0
最低限度: 0
最大: 100
单元: milliseconds (ms)
上下文: user
重新开始: false

进程超过代价限制后将休眠的时间长度,以毫秒计。其默认值为0,这将禁用基于代价的清理延迟特性。正值将启用基于代价的清理。注意在很多系统上,实际的休眠延迟单位是10毫秒,将vacuum_cost_delay设置成不为10的倍数的值和将它设置为比该值大的10的倍数的效果相同。

在使用基于代价的清理时,vacuum_cost_delay的合适值通常很小,也许是10或20毫秒。调整清理时资源消耗最好的方法是调整其他清理代价参数。

建议 [EN]

Most of the time, you will want manual vacuum to execute without vacuum_delay, especially if you're using it as part of ETL. If for some reason you can't use autovacuum on an OLTP database, however, you may want to increase this to 20ms to decrease the impact vacuum has on currently running queries. Will cause vacuum to take up to twice as long to complete.

条评论