Page 1 of 1

OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 1:39 am
by franmotta
Hello, I need to improve the memory usage of the program. What value you originally set to Xmx/Xms of the ExpertLotto? I'm using a Mac Pro with 32GB of memory, but the program is still returning the "OutOfMemory error". Where can I change the Xmx and Xms of the ExpertLotto to set a higher value?

THANKS,
Fran Motta

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 1:45 am
by franmotta
I need to configure the following items: XXMaxPermSize, -Xms, -Xmx

THANKS!

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 2:00 am
by motiram
Hello dearfranklin,

I do not now about much this error, below I have found a link you can try. If is it a same problem you are referring which is in the link below might can will help you.

http://expertlotto.com/en/forum/viewtop ... 13&p=16162

Regards,
Moti

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 2:02 am
by franmotta
Are the following information the limits [Minimum and Maximum] of memory usage by the program?

###################################################
Heap memory usage: initial 32,0MB maximum 123,9MB
Non heap memory usage: initial 23,2MB maximum 130,0MB
###################################################

Fran Motta

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 2:03 am
by franmotta
Thanks, Moti... I'll take a look!

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 2:15 am
by franmotta
I did as taught on the link and got the following error:

Error occurred during initialization of VM
Incompatible minimum and maximum heap sizes specified

Can anyone help me? THANKS!

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 2:23 am
by franmotta
Just fix it! I just added the following command "-Xmx1g" [no quotes] in the file "expertlotto.conf".

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 2:52 am
by franmotta
So to help users who may have the same problem in the future, I leave here a small tutorial:

NOTE: To change the Xmx value, you must have Java 64bit installed. It is also recommended to use a specific editor for programming language (I used TextWrangler - MacOSX), because a common text editor can generate an error in the original formation of the file "expertlotto.conf", which is essentially a Java file.

STEP BY STEP
1. Open the file expertlotto.conf using the "open with" (in this step, choose open with text editor);
2. On the line that appears -
"branding expertlotto-J-Xms32m" - change the Xms value to a Xmx value (never exceed 50% of your memory capacity). In my case, I changed "-J-Xms32m" to "-J-Xmx1g"
3. For me it worked like a charm!
4. The attached picture is just to show the line that needs to be edited.

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Wed Jul 17, 2013 9:31 pm
by stan
dearfranklin wrote:So to help users who may have the same problem in the future, I leave here a small tutorial:

NOTE: To change the Xmx value, you must have Java 64bit installed. It is also recommended to use a specific editor for programming language (I used TextWrangler - MacOSX), because a common text editor can generate an error in the original formation of the file "expertlotto.conf", which is essentially a Java file.

STEP BY STEP
1. Open the file expertlotto.conf using the "open with" (in this step, choose open with text editor);
2. On the line that appears -
"branding expertlotto-J-Xms32m" - change the Xms value to a Xmx value (never exceed 50% of your memory capacity). In my case, I changed "-J-Xms32m" to "-J-Xmx1g"
3. For me it worked like a charm!
4. The attached picture is just to show the line that needs to be edited.

Nice tutorial, thanks!
But you can leave the Xms option untouched. Just change/add -J-Xmx option to adjust the maximum available RAM.
And also keep in mind that you need 64 bit Java runtime if you want to allocate more than 800Mb of RAM for the application, otherwise the application may fail to start.

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Thu Jul 18, 2013 6:49 am
by franmotta
:D

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Sat Aug 23, 2014 12:05 pm
by nitho
I have about the same problem, although I have changed Xms32m to Xmx2g.

The application makes the statistical analysis (ticket analyzer, 76 latest draws of a 6/45 lotto) and then it gives me the results with a pop up "out of memory".
Is the statistical analysis ok or not ?
The same happens when I run a complex filter. The application filters the ticket package, it gives me the results with a pop up "out of memory".
Are the results ok or not?

I have 6GB RAM

Thanks in advance
Nitho

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Sun Aug 24, 2014 2:04 pm
by stan
nitho wrote:I have about the same problem, although I have changed Xms32m to Xmx2g.

The application makes the statistical analysis (ticket analyzer, 76 latest draws of a 6/45 lotto) and then it gives me the results with a pop up "out of memory".
Is the statistical analysis ok or not ?
The same happens when I run a complex filter. The application filters the ticket package, it gives me the results with a pop up "out of memory".
Are the results ok or not?

I have 6GB RAM

Thanks in advance
Nitho

Please email me your application log. Either you've adjusted your memory settings wrong or you are running some stats that just need a lot of RAM (for example when playing with many History levels).

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Mon Jun 06, 2016 4:51 am
by Numbers Theory
Hi Stan

