Skip to content

Instantly share code, notes, and snippets.

@chriskief
Last active December 28, 2015 13:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chriskief/7509548 to your computer and use it in GitHub Desktop.
Save chriskief/7509548 to your computer and use it in GitHub Desktop.
# install
sudo port install tomcat6
# add -Djava.awt.headless=true to /opt/local/share/java/tomcat6/bin/tomcatctl (line 65)
JAVA_OPTS="$JAVA_OPTS -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Djava.awt.headless=true"
# without this you’ll get this error in /opt/local/share/java/tomcat6/logs/catalina.err:
# 2013-11-16 23:39:17.389 jsvc[1698:203] Apple AWT Java VM was loaded on first thread -- can't start AWT.
# Nov 16, 2013 11:39:17 PM org.apache.catalina.startup.Bootstrap initClassLoaders
# SEVERE: Class loader creation threw exception
# java.lang.InternalError: Can't start the AWT because Java was started on the first thread. Make sure StartOnFirstThread is not specified in your application's Info.plist or on the command line
# load at startup
sudo port load tomcat6
@scottschreckengaust
Copy link

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment