Solved

how to configure virtual host in tomcat 4.x

Posted on 2006-11-13
2
194 Views
Last Modified: 2010-03-04
Hi Guys

I had tomcat 5.x set up on my computer but for compatibilty issues wth the production server we are de-grading our servers to 4.x

now would you guys please help me in setting up virtual host in version 4.x

In tomcat 5.x  I had the virtual hosting configuration as follows, i tried the same in 4.x but it doesnt work

-----------------------------

<Host name="localhost" appBase="" unpackWARs="true" autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false">
     <Context path ='' docBase= 'C:\svn_chapters\trunk\Tomcat\webapps\chapters' debug='0' />    
</Host>

<Host name="newccim.woody.com" appBase="" unpackWARs="true" autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false">
     <Context path ='' docBase= 'C:\svn_ccim\trunk\Tomcat\webapps\ccim' debug='0' />
</Host>



0
Comment
Question by:huzefaq
  • 2
2 Comments
 
LVL 6

Accepted Solution

by:
bpeterse earned 500 total points
ID: 17942490
We're running on 4.1.3 on Solaris and it appears to contain a bit more:      

<Host className="org.apache.catalina.core.StandardHost" appBase="{your_app_base}" autoDeploy="true" configClass="org.apache.cata
lina.startup.ContextConfig" contextClass="org.apache.catalina.core.StandardContext" debug="0" deployXML="true" errorReportValveClass="org
.apache.catalina.valves.ErrorReportValve" liveDeploy="true" mapperClass="org.apache.catalina.core.StandardHostMapper" name="{your_FQDN}" unpackWARs="true">
        <Valve className="org.apache.catalina.valves.AccessLogValve" debug="0" directory="logs/access" resolveHosts="false" suffix=".txt"
 prefix="{app_name_access.}" pattern="%h %l %u %t &quot;%r&quot; %s %b" fileDateFormat="yyyy-MM-dd" rotatable="true"/>
      <Alias>{your_app_alias}</Alias>
</Host>


The hierarchy of elements is as follows - top to bottom (don't forget your closing elements):

<Server>
 <JNDI> (if needed)
 <Service>
  <Connector>
   <Engine>
    <Listener> global
    <Valve> global
    <Realm> global
    <Logger> global
     <Host> default
      <Context> default
     <Host(s)> defined
      <Valve>
      <Logger>
0
 
LVL 6

Expert Comment

by:bpeterse
ID: 17942503
Perhaps you can access the admin GUI to set it up through that - in 4.x I believe the admin gui was included in the distribution.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In my time as an SEO for the last 2 years and in the questions I have assisted with on here I have always seen the need to redirect from non-www urls to their www versions. For instance redirecting http://domain.com (http://domain.com) to http…
It is possible to boost certain documents at query time in Solr. Query time boosting can be a powerful resource for finding the most relevant and "best" content. Of course the more information you index, the more fields you will be able to use for y…
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

25 Experts available now in Live!

Get 1:1 Help Now