Opened 8 years ago

Last modified 5 years ago

#953 new enhancement

Installer: provide better Tomcat service install experience

Reported by: jbirch Owned by:
Priority: low Milestone: 3.0
Component: Installer Version:
Severity: minor Keywords:
Cc: External ID:

Description (last modified by jbirch)

Currently, Tomcat gets installed, but no services are installed, and there is no check to ensure that a JRE/JDK is installed. Users have to:

  • Install JDK
  • Run services.bat from Tomcat/bin
  • Manually configure Apache

Although it would be great to offer a bare Tomcat option, this would take a lot of work (removing the options for Apache and PHP components during the install, providing and alternate configuration for Tomcat with non-Apache MapAgent, rewriting mapadmin in .jsp, etc). In the meantime we can do a fair amount just by automating the installation of the Tomcat service when the JSP viewer is chosen with the Bundled install.

Steps for this would looks something like:

Pull the current version from:

HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Development Kit\@CurrentVersion

Get the value of JAVA_HOME from:

HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Development Kit\{@CurrentVersion}\JavaHome

Do a file search to ensure that %JAVA_HOME%\bin\java.exe exists

If it doesn't exist, we can warn the user that the Java web extensions will not be available.

If it does exist, we can run a custom action something like this to install the service (cobbled together from service.bat in Tomcat/bin):

  [TomcatInstallDir]Tomcat/bin/tomcat6.exe //IS//[TC_SERVICE_NAME]
     --DisplayName [TC_SERVICE_DISPLAYNAME]
     --Description [TC_SERVICE_DESCRIPTION]
     --LogPath=[TomcatInstallDir]\logs
     --ClassPath=[TomcatInstallDir]\bin\bootstrap.jar
     --Install [TomcatInstallDir]Tomcat/bin/tomcat6.exe
     --StartClass org.apache.catalina.startup.Bootstrap 
     --StopClass org.apache.catalina.startup.Bootstrap 
     --StartParams start 
     --StopParams stop
     --Startup auto

And something similar for uninstall...

Change History (6)

comment:1 Changed 8 years ago by jbirch

Description: modified (diff)

comment:2 Changed 8 years ago by jbirch

Version: 2.1.0

Removing version from enhancement ticket (assumed valid regardless of version until implemented).

comment:3 Changed 7 years ago by jng

Milestone: 2.22.3

comment:4 Changed 5 years ago by jng

Milestone: 2.3

comment:5 Changed 5 years ago by jng

Milestone: 2.5

comment:6 Changed 5 years ago by jng

Milestone: 2.52.6
Note: See TracTickets for help on using tickets.