官术网_书友最值得收藏!

  • Mastering PostgreSQL 10
  • Hans Jürgen Sch?nig
  • 113字
  • 2021-06-30 19:03:52

A word on VACUUM FULL

Instead of normal VACUUM, you can also use VACUUM FULL. However, I really want to point out that VACUUM FULL actually locks the table and rewrites the entire relation. In the case of a small table, this might not be an issue. However, if your tables are large, the table lock can really kill you in minutes! VACUUM FULL blocks upcoming writes and therefore some people talking to your database might have the feeling that it is actually down. Hence, a lot of caution is advised.

To get rid of VACUUM FULL, I recommend that you check out pg_squeeze (http://www.cybertec.at/introducing-pg_squeeze-a-postgresql-extension-to-auto-rebuild-bloated-tables/), which can rewrite a table without blocking writes.

主站蜘蛛池模板: 湛江市| 西宁市| 昭苏县| 宜兰县| 临猗县| 丹凤县| 贵港市| 沂水县| 榆林市| 宁德市| 威宁| 鹿邑县| 靖远县| 崇阳县| 黄骅市| 甘南县| 广汉市| 广平县| 偏关县| 平江县| 东丰县| 汾阳市| 宁海县| 万源市| 漳州市| 尤溪县| 漠河县| 南宁市| 商城县| 茂名市| 栖霞市| 永城市| 比如县| 都江堰市| 囊谦县| 阿拉善右旗| 营口市| 塔河县| 滨海县| 伊春市| 稷山县|