apache / incubator-hugegraph-toolchain

HugeGraph toolchain - include a series useful graph modules
https://hugegraph.apache.org/
Apache License 2.0
87 stars 91 forks source link

hugegraph-server下rest-server.properties设置了batch.max_edges_per_batch和restserver.min_free_memory后,代码依旧报顶点超过500和存储空间不足的错 #182

Closed lixuanhng closed 3 years ago

lixuanhng commented 3 years ago
  1. 报错内容为: Caused by: class javax.ws.rs.ServiceUnavailableException: The server available memory 61(MB) is below than threshold 64(MB) and can't process the request, you can config restserver.min_free_memory to adjust it or try again later 尝试解决的方法为: 在hugegraph-server下rest-server.properties的文件中添加参数restserver.min_free_memory,并指定其值为32。但是重新运行代码,还是报同样的错;

  2. 报错内容为: ERROR: More than 500 vertices insert error, stop parsing and waiting other insert tasks finished 尝试解决的方法为: 在hugegraph-server下rest-server.properties的文件中添加参数batch.max_edges_per_batch,并指定其值为100000。但是重新运行代码后,还是报同样的错;

在未修改的rest-server.properties中并没有这两个参数,这两个参数难道需要手动添加吗?

感谢解答!!

Linary commented 3 years ago

@lixuanhng 你的server是部署在什么机器上的,出现上述那个异常的时候说明内存非常吃紧了,调参数restserver.min_free_memory也只是治标不治本,你得换个配置好点的机器。 等你解决了第一个问题,第二个问题或许就不存在了,如果还存在。你可以调低loader的写入线程数,调小写入的batch的大小。

javeme commented 3 years ago

@lixuanhng 配置文件写出的配置项不全面,可以任意加入配置项的。具体配置项见文档:https://hugegraph.github.io/hugegraph-doc/config/config-option.html 。 内存不足建议调大最大内存,调整bin/hugegraph-server.sh中的XMX值即可。

lixuanhng commented 3 years ago

问题已经解决了,感谢两位大佬帮忙!