incubator-hugegraph icon indicating copy to clipboard operation
incubator-hugegraph copied to clipboard

hugegraph-server 用restapi查询了多次之后,内存占用就降不下来

Open fisherinbox opened this issue 8 years ago • 4 comments

Expected behavior 期望表现

希望内存占用能够在不用的时候下降

Actual behavior 实际表现

比如刚启动hugegraph-server的时候内存占用3G,使用多次restapi查询之后,内存会到10g,而且不会下降,求问怎么解决

Steps to reproduce the problem 复现步骤

  1. {step 1}
  2. {step 2}
  3. {step 3}

Status of loaded data 数据状态

Vertex/Edge summary 数据量

  • loaded vertices amount: {like 10 million}
  • loaded edges amount: {like 20 million}
  • loaded time: {like 200s}

Vertex/Edge example 数据示例

{type something here...}

Schema(VertexLabel, EdgeLabel, IndexLabel) 元数据结构

{type something here...}

Specifications of environment 环境信息

  • hugegraph version: {like v0.7.4}
  • operating system: {like centos 7.4, 32 CPUs, 64G RAM}
  • hugegraph backend: {like cassandra 3.10, cluster with 20 nodes, 3 x 1TB HDD disk each node}

fisherinbox avatar Sep 26 '18 02:09 fisherinbox

@fisherinbox hi,内存无法降下来有几点原因:

  1. 缓存占用
  2. JVM未把空闲内存还给操作系统
  3. 内存泄露

可以提供更详细的信息进行分析,比如访问restapi的内容?默认缓存超时时间10分钟之后是否释放?

javeme avatar Sep 28 '18 10:09 javeme

@fisherinbox hi,内存无法降下来有几点原因:

  1. 缓存占用
  2. JVM未把空闲内存还给操作系统
  3. 内存泄露

可以提供更详细的信息进行分析,比如访问restapi的内容?默认缓存超时时间10分钟之后是否释放? restapi 访问的内容就是kneighbor,kout,10分钟之后还是不会降下来,很长时间都不会,另外默认10分钟是在哪里设置的?

fisherinbox avatar Sep 28 '18 10:09 fisherinbox

好的,kneighbor/kout返回数据是多少?数据库中总共数据多少条?

缓存超时配置项:graph.cache_expire,请参考文档:hugegraph.properties

javeme avatar Sep 28 '18 11:09 javeme

@Linary 对于JVM未把空闲内存还给操作系统,看看是否有必要默认设置MaxHeapFreeRatio一个值?

javeme avatar Jan 06 '20 16:01 javeme