I recently updated to the latest version of Jira. My service wasn't starting, so I started checking what was going on. I followed this article to remove the old service: https://confluence.atlassian.com/adminjiraserver/running-jira-applications-as-a-windows-service-938847902.html?_ga=2.30832127.1734060536.1598734488-473765654.1574205489
However, I cannot create a new service. I get the following:
C:\PROGRA~1\Atlassian\Jira\bin>service.bat install JIRA
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
Service will use the bundled JRE.
Failing that, service will try to guess them from the registry.
Granting full access for Network Service to the Jira home directory 'C:\Program Files\Atlassian\Application Data\Jira'
processed file: C:\Program Files\Atlassian\Application Data\Jira
Successfully processed 1 files; Failed processing 0 files
Granting read and execute access for Network Service to the Jira installation directory 'C:\Program Files\Atlassian\Jira'
processed file: C:\Program Files\Atlassian\Jira
Successfully processed 1 files; Failed processing 0 files
Granting full access for Network Service to the work, temp and logs subdirectories of Jira installation directory 'C:\Program Files\Atlassian\Jira'
processed file: C:\Program Files\Atlassian\Jira/work
Successfully processed 1 files; Failed processing 0 files
processed file: C:\Program Files\Atlassian\Jira/temp
Successfully processed 1 files; Failed processing 0 files
processed file: C:\Program Files\Atlassian\Jira/logs
Successfully processed 1 files; Failed processing 0 files
Granting read and execute access for Network Service for parent directories of the Jira home directory 'C:\Program Files\Atlassian\Application Data\Jira'.
They're required to make Java native IO operations work, which are required e.g. when starting up the plugin system.
Starting to walk up from: "C:\Program Files\Atlassian\Application Data\Jira\"
Checking permissions of C:\Program Files\Atlassian\Application Data\Jira\ [C:\Program Files\Atlassian\Application Data\Jira\]
Checking permissions of C:\Program Files\Atlassian\Application Data\ [C:\Program Files\Atlassian\Application Data\Jira\..\]
Checking permissions of C:\Program Files\Atlassian\ [C:\Program Files\Atlassian\Application Data\Jira\..\..\]
Checking permissions of C:\Program Files\ [C:\Program Files\Atlassian\Application Data\Jira\..\..\..\]
Granting read and execute access for Network Service to C:\Program Files\
C:\Program Files\.: Access is denied.
Successfully processed 0 files; Failed processing 1 files
end
Granting read and execute access for Network Service for parent directories of the Jira installation directory 'C:\Program Files\Atlassian\Jira'.
They're required to make Java native IO operations work, which are required e.g. when starting up the plugin system.
Starting to walk up from: "C:\Program Files\Atlassian\Jira\"
Checking permissions of C:\Program Files\Atlassian\Jira\ [C:\Program Files\Atlassian\Jira\]
Checking permissions of C:\Program Files\Atlassian\ [C:\Program Files\Atlassian\Jira\..\]
Checking permissions of C:\Program Files\ [C:\Program Files\Atlassian\Jira\..\..\]
Granting read and execute access for Network Service to C:\Program Files\
C:\Program Files\.: Access is denied.
Successfully processed 0 files; Failed processing 1 files
end
Installing the service 'JIRA' ...
Using CATALINA_HOME: "C:\Program Files\Atlassian\Jira"
Using CATALINA_BASE: "C:\Program Files\Atlassian\Jira"
Ignoring JAVA_HOME: "C:\Program Files\Java\jre1.8.0_261"
Using JRE_HOME: "C:\PROGRA~1\Atlassian\Jira\bin\jre"
Warning: Neither 'server' nor 'client' jvm.dll was found at JRE_HOME.
Using JVM: "auto"
****************************************************************************
******* Wrong JVM version Jira requires 1.8 or 11 to run. *******
****************************************************************************
***
*** Output of java -version command is:
The system cannot find the path specified.
*** (End of output) ***
***
*** If you want JIRA to start using this JVM
*** set environment variable 'ignore_jvm_version' to 'true'
***
****************************************************************************
I've googled around and found these:
https://community.atlassian.com/t5/Jira-questions/JIRA-config-tool-says-wrong-JVM-but-it-s-not/qaq-p/95883
https://community.atlassian.com/t5/Jira-questions/Wrong-JVM-version-JIRA-requires-1-8-or-11-to-run/qaq-p/1228936
but nothing works... no matter what I do in my config.bat file, Jira complains it can't find Java and won't create the service.