2G limit is problem with launching script


#1

When directly setting the -Xmx size in Info.plist, the value is ignored and 2G is always used.

What I see from JConsole is the that in the VM arguments:
-Dfile.encoding=UTF-8 -Xmx4096m -Xms2048m -Dsun.java2d.noddraw=true -Dvp.launcher.version=13.1 -Xmx2048m -Djava.io.tmpdir=${installer:sys.appdataDir}/VisualParadigm/tmp -Dapple.awt.rendering=speed -Dapple.awt.graphics.UseQuartz=true -Dinstall4j.launcherId=5 -Dinstall4j.swt=false -Dexe4j.moduleName=/Applications/Visual Paradigm.app -Di4j.ownBundlePath=/Applications/Visual Paradigm.app -Di4j.jreBundle=/Applications/Visual Paradigm.app/Contents/Resources/jre.bundle

** NOTE ** That there is a first -Xmx4096 (my value) and the a SECOND with -Xmx2048 (culprit). The VM will pick up the last value so maybe this is why the 2G appears to be the limit. Whatever script produces this must be the problem.

I am on MAC OS X 10.12.2 with 128GB memory. I am using VP Pro v 14.2 build sp1_20171203


#2

Seems xmx can be modified in Info.plist
PS: I am not familiar with mac. :sweat_smile:

Just try to follow this knownow page, the section “For Mac OS X users”, to modify the Info.plist, change its -xmx to be 4096m:

Then start VP. And check in vp.log. It shows Memory: current=254M, max=3641M.
So, seems xmx can be modified in Info.plist
// since I don’t know how to check XMX in mac, so, I check it in vp.log (vp.log can be exported from About dialog. There is a button “Export Log File…”)


#3

Please read the bug report details. The VP launch script adds an extra -xmx value of 2048. This overrides anything the user does.
Please note that looking at the vp.log file possibly says what value it reads from the plist and NOT what the actual JavaVM launch is getting. How are you verifying what the VP launch script is doing? Are you saying that you don’t get the second xmx=2048 launch arg?
I verified that the JavaVM process (using JConsole to attach to the VM) is absolutely not getting the user specified XMX value. It can’t get the user specified value because the JVM launch command is overriding it.


#4

sorry, the “current=… , max=…” in vp.log comes from
java.lang.Runtime #maxMemory()
It should be the real value from JavaVM.

But we are checking why did JConsole show two xmx. Please wait…


#5

Good to know the vp.log is showing actual memory. Thanks!

Hopefully something shows up on why the JVM launch (I’m on MAC OS X) has the extra -xmx…


#6

Sorry, the About dialog will create the following file:
~/Library/Application Support/Visual Paradigm/vplauncher.vmoptions
which stores what xmx you selected from About dialog, and that value will be appended into launcher script when you start VP. So, finally, there will be 2 xmx shown in jconsole.

Since you have edited info.plist to be 4096m. I suggest you delete the above file to avoid 2 xmx.
(Sorry for asking you to delete it manually.)

Thanks for your post, we know that our knowhow page is outdated (to ask user to change xmx by info.plist). We should only suggest general users (including Mac users) to change it via About dialog.


#7

Deleted the vplauncher.vmoptions and verified the VM got the 4096M and it’s working.

Please note that this journey all started because the About->Utilities Max Memory was initially limited to 2G. There was no way in the UI to change it to a higher value.

With the vmoptions file gone, it seems my .plist value for the max memory of 4G is now showing in that dialog. Note I can select 4G or lower not higher.

I think this is still a bug VP needs to fix. An initial MAC OS X user like myself will be constrained to the initial max 2G value and no way to change it in the UI.

Thanks for help.

Best,
MrP


#8

Right, we will follow up the About > Utilities Max Memory in this post:

Thanks :wink: