Install Liferay as Windows 2012R2 service

萝らか妹 提交于 2019-11-30 16:27:21

Configuring liferay or tomcat to run as a service on a windows server doesn't differ that much.So in order to do that you have to add some files to the LIFERAY_HOME\tomcat\bin directory.

To get those files you have to download a full version of 64-bitWindows tomcat from here : http://tomcat.apache.org/download-70.cgi. Extract the zip and go to the bin directory, copy service.bat , tomcat7.exe and tomcat7w.exe to this location : LIFERAY_HOME\tomcat\bin

  1. Setting Up the service

Open the commad prompt (Make sure you have admin rights or run the command prompt as administrator),In Command Prompt go to LIFERAY_HOME\tomcat\bin and Execute the following command

service.bat install tomcat7

This will install the tomcat6 service in windows. Now execute following commond to setup additional configuration for the service

tomcat7w.exe ES tomcat7.exe

2 . Extra configuration :

-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

and make sure to provide enough memory for your service by setting the initial memory pool and the maximum one.

Either go with Rafik Beldi's answer (quite an effort, wow) or just go to tomcat's documentation in case you're still missing some information

I had to delete what was in Java Options completely or it wouldn't start: and then I entered:

-XX:MaxPermSize=512m
-Dfile.encoding=UTF8
-Duser.timezone=America/New_York
-Dorg.apache.catalina.loader.WebappClassLoader.ENABLE_CLEAR_REFERENCES=false
-Djava.net.preferIPv4Stack=true

note that where I am: America/New_York allows for both EST and EDT

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!