暂无图片
暂无图片
暂无图片
暂无图片
暂无图片

PostgreSQL 15 preview - pgbench copy freeze 加速tpc-b测试数据生成

原创 digoal 2022-01-20
290

作者

digoal

日期

2021-09-02

标签

PostgreSQL , freeze , copy , pgbench


https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=06ba4a63b85e5aa47b325c3235c16c05a0b58b96

Use COPY FREEZE in pgbench for faster benchmark table population.  
author  Tatsuo Ishii <ishii@postgresql.org>   
Thu, 2 Sep 2021 01:39:09 +0000 (10:39 +0900)  
committer   Tatsuo Ishii <ishii@postgresql.org>   
Thu, 2 Sep 2021 01:39:09 +0000 (10:39 +0900)  
commit  06ba4a63b85e5aa47b325c3235c16c05a0b58b96  
tree    6314f1e5ebbf3424b10fab49e5923972dfe1b40a    tree  
parent  469150a240dd79acbe7d86cb5df869d95f4d6d2d    commit | diff  
Use COPY FREEZE in pgbench for faster benchmark table population.  
While populating the pgbench_accounts table, plain COPY was  
unconditionally used. By changing it to COPY FREEZE, the time for  
VACUUM is significantly reduced, thus the total time of "pgbench -i"  
is also reduced. This only happens if pgbench runs against PostgreSQL  
14 or later because COPY FREEZE in previous versions of PostgreSQL does  
not bring the benefit. Also if partitioning is used, COPY FREEZE  
cannot be used. In this case plain COPY will be used too.  
Author: Tatsuo Ishii  
Discussion: https://postgr.es/m/20210308.143907.2014279678657453983.t-ishii@gmail.com  
Reviewed-by: Fabien COELHO, Laurenz Albe, Peter Geoghegan, Dean Rasheed  
复制

PostgreSQL 许愿链接

您的愿望将传达给PG kernel hacker、数据库厂商等, 帮助提高数据库产品质量和功能, 说不定下一个PG版本就有您提出的功能点. 针对非常好的提议,奖励限量版PG文化衫、纪念品、贴纸、PG热门书籍等,奖品丰富,快来许愿。开不开森.

9.9元购买3个月阿里云RDS PostgreSQL实例

PostgreSQL 解决方案集合

德哥 / digoal's github - 公益是一辈子的事.

digoal's wechat

「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论