jvm-arguments

How to give Jenkins more heap space when it´s started as a service under Windows?

谁说胖子不能爱 提交于 2019-11-26 15:51:34
I want to increase the available heap space for Jenkins. But as it is installed as a service I don´t know how to do it. In your Jenkins installation directory there is a jenkins.xml, where you can set various options. Add the parameter -Xmx with the size you want to the arguments-tag (or increase the size if its already there). If you used Aptitude (apt-get) to install Jenkins on Ubuntu 12.04, uncomment the JAVA_ARGS line in the top few lines of /etc/default/jenkins : # arguments to pass to java #JAVA_ARGS="-Xmx256m" # <--default value JAVA_ARGS="-Xmx2048m" #JAVA_ARGS="-Djava.net

Debug a java application without starting the JVM with debug arguments

≯℡__Kan透↙ 提交于 2019-11-26 15:01:13
Normally to attach a debuger to a running jvm you would need start the jvm with arguments such as the following: > java -Xdebug -Xrunjdwp:transport=dt_socket,address=1000,server=y,suspend=n Now if I want to debug a process that wasn't started in debug mode, what can I do? This situation arrises when a production system (i.e. started without debug args) exhibits a 'random' (I use the term loosely) bug. So I can't restart the jvm with the appropriate arguments, because nobody knows how to reproduce the bug again. Is it impossible to attach to the JVM in this situation? Just to clarify it is not

How to increase IDE memory limit in IntelliJ IDEA on Mac?

倖福魔咒の 提交于 2019-11-26 13:52:42
I'm using IDEA 12 Leda on Mountain Lion. I wanted to increase the maximum memory that IDE can use. I set the VMOptions in Info.plist file to be -Xmx2048m -ea -XX:+HeapDumpOnOutOfMemoryError -Xverify:none -Xbootclasspath/a:../lib/boot.jar When I open up IDEA, I still see the maximum memory to be 711m. jps -v shows my VMOptions has been loaded but it's replaced by the following options. 29388 **-Xmx2048m** -ea -XX:+HeapDumpOnOutOfMemoryError -Xverify:none -Xbootclasspath/a:../lib/boot.jar -Xms128m **-Xmx800m** -XX:MaxPermSize=350m -XX:ReservedCodeCacheSize=64m -XX:+UseCodeCacheFlushing -XX:

increase the java heap size permanently?

末鹿安然 提交于 2019-11-26 12:13:25
Is there a way that I can set the default heap size for the jvm on my own computer? I want to set it to 1g, because I'm always running custom programs that always hit the overage point in the default jvm size. I just dont want to have to remember to type -XmX1g everytime I run my java app from the command line... There has to be an admin way to do this right? Apparently, _JAVA_OPTIONS works on Linux, too: $ export _JAVA_OPTIONS="-Xmx1g" $ java -jar jconsole.jar & Picked up _JAVA_OPTIONS: -Xmx1g For Windows users, you can add a system environment variable named _JAVA_OPTIONS, and set the heap

Difference between _JAVA_OPTIONS JAVA_TOOL_OPTIONS and JAVA_OPTS

二次信任 提交于 2019-11-26 11:34:36
I thought it would be great to have a comparison between _JAVA_OPTIONS and JAVA_TOOL_OPTIONS . I have been searching a bit for one, but I cannot find anything, so I hope we can find the knowledge here on Stackoverflow. JAVA_OPTS is included for completeness. It is not part of the JVM, but there is a lot of questions about it out in the wild. What I know: So far I have found out that: JAVA_OPTS is not used by the JDK, but by a bunch of other apps (see this post ). JAVA_TOOL_OPTIONS and _JAVA_OPTIONS are ways to specify JVM arguments as an environment variable instead of command line parameters.

How to set -Dorg.apache.el.parser.COERCE_TO_ZERO=false programmatically

ⅰ亾dé卋堺 提交于 2019-11-26 10:35:48
问题 This question is similar to: jsf: integer property binded to a inputtext in UI is set to zero on submit but I am not completely satisfied with the solution. The contexts is the same: I have a web form requiring an Integer value. If the textbox is left empty, I want my Integer field to be \'null\' but instead the EL Parser automatically sets my id field to \'0\'. I can fix the problem by setting a JVM Parameter in my local Tomcat VM: -Dorg.apache.el.parser.COERCE_TO_ZERO=false However, this

Running java with JAVA_OPTS env variable has no effect

孤者浪人 提交于 2019-11-26 10:30:39
问题 In a shell script, I have set the JAVA_OPTS environment variable (to enable remote debugging and increase memory), and then I execute the jar file as follows: export JAVA_OPTS=\"-Xdebug -Xrunjdwp:transport=dt_socket,address=8001,server=y,suspend=n -Xms512m -Xmx512m\" java -jar analyse.jar $* But it seems there is no effect of the JAVA_OPTS env variable as I cannot connect to remote-debugging and I see no change in memory for the JVM. What could be the problem? PS: I cannot use those settings

What does JVM flag CMSClassUnloadingEnabled actually do?

偶尔善良 提交于 2019-11-26 09:53:10
I cannot for the life of me find a definition of what the Java VM flag CMSClassUnloadingEnabled actually does, other than some very fuzzy high-level definitions such as "gets rid of your PermGen problems" ( which it doesn't , btw). I have looked on Sun's/Oracle's site, and even the options list doesn't actually say what it does. Based upon the name of the flag, I'm guessing that the CMS Garbage Collector doesn't by default unload classes, and this flag turns it on - but I can't be sure. Update This answer is relevant for Java 5-7, Java 8 has this fixed: https://blogs.oracle.com/poonam/about-g1

Java Exceptions counter on JVM HotSpot

旧巷老猫 提交于 2019-11-26 08:23:26
问题 I am wondering is it possible to log every exception which occurs on JVM level without changing application code? By every exception I mean caught and uncaught exception... I would like to analyze those logs later and group them by exception type (class) and simply count exceptions by type. I am using HotSpot ;) Maybe there is smarter why of doing it? For example by any free profiler (YourKit has it but it is not free)? I think that JRockit has exception counter in management console, but don

CMSPermGenSweepingEnabled vs CMSClassUnloadingEnabled

一个人想着一个人 提交于 2019-11-26 07:56:34
问题 I\'ve kind of asked this question before - What does JVM flag CMSClassUnloadingEnabled actually do?, but this time it\'s slightly different! If I start a Java VM with the -XX:+CMSPermGenSweepingEnabled flag set, the following message is printed: Please use CMSClassUnloadingEnabled in place of CMSPermGenSweepingEnabled in the future The -XX:+CMSPermGenSweepingEnabled flag is often used to mitigate against PermGen OutOfMemory errors, however I have read elsewhere that people have found that by