You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "mzelenkovska@bluewin.ch" <mz...@bluewin.ch> on 2007/01/18 15:22:07 UTC

server.xml

Hi,

Just recently I have installed tomcat and I still cannot make my 
pages available.


I have a test file put in my webapps folder that

1. works fine when called from the server machine with the link 
localhost:8080\test\test.html
2. but http://www2.myhostmz.org/test/test.html shows page not 
found



I tested option 2 from the server and from another computer 
connected to the same router as the server. I have read somewhere 
that option 2 is not possible from the host machine and any 
machine connected to the same router. I am using dynamic DNS and 
this seems to be set up fine as I have already double-checked with 
the support team.

I have added the following code to the server.xml file in tomcat:


  <!-- This Host is the first "Virtual Host": www.fbraho.org -->
      <Host name="www2.myhostmz.org" appBase="webapps">
        <Context path="" docBase="."/>
      </Host>

Could someone please advise.

Thanks

Best Regards,
Magdalena




---------------------------------------------------------------------
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: server.xml

Posted by David Delbecq <de...@oma.be>.
En l'instant précis du 01/18/07 15:22, mzelenkovska@bluewin.ch
s'exprimait en ces termes:
> Hi,
>
> Just recently I have installed tomcat and I still cannot make my 
> pages available.
>
>
> I have a test file put in my webapps folder that
>
> 1. works fine when called from the server machine with the link 
> localhost:8080\test\test.html
> 2. but http://www2.myhostmz.org/test/test.html shows page not 
> found
>
> The 1. is indeed discussing with your tomcat web application, but considering you didn't specify the 8080 port in 2, i bet your are not discussing with tomcat but with your web server (apache, IIS, whatsoever is runing on the default http port, which is not tomcat). For information, the default error pages in tomcat contains the string "Apache Tomcat/x.y.z" where x.y.z is apache version number,
>   

Suggestion:
try

http://www2.myhostmz.org:8080/test/test.html


---------------------------------------------------------------------
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: server.xml

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: mzelenkovska@bluewin.ch [mailto:mzelenkovska@bluewin.ch] 
> Subject: server.xml
> 
> 1. works fine when called from the server machine with the link 
> localhost:8080\test\test.html

The above indicates Tomcat is listening on port 8080.  However, it's
unlikely the above actually worked with back slashes in the URL.

> 2. but http://www2.myhostmz.org/test/test.html shows page not 
> found

You left out the port number.  If you want Tomcat to use port 80 (the
browser default), change the configuration of the <Connector> element in
the server.xml file and restart Tomcat.

>       <Host name="www2.myhostmz.org" appBase="webapps">
>         <Context path="" docBase="."/>
>       </Host>

Putting <Context> elements in server.xml is strongly discouraged.  Also,
a docBase of "." indicates the app is deployed _in_ the webapps
directory rather than under it.  At best, that's inviting confusion and
disorganization.

The default app should be placed in a directory named ROOT (or packaged
in a file named ROOT.war) under the appBase directory.  If you're using
Tomcat's normal default app, you don't need a <Context> element for it
(that's the case for many apps).

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

---------------------------------------------------------------------
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