Resolve running the MapMarker Tomcat as a 64-bit Windows Service

Product affected: MapMarker™
Running the MapMarker Tomcat as a 64-bit Windows Service

In order to run MapMarker as a 64-bit Windows Service, you must first deploy MapMarker into a 64-bit instance of Tomcat.  The default instance of Tomcat included with MapMarker is 32-bit and will not run as a Windows Service when using a 64-bit JVM.  The following are the steps necessary to accomplish this.
  1. Install MapMarker first using all default settings. (Please make sure you have your license before installing.)
  2. If not already present on the server, install a 64-bit Java JRE.
    Please go to the following site:

    http://www.oracle.com/technetwork/java/javase/downloads/jre7-downloads-1880261.html
Select the jre-7u67-windows-x64.exe on the download page.

 
  1. Configure MapMarker to run as a 64-bit application by replacing the 32-bit binaries with 64-bit binaries.  Additional details on the following can be found on page 26 of the MapMarker Develoer Guide:
http://reference.mapinfo.com/software/mapmarker_plus/english/27.0/MM_USA_v27_DeveloperGuide.pdf page 26.

COPY the 64 bit MapMarker dll’s located in the following directory:
C:\Program Files (x86)\MapInfo\MapMarker_USA_v27
\sdk\additional_tools\geostan_libs\win64


User-added image

PASTE these 64 bit libraries in the C:\Program Files (x86)\MapInfo\MapMarker_USA_v27\sdk\engine\bin Folder overwriting the 32-bit files already present.
 
  1. Download 64 bit Apache Tomcat
    Please go to the following site: http://tomcat.apache.org/download-70.cgi
     
On the download page under Binary Distributions
Core:
Download
64-bit Windows zip (pgp, md5)


Once downloaded, extract the zipped file for apache-tomcat-7.0.55-windows-x64.zip to the root of where MapMarker is installed.
Example below:


User-added image

 
  1. Set the JRE_HOME for the 64-bit Tomcat, pointing to the 64-bit JVM that will be used. Set the JRE_HOME in the Startup.bat and Shutdown.bat, as follows:
    1. Go to:  C:\Program Files (x86)\MapInfo\MapMarker_USA_v27\apache-tomcat-7.0.55\bin
Open Startup.bat in a text editor.
  1. Set and add a line after setlocal and type the path for JRE_HOME to the new 64-bit JRE that will be used.
    See Set Example Below:
    setlocal
    set JAVA_HOME=
set JRE_HOME=C:\Program Files\Java\jre7
  1. Open Shutdown.bat in a text editor and make the same edits for “set JRE_HOME=C:\Program Files\Java\jre7”
Example:
-------------------------------------------------------------------------------
setlocal
set JAVA_HOME=
set JRE_HOME=C:\Program Files\Java\jre7
 
  1. Deploy MapMarker into the new 64-bit Tomcat as follows:
Copy the mapmarker40.war file located in:
C:\Program Files (x86)\MapInfo\MapMarker_USA_v27\sdk\tomcat\wars
 
Paste the mapmarker40.war in the NEW Tomcat webapps folder located here:
C:\Program Files (x86)\MapInfo\MapMarker_USA_v27\apache-tomcat-7.0.55\webapps
  1. Run the new 64 Bit Tomcat Server by clicking on the Startup.bat file located here:
    C:\Program Files (x86)\MapInfo\MapMarker_USA_v27
    \sdk\tomcat\bin
This will “explode” the war file into the Tomcat.
  1. To confirm that MapMarker was successfully deployed, test the MapMarker USA v27 Sample Application.exe located here:  C:\Program Files (x86)\MapInfo\MapMarker_USA_v27\sdk\examples
 
Type in an address, click Test to validate and click Geocode Address to see get a GeoResult.
 
  1. Now configure the 64-bit Tomcat as a Windows Service using the following steps.
 
Also See this KB on how to create the Tomcat Server as a Windows Service:
http://testdrive.mapinfo.com/techsupp/miprod.nsf/kbase_by_product/6CF53A72217F3FED852570BB006CB929
 
  1. Open a DOS window as Administrator (right click -> Run As Administrator)and navigate to the MapMarker Tomcat bin folder

    For Example:
    C:\Program Files (x86)\MapInfo\MapMarker_USA_v27\apache-tomcat-7.0.55\bin
  2. At the DOS command prompt, enter the following:
     
Service.bat Install MM64Tomcat
User-added image
  1. Start the MapMarker Service (from the Windows Start menu, choose Control Panel > Administrative Tools > Services). It will be listed as Apache Tomcat MM.

You will now see the 64 bit Apache Tomcat listed with the name gave it during the installation.
In our example we named it: MM64Tomcat

User-added image


If the service does not start, follow these additional steps:

  1. Choose Start > Run, type in regedit, and hit Enter.
  2. Navigate to the tree on the left for following registry location:
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Apache Software Foundation\Procrun 2.0\MMUSA64\Parameters\Java

 
  1. In the right pane of the registry editor, there is a key called JVM that specifies the path to a Java Virtual Machine (JVM) dll file. By default, this is set to "auto." Right-click on the JVM key and choose Modify. Change this key to point to a proper jvm.dll location.

    For example: C:\Program Files\Java\jre7\bin\server\jvm.dll
     
User-added image
Close the registry editor.
  1. Attempt to start the service (it will be listed as Apache Tomcat MM or whatever it was named as the service in the steps above) and run the Java sample application as before to test geocoding.


 

UPDATED:  September 14, 2017