JVM Out Of Memory Error


#1

Hi,

We are using Orient for a little more than 3 years and it has been a blast.

But recently we have the following error occuring more and more frequently.

com.orientechnologies.orient.core.exception.OJVMErrorException: JVM error ‘OutOfMemoryError : Java heap space’ occurred during data processing, storage is switched to ‘read-only’ mode.

Forcing us to stop and restart the service about once a day.

We did not find in the documentation how to increase the allocated memory.

Does anyone have this problem and / or know what is the correct solution ?

We are currently running orient 2.2.30 community.

Thanks in advance.


#2

Hi,

OrientDB v 2.2 uses heap memory intensively for query result sets, so in some cases you may want to increase the heap size, changing the -Xmx parameter in the server.sh (or .bat) file.
FYI, in v 3.0 this problem is much less significant, as query result sets are streamed and much more efficient in terms of memory usage

Thanks

Luigi


#3

Hi Luigi,

Thanks a lot for the quick reply.

We want to upgrade to the latest version v3.0.X (protocol level 37) but the connection workflow has changed and we did not find how to implement the necessary changes in the documentation (cannot connect directly to the database, handshake needed).

We created 2 years ago an ORM to work with laravel and orientdb which and used a fork PHPOrient (https://github.com/Ostico/PhpOrient) , however PHPOrient is still on protocol version 36 and has not been updated.

Is there any ressources and documentation available to implement the new workflow, or maybe do you advise to use another library than PHPOrient for the 3.0.X ?

Thanks in advance.

Regards,