if none of the other options works, then this could be an issue with the version of the jdk itself, just uninstall the current jdk and install the latest version.

i also faced this issue. after trying everything, i upgraded to the latest jdk and this issue was resolved on its own.


i was facing the same issue when i was using tomcat 8.5 with java 10. i installed java 8(1.8.0_171) and it's working fine without any issues.


on ubuntu (version 18), some application support java 8 and do not support java 11. if this is the case , you can switch to java 8 by following instruction on below topic :


i had to add an older jdk on my project.

right button on project folder > properties > java build path > libraries > add library > jre system library

enter image description here

enter image description here

in case you don't have the package for jdk8, download the jdk that some user mentioned above ( and click on "installed jres" and search for the directory you downloaded the jdk8.

enter image description here

then click on finish.

remove the apache server and add again.

the magic is done ;)


i had the same issue today when running the ancient software dundjinni, a mapping tool, on windows 10. (dundjinni requires a rather old installation of java; i haven’t tried updating java, for fear the programme will fail.) my method was to simply run dundjinni in administrator mode. here is how:

click start or press the start key, navigate down to the software, rightclick the programme, choose more, then choose run as administrator. note that this option is not available if you simply type the name of the software.

enter image description here


-open installed version of tomcatx.exe from the tomcat lib folder

-from the tomcat9 properties screen, select the java tab

-remove the line "-djava.endorsed.dirs=xxxxxx"

-select the general tab and click on the start button to restart tomcat


the error does not say much and lot of things can be wrong. one thing that was wrong in my case was following


which is clearly wrong and should have been



i was facing the same issue while i was using jdk 1.8.0_05 64 bit and eclipse-jee-oxygen-3a-win32-x86_64 on windows 64 bit operating system.

enter image description here

i resolved the issue by changing jdk version jdk1.8.0_05 to jdk1.8.0_172


for me it was picking the default jvm v6 set in env vars.

needed to explicitly add below in eclipse.ini to use v8 which is req by photon.

c:\program files\java\jdk1.8.0_75\bin\javaw.exe

note : add the entry of vm above the vm args else it will not work!


you just need to add java_home to your environment variable. just point this variable to jdk location(not the jdk bin location) as shown in the below image.enter image description here

enter image description here


add the system variable _java_options and in the "new variable value" add "-xmx1024m".

xmx sets the maximum heap memory size


i was facing the same issue while i was using "jdk-10.0.1_windows-x64_bin" and eclipse-jee-oxygen-3a-win32-x86_64 on windows 64 bit operating system.

i resolved this issue by changing my jdk to "jdk-8u172-windows-x64". now it's working fine.


edit your catlina.bat so that your -xmx settings are less than your physical memory

see tomcat 7: how to set initial heap size correctly?


  • press windows+pause keys simultaneously to open the "system" window. you can alternatively open the control panel manual to go there if you prefer it that way. click on "advanced system settings" on the left then click "advanced" tab.
  • select environmental variables here.
  • click on new under system variables.
  • enter '_java_options' as the variable name.
  • enter '-xmx1024m' as the variable value.
  • click ok twice.


i was also facing this issue when we upgraded from java 8 to java 10. i solved by removing

-djava.endorsed.dirs="c:\program files\apache software foundation\tomcat 8.5\endorsed"

from the argument.



sony@sony-vpceh25en:~$ java --version
picked up java_tool_options: -javaagent:/usr/share/java/jayatanaag.jar 
unrecognized option: --version
error: could not create the java virtual machine.
error: a fatal exception has occurred. program will exit.

solution: remove extra hyphen '-'

sony@sony-vpceh25en:~$ java -version
picked up java_tool_options: -javaagent:/usr/share/java/jayatanaag.jar 
java version "1.8.0_101"
java(tm) se runtime environment (build 1.8.0_101-b13)
java hotspot(tm) 64-bit server vm (build 25.101-b13, mixed mode)

Related Query

More Query from same tag