I'm running EL 5.8 and have 4 GB RAM. I recently upgraded to Windows 10 and EL is now running very slowly when filtering only a few thousand (e.g. 60,000) tickets whereas previously the same filter would run much quicker. In the application log I got the following warning messages:

WARNING [org.netbeans.modules.openide.filesystems.declmime.MIMEResolverImpl]: Ineffective registration of resolver Services/MIMEResolver/ComplexFilterResolver.xml use @MIMEResolver.Registration! See bug #191777.

WARNING [org.netbeans.modules.openide.filesystems.declmime.MIMEResolverImpl]: Ineffective registration of resolver Services/MIMEResolver/CustomAnalyzerResolver.xml use @MIMEResolver.Registration! See bug #191777.


Also, here is another extract from the log showing the memory parameters:

Input arguments:
-Xms32m
-Dapple.laf.useScreenMenuBar=true
-Dsun.java2d.noddraw=true
-Duser.language.czech=sk
-Dnetbeans.logger.console=true
-Dsun.java2d.dpiaware=true
-Xmx409m
-XX:MaxPermSize=256m
-Dnetbeans.user.dir=C:\Program Files\Expert Lotto 5\bin
-Djdk.home=C:\Program Files\Java\jre7
-Dnetbeans.home=C:\Program Files\Expert Lotto 5\platform
-Dnetbeans.user=C:\Users\Alistair\AppData\Roaming\.expertlotto\release
-Dnetbeans.default_userdir_root=
-XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=C:\Users\Alistair\AppData\Roaming\.expertlotto\release\var\log\heapdump.hprof
-Dsun.awt.keepWorkingSetOnMinimize=true
-Dnetbeans.dirs=C:\Program Files\Expert Lotto 5\expertlotto
Compiler: HotSpot 64-Bit Tiered Compilers
Heap memory usage: initial 32.0MB maximum 364.5MB
Non heap memory usage: initial 23.4MB maximum 304.0MB

I have tried to increase the memory available to EL but I was unable to edit the config file using Windows Notepad - I got an 'Access denied' message.

Can you assist please?

Re: OutOfMemory Error - How to Set Xmx/Xms Values

PostPosted: Tue Jun 14, 2016 5:48 pm
by stan
Numbers Theory wrote:Hi Stan

I'm running EL 5.8 and have 4 GB RAM. I recently upgraded to Windows 10 and EL is now running very slowly when filtering only a few thousand (e.g. 60,000) tickets whereas previously the same filter would run much quicker. In the application log I got the following warning messages:

WARNING [org.netbeans.modules.openide.filesystems.declmime.MIMEResolverImpl]: Ineffective registration of resolver Services/MIMEResolver/ComplexFilterResolver.xml use @MIMEResolver.Registration! See bug #191777.

WARNING [org.netbeans.modules.openide.filesystems.declmime.MIMEResolverImpl]: Ineffective registration of resolver Services/MIMEResolver/CustomAnalyzerResolver.xml use @MIMEResolver.Registration! See bug #191777.


Also, here is another extract from the log showing the memory parameters:

Input arguments:
-Xms32m
-Dapple.laf.useScreenMenuBar=true
-Dsun.java2d.noddraw=true
-Duser.language.czech=sk
-Dnetbeans.logger.console=true
-Dsun.java2d.dpiaware=true
-Xmx409m
-XX:MaxPermSize=256m
-Dnetbeans.user.dir=C:\Program Files\Expert Lotto 5\bin
-Djdk.home=C:\Program Files\Java\jre7
-Dnetbeans.home=C:\Program Files\Expert Lotto 5\platform
-Dnetbeans.user=C:\Users\Alistair\AppData\Roaming\.expertlotto\release
-Dnetbeans.default_userdir_root=
-XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=C:\Users\Alistair\AppData\Roaming\.expertlotto\release\var\log\heapdump.hprof
-Dsun.awt.keepWorkingSetOnMinimize=true
-Dnetbeans.dirs=C:\Program Files\Expert Lotto 5\expertlotto
Compiler: HotSpot 64-Bit Tiered Compilers
Heap memory usage: initial 32.0MB maximum 364.5MB
Non heap memory usage: initial 23.4MB maximum 304.0MB

I have tried to increase the memory available to EL but I was unable to edit the config file using Windows Notepad - I got an 'Access denied' message.

Can you assist please?

The slow processing could be related to antivirus scanning - Expert Lotto does a lot of I/O operation during filtering so your antivirus might a bit too aggressive.
To edit the config file you need to open Notepad as administrator to get appropriate privileges - right-click the Notepad icon in Start menu and choose 'Run as administrator'