Saturday 28 April 2012

Running Liferay 6.1 CE on Non Root Context

By default Liferay 6.1 CE runs on root context after installation. Sometimes this may not be possible. Assuming that we would like Liferay 6.1 CE to work as http://<hostname>/myportal instead of http://<hostname>/, just make the following changes.

1. Under liferay-portal-6.1.0/tomcat-7.0.23/webapps directory
  • Rename directory ROOT to myportal
2. Under liferay-portal-6.1.0/tomcat-7.0.23/conf/Catalina/localhost directory
  • Rename file root to myportal
  • Edit myportal file and change  <Context path=""...> to  <Context path="/myportal"...>
3. Under  liferay-portal-6.1.0 directory
  • Edit (create one if it does not exist), add in portal.ctx=/myportal
4. After restarting Liferay, it is very important to perform the following additional step. Without making this change, a number of portlets such as message board would not work properly.
  • Login as portal administrator
  • Bring up "Control Panel" and click on "Portal Instances" under "Server" tab
  • Change the default value "localhost" at "Virtual Host" to the domain where Liferay is hosted.
5. Liferay should be working on http://<hostname>/myportal

1 comment:

  1. brillant piece of information, I had come to know about your web-page from my friend hardkik, chennai,i have read atleast 9 posts of yours by now, and let me tell you, your webpage gives the best and the most interesting information. This is just the kind of information that i had been looking for, i'm already your rss reader now and i would regularly watch out for the new posts, once again hats off to you! Thanx a million once again, Regards liferay training in hyderabad