You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Shahar Cohen <Sh...@888holdings.com> on 2008/08/12 17:02:54 UTC

tomcat5.5 site configuration.

Hi,

I have installed tomcat 5.5 on my linux and I want to configure my
website so I would be able to connect to it without the need to
configure host header in a virtual site but receiving requests to the ip
address of the site on the specified port which are coming 

>From multiple DNS directions. 

Thanks in advanced


RE: tomcat5.5 site configuration.

Posted by Shahar Cohen <Sh...@888holdings.com>.
Thanks that solved my problem.

-----Original Message-----
From: Hassan Schroeder [mailto:hassan.schroeder@gmail.com] 
Sent: Tuesday, August 12, 2008 6:33 PM
To: Tomcat Users List
Subject: Re: tomcat5.5 site configuration.

On Tue, Aug 12, 2008 at 8:20 AM, Shahar Cohen
<Sh...@888holdings.com> wrote:

> when I put in my browser anyone of the URLS I don't get my web site.

>    <Engine name="Catalina" defaultHost="localhost">
>      <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
>             resourceName="UserDatabase" />
> #      <Host name="localhost" appBase="webapps" />

I hope you don't actually have a '#' in your server.xml -- it's not an
XML comment :-)

In any case, your default host is set to 'localhost' ; put your actual
config information there.

> <Host name="10.10.10.12" appBase="webapps"
>       unpackWARs="true" autoDeploy="true"
>       xmlValidation="false" xmlNamespaceAware="false">

And FWIW it's not recommended to put Context elements in server.xml;
name your default app ROOT (or ROOT.war) and put any config info
into META-INF/context.xml in the webapp.

> <Context path="" docBase="xxx" reloadable="true"
>       swallowOutput="true">
>      <WatchedResource>WEB-INF/web.xml</WatchedResource>
>     </Context>

HTH,
-- 
Hassan Schroeder ------------------------ hassan.schroeder@gmail.com

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: tomcat5.5 site configuration.

Posted by Hassan Schroeder <ha...@gmail.com>.
On Tue, Aug 12, 2008 at 8:20 AM, Shahar Cohen
<Sh...@888holdings.com> wrote:

> when I put in my browser anyone of the URLS I don't get my web site.

>    <Engine name="Catalina" defaultHost="localhost">
>      <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
>             resourceName="UserDatabase" />
> #      <Host name="localhost" appBase="webapps" />

I hope you don't actually have a '#' in your server.xml -- it's not an
XML comment :-)

In any case, your default host is set to 'localhost' ; put your actual
config information there.

> <Host name="10.10.10.12" appBase="webapps"
>       unpackWARs="true" autoDeploy="true"
>       xmlValidation="false" xmlNamespaceAware="false">

And FWIW it's not recommended to put Context elements in server.xml;
name your default app ROOT (or ROOT.war) and put any config info
into META-INF/context.xml in the webapp.

> <Context path="" docBase="xxx" reloadable="true"
>       swallowOutput="true">
>      <WatchedResource>WEB-INF/web.xml</WatchedResource>
>     </Context>

HTH,
-- 
Hassan Schroeder ------------------------ hassan.schroeder@gmail.com

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: tomcat5.5 site configuration.

Posted by Shahar Cohen <Sh...@888holdings.com>.
Thanks that solved my problem.

-----Original Message-----
From: Mark Thomas [mailto:markt@apache.org] 
Sent: Tuesday, August 12, 2008 6:38 PM
To: Tomcat Users List
Subject: Re: tomcat5.5 site configuration.

Shahar Cohen wrote:

Rmove this line:
> #      <Host name="localhost" appBase="webapps" />

Change this line:
> <Host name="10.10.10.12" appBase="webapps"
to:
<Host name="localhost" appBase="webapps"

Mark


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: tomcat5.5 site configuration.

Posted by Mark Thomas <ma...@apache.org>.
Shahar Cohen wrote:

Rmove this line:
> #      <Host name="localhost" appBase="webapps" />

Change this line:
> <Host name="10.10.10.12" appBase="webapps"
to:
<Host name="localhost" appBase="webapps"

Mark


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: tomcat5.5 site configuration.

Posted by Shahar Cohen <Sh...@888holdings.com>.
Hi,
In my dns I enter 3 records:
www.aaa.dev
www.bbb.dev
www.ccc.dev

all redirect to ip 10.10.10.12 
when I put in my browser anyone of the URLS I don't get my web site.
And I don't want to enter the urls as a host header in server.xml.
When I change in the server.xml to one of the URLS <Host
name="www.aaa.dev"  I get the web site
Here is my server.xml.


