This wiki does not contain official documentation and is currently deprecated and read only. Please try reading the documentation on the Liferay Developer Network, the new site dedicated to Liferay documentation. DISCOVER Build your web site, collaborate with your colleagues, manage your content, and more. DEVELOP Build applications that run inside Liferay, extend the features provided out of the box with Liferay's APIs. DISTRIBUTE Let the world know about your app by publishing it in Liferay's marketplace. PARTICIPATE Become a part of Liferay's community, meet other Liferay users, and get involved in the open source project. Tomcat 6 as a Windows Service
Table of Contents [-]
You may need to run Liferay Tomcat bundle (for both Portal and Social Office) as Windows services. Right?
Best practices#
Best combination should be
- 1) Window server 2008 64-bit, 64-bit JDK 1.6 and Tomcat 64-bit.
- 2) Window server 2003 32-bit, 32-bit JDK 1.6 and Tomcat 32-bit.
Limitation for 2) - only 1024MB (JVM parameter) is available.
Current installation: Window server 2008 64-bit, 64-bit JDK 1.6 and Tomcat 32-bit. This is the reason that
a) Tomcat as a Windows service does not work; b) staring time is longer.
Solution: using 1) Window server 2008 64-bit, 64-bit JDK 1.6 and Tomcat 64-bit.
Then we should get:
a) Tomcat as a windows service, JVM can be set as 2048MB or bigger
b) Staring time should be shorter.
How to achieve it?#
The following are sample steps to achieve the goal: Window server 2008 64-bit, 64-bit JDK 1.6 and Tomcat 64-bit.
1) Install Windows Server 2008 (64-bit)
2) Install 64-bit JDK and set $JAVA_HOME
3) Install Liferay-Tomcat 6 bundle
4) Set $JAVA_HOME in $TOMCAT_AS_DIR/bin/setenv.bat
5) Rename tomcat6.exe and tomcat6w.exe at $TOMCAT_AS_DIR/bin/ to a whatsoever names.
6) Download tomcat6.exe and tomcat6w.exe from
(for latest 64 bit binaries, refer to http://tomcat.apache.org/download-60.cgi)
And drop them to $TOMCAT_AS_DIR/bin/
7) Start service.bat install tomcat6;
8) Use >tomcat6w.exe ES tomcat6
9) Append these in Java Options:
-XX:MaxPermSize=512m-Dfile.encoding=UTF8 -Duser.timezone=GMT -Djava.security.auth.login.config="%CATALINA_HOME%/conf/jaas.config" -Dorg.apache.catalina.loader.WebappClassLoader.ENABLE_CLEAR_REFERENCES=false}}}
10) set both Initial and Maximum memory pool to 2048 or bigger;
11) Click on General tab;
12) Click start;
That’s it.