java.lang.​OutOfMemor​yError について

MATLAB R2016b (9.1.0.441655) 64-bit (glnxa64) is used to predict survey information.
About three days ago, the following error occurred, and it examined in various ways and it understood to the place where Java heap area was short.
ExceptionObject: [1×1 java.lang.OutOfMemoryError] identifier: 'MATLAB:Java:GenericException' message: 'Java exception occurred: ...' cause: {} stack: [3×1 struct]
I checked the setting method on the MATLAB side, but I understood how to set it from the management screen by GUI, but because of AWS the GUI can not be used and I do not know how to set it.
It is saved if someone can tell me how to set it from the command line.
In addition, I think whether the memory use situation of AWS has no problem. KiB Mem: 60614968 total, 56340112 free, 1448516 used
Thank you.

 Réponse acceptée

Kojiro Saito
Kojiro Saito le 14 Mar 2018

3 votes

You can change Java heap size by editing $prefdir/matlab.prf file.
By default in Linux MATLAB R2016b, $prefdir is would be /home/USER/.matlab/R2016b. If you want to increase Java heap size to 4,000MB, try the following.
vi /home/USER/.matlab/R2016b/matlab.prf
and add ( or change if JavaMemHeapMax is already existing)
JavaMemHeapMax=I4000
Then restart MATLAB, the Java heap size will be changed.

1 commentaire

turinavi
turinavi le 14 Mar 2018
Thank you very much. I will check it.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur 環境と設定 dans Centre d'aide et File Exchange

Produits

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!