Hi. I have an issue where the Atlassian installer eats memory until it crashes. "top" shows it spiking at 15GB virtual memory usage just before the crash. The install4j log is empty.
Is there any way of controlling the amount of memory used by the installer?
- Ubuntu 16.04 x64
- 4GB RAM
- 4GB Swap
- OpenJDK 8
Error
root@bitbucket-01:/$ /tmp/atlassian-bitbucket-4.10.1-x64.bin -q -varfile /tmp/varfile
Starting Installer ...
The target home directory is not empty.
The installation directory has been set to /opt/atlassian/bitbucket/4.10.1.
An error occurred:
java.lang.OutOfMemoryError: unable to create new native thread
Error log: /tmp/install4jError7730425451491793188.log
java.lang.OutOfMemoryError: unable to create new native thread
java.lang.Thread.start0(Native Method)
java.lang.Thread.start(Thread.java:714)
com.atlassian.bitbucket.installer.Tracker.track(Tracker.java:37)
com.install4j.script.I4jScript_Internal_59.eval(I4jScript_Internal_59.java:20)
com.install4j.script.I4jScript_Internal_59.evaluate(I4jScript_Internal_59.java:24)
com.install4j.runtime.installer.helper.Script.evaluate(Script.java:29)
com.install4j.runtime.installer.ContextImpl.runScript(ContextImpl.java:181)
com.install4j.runtime.installer.ContextImpl.runScript(ContextImpl.java:176)
com.install4j.runtime.installer.ContextImpl.runBooleanScript(ContextImpl.java:49)
com.install4j.runtime.installer.ContextImpl.runBooleanScript(ContextImpl.java:210)
com.install4j.runtime.installer.frontend.headless.UnattendedScreenExecutor.handleScreen(UnattendedScreenExecutor.java:99)
com.install4j.runtime.installer.frontend.headless.AbstractHeadlessScreenExecutor.execute(AbstractHeadlessScreenExecutor.java:81)
com.install4j.runtime.installer.controller.Controller$1.run(Controller.java:133)
java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
java.awt.EventQueue.dispatchEventImpl(EventQueue.java:756)
java.awt.EventQueue.access$500(EventQueue.java:97)
java.awt.EventQueue$3.run(EventQueue.java:709)
java.awt.EventQueue$3.run(EventQueue.java:703)
java.security.AccessController.doPrivileged(Native Method)
java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76)
java.awt.EventQueue.dispatchEvent(EventQueue.java:726)
java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
Varfile
app.install.service$Boolean=true
portChoice=custom
httpPort=7990
serverPort=8006
app.bitbucketHome=/bitbucket
app.defaultInstallDir=/opt/atlassian/bitbucket/4.10.1
Log
[INFO] com.install4j.runtime.beans.actions.control.RunScriptAction [ID 81761]: Execute action
Property rollbackScript: null
Property rollbackSupported: false
Property script: com.install4j.script.I4jScript_Internal_61
[ERROR] com.install4j.runtime.beans.actions.control.RunScriptAction [ID 81761]: Execute action not successful after 0 ms
[INFO] com.install4j.runtime.beans.screens.FormScreen [ID 54715]: command: go back 0 screens
Show screen
Variable changed: app.install.service=true[class java.lang.Boolean]
Sending pingback for event installer-install-service
[INFO] com.install4j.runtime.beans.actions.control.RunScriptAction [ID 81761]: Execute action
Property rollbackScript: null
Property rollbackSupported: false
Property script: com.install4j.script.I4jScript_Internal_61
[ERROR] com.install4j.runtime.beans.actions.control.RunScriptAction [ID 81761]: Execute action not successful after 0 ms
... repeat over and over and over again until the log is 8 GB!
Install4j is executed with -Dinstall4j.executionMode=gui even though -q is used
$ ps -ef | grep java
root 31985 31912 99 14:32 pts/1 00:00:07 /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java -Dinstall4j.jvmDir=/usr/lib/jvm/java-8-openjdk-amd64/jre -Dexe4j.moduleName=/tmp/atlassian-bitbucket-4.10.1-x64.bin -Dexe4j.totalDataLength=267859283 -Dinstall4j.cwd=/home/root -Djava.ext.dirs=/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/ext:/usr/lib/jvm/java-8-openjdk-amd64/jre/jre/lib/ext -Dinstall4j.executionMode=gui -Dsun.java2d.noddraw=true -Di4jv=0 -Di4jv=0 -Di4jv=0 -Di4jv=0 -Di4jv=0 -Di4j.vpt=true -classpath i4jruntime.jar:user.jar:user/bitbucket-installer.jar com.install4j.runtime.launcher.UnixLauncher launch 0 com.install4j.runtime.installer.Installer -q -varfile /tmp/varfile