- nebula 版本:2.0.0
- 部署方式 单机
- 是否为线上版本: N
- 问题的具体描述
关于磁盘资源占用计算问题。
create space shareholder(partition_num=10,replica_factor=3,vid_type=fixed_string(100));
create tag entity(name string, type int, has_valid_id bool);
create edge invest(shared_capital_percentage double, share_capital_percentage_fuzzy int, subscribed_capital double, subscribed_currency int);
以上是相关的space和tag的创建信息。
现在插入30万个点,20万条边
- vid 100byte
entity - name 平均15个中文,字节数为15*3=45
- type 8 byte
- has_valid_id 1byte
invest - shared_capital_percentage 8 byte
- share_capital_percentage_fuzzy 8 byte
- subscribed_capital 8 byte
- subscribed_currency 8 byte
首先是计算属性平均字节数:(100+45+8+1) * (3/5) + (8+8+8+8) * (2/5) = 92.4 + 12.8 = 105.2
计算磁盘空间大小: 500000 * 105.2 * 6 * 1.2 = 378720000 ~ 361M
计算结果大概是361M,但本地实际插入数据后通过 data目录所占磁盘空间差值算出增加了大概850M的磁盘空间,是我哪里算错了吗?为什么空间差距会这么多?