<?xml version="1.0" encoding="UTF-8"?>
<Server port="5111" shutdown="password">

  <GlobalNamingResources>
    <!-- Used by Manager webapp -->
    <Resource name="UserDatabase" auth="Container"
              type="org.apache.catalina.UserDatabase"
       description="User database that can be updated and saved"
           factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
          pathname="conf/tomcat-users.xml" />
  </GlobalNamingResources>

  <Service name="Catalina">
<!-- Define a non-SSL HTTP/1.1 Connector on port 5222 -->
    <Connector port="5222" maxHttpHeaderSize="8192"
               maxThreads="1500" minSpareThreads="25"
maxSpareThreads="150"
               enableLookups="false" redirectPort="8443"
acceptCount="100"
               connectionTimeout="20000" disableUploadTimeout="true"
maxKeepAliveRequests="1000" server="katatak" />


    <!-- This is here for compatibility only, not required -->
    <Connector port="5333" protocol="AJP/1.3" />

    <Engine name="Catalina" defaultHost="localhost">
      <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
             resourceName="UserDatabase" />
#      <Host name="localhost" appBase="webapps" />

<Host name="10.10.10.12" appBase="webapps"
       unpackWARs="true" autoDeploy="true"
       xmlValidation="false" xmlNamespaceAware="false">
<Context path="" docBase="xxx" reloadable="true"
       swallowOutput="true">
      <WatchedResource>WEB-INF/web.xml</WatchedResource>
     </Context>
<Valve className="org.apache.catalina.valves.AccessLogValve"
         directory="logs/xxx"  prefix="access.log."
fileDateFormat="yyyyMMddHH" suffix=""
         pattern='%B     %a     %m       %U      %q     %s      %t
%D        "%{Referer}i"    "%{User-Agent}i"        %S'
resolveHosts="false"/>

</Host>




    </Engine>

  </Service>
</Server> 

Thanks in advanced

-----Original Message-----
From: Hassan Schroeder [mailto:hassan.schroeder@gmail.com] 
Sent: Tuesday, August 12, 2008 6:08 PM
To: Tomcat Users List
Subject: Re: tomcat5.5 site configuration.

On Tue, Aug 12, 2008 at 8:02 AM, Shahar Cohen
<Sh...@888holdings.com> wrote:

> I have installed tomcat 5.5 on my linux and I want to configure my
> website so I would be able to connect to it without the need to
> configure host header in a virtual site but receiving requests to the
ip
> address of the site on the specified port which are coming
> From multiple DNS directions.

Assuming I understand what you're asking -- it does that by default.

What problem are you having?

-- 
Hassan Schroeder ------------------------ hassan.schroeder@gmail.com

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: tomcat5.5 site configuration.

Posted by Hassan Schroeder <ha...@gmail.com>.
On Tue, Aug 12, 2008 at 8:02 AM, Shahar Cohen
<Sh...@888holdings.com> wrote:

> I have installed tomcat 5.5 on my linux and I want to configure my
> website so I would be able to connect to it without the need to
> configure host header in a virtual site but receiving requests to the ip
> address of the site on the specified port which are coming
> From multiple DNS directions.

Assuming I understand what you're asking -- it does that by default.

What problem are you having?

-- 
Hassan Schroeder ------------------------ hassan.schroeder@gmail.com

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: tomcat5.5 site configuration.

Posted by Martin Gainty <mg...@hotmail.com>.
Good Morning Mr Cohen-

for CNAME, ADDR and PTR questions I would consult your sys admin for particulars on 
mapping those DNS records to specified IP

HTH
Martin
______________________________________________ 
Disclaimer and confidentiality note 
Everything in this e-mail and any attachments relates to the official business of Sender. This transmission is of a confidential nature and Sender does not endorse distribution to any party other than intended recipient. Sender does not necessarily endorse content contained within this transmission. 


> Subject: tomcat5.5 site configuration.
> Date: Tue, 12 Aug 2008 18:02:54 +0300
> From: Shahar.Cohen@888holdings.com
> To: users@tomcat.apache.org
> 
> Hi,
> 
> I have installed tomcat 5.5 on my linux and I want to configure my
> website so I would be able to connect to it without the need to
> configure host header in a virtual site but receiving requests to the ip
> address of the site on the specified port which are coming 
> 
> From multiple DNS directions. 
> 
> Thanks in advanced
> 

_________________________________________________________________
Got Game? Win Prizes in the Windows Live Hotmail Mobile Summer Games Trivia Contest
http://www.gowindowslive.com/summergames?ocid=TXT_TAGHM