Thank you Lutz,

    I was trying for the second option, 

    Here is how my server.xml file 

      <Engine defaultHost="techserv" name="Catalina">
      <Host appBase="webapps" name="techserv">
        <Logger className="org.apache.catalina.logger.FileLogger"
prefix="techserv_log." suffix=".txt" timestamp="true"/>
      </Host>


   But if I do this,  I'm not able to go to http://techserv:8080/admin  .
It gives me HTTP error 404 ( requested page not available. )


Thanks,
Mandar

 

-----Original Message-----
From: Lutz Zetzsche [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, May 10, 2005 11:51 AM
To: Tomcat Users List
Subject: Re: How to change hostname in tomcat configuration

Hi Mandar,

Mandar Vaidya schrieb:
>     I'm trying to change hostname on the tomcat server from localhost 
> to my server name. After I change it in server.xml, I'm able to go to 
> http://servername:8080  url, but I'm not able to go to 
> http://servername:8080/admin .  It gives me error.
>
>     Aprreciate any help regarding this.

Instead of changing the name attribute of your Host element from "localhost"
to "servername", you can also simply nest an Alias element into the Host
element:

     <Host name="localhost" ...>
       ...
       <Alias>servername</Alias>
       ...
     </Host>

However, if you prefer to change the name attribute rather than to add an
alias, make sure to customize the defaultHost attribute of your Engine
element if you only have one Host element inside:

"The default host name, which identifies the Host that will process requests
directed to host names on this server, but which are not configured in this
configuration file. This name MUST match the name attributes of one of the
Host elements nested immediately inside."

!


Best wishes

Lutz


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to