[英]Capacity Forecasting ( CPU/Memory/Disk)
Trying to forecast the above metrics for our postgres database servers. 尝试预测我们的postgres数据库服务器的上述指标。 We have nagios and cacti. 我们有nagios和仙人掌。 How have you done this? 你是怎么做到的?
Disk: 磁碟:
You can experiment with pg_column_size
to figure out how big a value (or a table row) will be on disk. 您可以尝试使用pg_column_size
来确定值(或表行)在磁盘上的大小。
There will be a lot of overhead: headers, empty space in disk blocks, and of course all the space for indexes you create. 会有很多开销:标头,磁盘块中的空白空间,当然还有创建索引的所有空间。 Estimate something between three and ten times the space got with pg_column_size
. 估计使用pg_column_size
获得的空间的三到十倍。
You will also have to reserve disk space for archived transaction logs (WAL). 您还必须保留磁盘空间用于归档的事务日志(WAL)。
Memory: 记忆:
As much as possible for a busy database. 对于繁忙的数据库,请尽可能。
CPU: 中央处理器:
As many cores as you expect concurrent queries. 与您期望的并发查询一样多的内核。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.