Forums / General / eZFind Java eating a lot of memory

eZFind Java eating a lot of memory

Author Message

Jacobi Jacobi

Thursday 24 June 2010 5:25:13 am

Hello,

I found two Java jobs in back end eating a lot of memory which make the system very slow, they should be related to ez Find:

1) /bin/bash -c ulimit -S -c 0 >/dev/null 2>&1 ; nohup /usr/bin/java -jar start.jar
2) /usr/bin/java -jar start.jar
 

Any idea what are the purpose of these two Java jobs in back end?

Can I kill them or restart them?

Is there any way to check if this is caused by DB error or Lock error? 

Gaetano Giunta

Thursday 24 June 2010 7:24:57 am

This is the solr indexing engine - used by ezfind. It is normal that it uses quite a lot of memory (and cpu too).

If you stop it, search will not work on your site - unless you deactivate ezfind too.

ps: it is one job, not two - one is the shell launching the other one.

Principal Consultant International Business
Member of the Community Project Board

Ali Nebi

Friday 25 June 2010 5:39:24 am

Hi,

we experienced such problems long time ago. In our analysis we found several things to make solr job faster and less resources consuming.

First of all we needed to set the following parameters in init script when we start solr:

-Dezfind -server -Xms150m -Xmx150m -XX:+UseParallelGC -XX:+AggressiveOpts -XX:NewRatio=5

If your server is 64bits and java version supports 64bits, then you should set above: -server -d64

Usually the problem with memory usage and solr failing is related with java garbage collector and its resources usage.

The other thing i tuned is solrconfig.xml file. There are several section to tune:

- mergeFactor
- ramBufferSizeMB
- maxFieldLength
You can take a look in solr official site for more info how to tune those values and how they affect resources usage and indexing speed.

The other very very important, maybe most important thing that we found was that solr was looping when it was trying to index object relation attributes. It was going in loop and was keeping solr and java to use much more resources than usual.

It is necessary to disable indexing for object relation attributes or to limit indexing level so solr cannot go in loop.

We also have experienced problems when $useFork variable was different then 'false'. When we was runing indexing this way, then java process was stopping to work after some time and wasn't complete its job.

So we continue to use useFork='false' for now.

I hope this will help you to solve your problems.

Best regards, Ali Nebi!

Iguana Information Technologies, SL - http://www.iguanait.com

Gaetano Giunta

Thursday 28 July 2011 11:30:08 pm

Note: according to the solr wiki (http://lucene.apache.org/solr/ ), using -XX:+AggressiveOpts is dangerous with a version 6 jre

Principal Consultant International Business
Member of the Community Project Board

Ali Nebi

Friday 29 July 2011 1:27:50 am

Hi, Gaetano.

Thanks for the note. I didn't know that until know. I will keep this in mind and follow the threads for this.

Iguana Information Technologies, SL - http://www.iguanait.com

eZ debug

Timing: Jan 17 2025 20:55:14
Script start
Timing: Jan 17 2025 20:55:14
Module start 'content'
Timing: Jan 17 2025 20:55:15
Module end 'content'
Timing: Jan 17 2025 20:55:15
Script end

Main resources:

Total runtime1.2893 sec
Peak memory usage4,096.0000 KB
Database Queries202

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0075 596.0469180.8359
Module start 'content' 0.00751.1139 776.8828642.2500
Module end 'content' 1.12140.1679 1,419.1328337.6094
Script end 1.2893  1,756.7422 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00390.3018210.0002
Check MTime0.00140.1086210.0001
Mysql Total
Database connection0.00080.061310.0008
Mysqli_queries1.208193.69902020.0060
Looping result0.00180.13892000.0000
Template Total1.249896.920.6249
Template load0.00190.145020.0009
Template processing1.247996.788820.6240
Template load and register function0.00020.015010.0002
states
state_id_array0.00110.089010.0011
state_identifier_array0.00120.092620.0006
Override
Cache load0.00160.1230420.0000
Sytem overhead
Fetch class attribute can translate value0.00150.118440.0004
Fetch class attribute name0.00110.087570.0002
XML
Image XML parsing0.00250.196340.0006
class_abstraction
Instantiating content class attribute0.00000.001390.0000
General
dbfile0.00460.3604330.0001
String conversion0.00000.000530.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
5content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
7content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
4content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 20
 Number of unique templates used: 6

Time used to render debug report: 0.0002 secs