tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sean Dockery" <s...@sbdconsultants.com>
Subject Re: Virtual Hosting Tomcat
Date Tue, 11 Feb 2003 21:05:41 GMT
www.inqbyte.com is not in your hosts file, so your machine looks to your DNS
server to resolve to it to an IP.  If you put www.ipqbyte.com in your hosts
file, it should work as you expect.

Sean Dockery
sean@sbdconsultants.com
Certified Java Web Component Developer
Certified Delphi Programmer
SBD Consultants
http://www.sbdconsultants.com

----- Original Message -----
From: "Sangam Dash" <srdash@rippleimpact.com>
To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
Sent: Tuesday, February 11, 2003 12:21
Subject: Re: Virtual Hosting Tomcat


> hi
>
> I have this
> <Host name="inqbyte.com" debug="0" appBase="webapps" unpackWARs="true">
>         <Alias>www.inqbyte.com</Alias>
>         <Logger className="org.apache.catalina.logger.FileLogger"
> directory="logs" prefix="inqbyte." suffix=".log" timestamp="true"/>
>         <Context path="" docBase="ripple" debug="0" reloadable="true"/>
>     </Host>
> in the server.xml file now
> in the hosts file
> it is
> 127.0.0.1 inqbyte.com
> so now when i say http://www.inqbyte.com:8080/  it says page cant be found
> without the alias it works fine
> when i say http://inqbyte.com:8080/ it works fine
> do u know what happens?
> thanks
> sangam dash
> Sean Dockery wrote:
>
> >What do you mean that you don't find any errors in the logs folder?
Where
> >did you look?  What about the output of the console window when you start
> >Tomcat manually?  I'm willing to be that you fatally corrupted your
> >server.xml file somehow.
> >
> >Make a copy of the Host definition for localhost within the same Engine
> >definition.  Then make changes to the copy.  Your Host definition is far
> >more sparse than mine.
> >
> >
> >Sean Dockery
> >sean@sbdconsultants.com
> >Certified Java Web Component Developer
> >Certified Delphi Programmer
> >SBD Consultants
> >http://www.sbdconsultants.com
> >
> >
> >----- Original Message -----
> >From: "Sangam Dash" <srdash@rippleimpact.com>
> >To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
> >Sent: Tuesday, February 11, 2003 11:31
> >Subject: Re: Virtual Hosting Tomcat
> >
> >
> >
> >
> >>Hi
> >>i added something like you said to the hosts file
> >>127.0.0.1 rippleimpact
> >>then if i give rippleimpact:8080 it works
> >>thanks a lot
> >>but then i added
> >>this to the server.xml file
> >>
> >><Host name="rippleimpact" debug="0" appBase="webapps" unpackWARs="true">
> >>        <Logger className="org.apache.catalina.logger.FileLogger"
> >>directory="logs" prefix="ripple." suffix=".log" timestamp="true"/>
> >>        <Context path="" docBase="ripple" debug="0" reloadable="true"/>
> >>        <Context path="" docBase="mydomain0" debug="0"
reloadable="true"/>
> >>    </Host>
> >>is there something wrong with this ?
> >>tomcat doesnt start now...
> >>do you have any idea why its doing that?
> >>i dont find any error showing in the logs folder?
> >>please help
> >>thanks
> >>sangam dash
> >>Sean Dockery wrote:
> >>
> >>
> >>
> >>>I have done this in the past.  Here's what you can do...
> >>>
> >>>Open the "hosts" file on your machine (in WinNT\System32\drivers\etc on
> >>>
> >>>
> >my
> >
> >
> >>>Windows 2000 machine--your location may be different) and add the
> >>>
> >>>
> >following
> >
> >
> >>>lines to the end of the file...
> >>>
> >>>127.0.0.1    alpha
> >>>127.0.0.1    gamma
> >>>127.0.0.1    omega
> >>>
> >>>For each Host.name attribute in your server.xml, set it to a machine
> >>>
> >>>
> >name.
> >
> >
> >>>Like this...
> >>>
> >>> <Host name="alpha" ...>
> >>>   ...
> >>> </Host>
> >>>
> >>> <Host name="gamma" ...>
> >>>   ...
> >>> </Host>
> >>>
> >>> <Host name="omega" ...>
> >>>   ...
> >>> </Host>
> >>>
> >>>Then you should be able to access your local machine using different
> >>>
> >>>
> >names
> >
> >
> >>>like this...
> >>>
> >>>http://alpha:8080/
> >>>http://gamma:8080/
> >>>http://omega:8080/
> >>>
> >>>Good luck.
> >>>
> >>>Sean Dockery
> >>>sean@sbdconsultants.com
> >>>Certified Java Web Component Developer
> >>>Certified Delphi Programmer
> >>>SBD Consultants
> >>>http://www.sbdconsultants.com
> >>>
> >>>----- Original Message -----
> >>>From: "Lajos" <lmocz@galatea.com>
> >>>To: "Tomcat Users List" <tomcat-user@jakarta.apache.org>
> >>>Sent: Monday, February 10, 2003 20:25
> >>>Subject: Re: Virtual Hosting Tomcat
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>>Ouch, windows. I'm not too sure - maybe someone else can provide the
> >>>>info. On older versions, you could edit some file like lmhosts ...
> >>>>
> >>>>I like fronting Tomcat with Apache for security reasons, but I still
use
> >>>>virtual hosts in Tomcat. I have no idea why you are running out of
> >>>>memory - how much RAM do you have? It may be due to your applications
> >>>>more than Tomcat itself.
> >>>>
> >>>>Regards,
> >>>>
> >>>>Lajos
> >>>>
> >>>>
> >>>>Sangam Dash wrote:
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>>Hi
> >>>>>
> >>>>>Thanks for the mail.
> >>>>>But do you know how to do that on windows machine?
> >>>>>The other thing is that when i add this one to the server.xml file
the
> >>>>>tomcat runs out of memory and it gives premature end of file error
> >>>>>sometimes. :-[
> >>>>>Is it better to have apache and tomcat both configured for this kind
of
> >>>>>situations? :-\
> >>>>>Thanks a lot
> >>>>>Sangam Dash :-)
> >>>>>Lajos wrote:
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >>>>>>Hi Sangam -
> >>>>>>
> >>>>>>Looks like the examples from my FlashGuide ;) What doesn't work?
One
> >>>>>>thing that you must make sure is that the values of the name
attribute
> >>>>>>of the <Host> resolve to your machine. You can do this
via your
> >>>>>>machine's DNS configuration. In the example below, mydomain0.com,
> >>>>>>mydomain1.com and mydomain2.com must resolve to the same machine.
If
> >>>>>>not, the example won't work.
> >>>>>>
> >>>>>>Regards,
> >>>>>>
> >>>>>>Lajos
> >>>>>>
> >>>>>>
> >>>>>>Sangam Dash wrote:
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>>>Hi
> >>>>>>>
> >>>>>>>I am using tomcat for my websites.
> >>>>>>>I am not using apache.
> >>>>>>>I need to do have two websites running from the same machine
with
the
> >>>>>>>same tomcat instance.
> >>>>>>>i didnt get any help on the net as everything for virtual
hosting
is
> >>>>>>>with apache and tomcat combination.
> >>>>>>>is it possible to server two different websites from same
machine
> >>>>>>>using only tomcat?
> >>>>>>>please help me out
> >>>>>>>
> >>>>>>>I tried the following
> >>>>>>>but it doesnt work
> >>>>>>>
> >>>>>>>added this following to the server.xml file
> >>>>>>><Host name="mydomain0.com" debug="0" appBase="webapps"
> >>>>>>>unpackWARs="true">
> >>>>>>>     <Logger className="org.apache.catalina.logger.FileLogger"
> >>>>>>>directory="logs" prefix="mydomain0." suffix=".log"
timestamp="true"/>
> >>>>>>>     <Context path="" docBase="mydomain0" debug="0"
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>reloadable="true"/>
> >>>
> >>>
> >>>
> >>>
> >>>>>>>     <Context path="/test" docBase="mydomain0" debug="0"
> >>>>>>>reloadable="true"/>
> >>>>>>> </Host>
> >>>>>>> <Host name="mydomain1.com" debug="0" appBase="webapps"
> >>>>>>>unpackWARs="true">
> >>>>>>>     <Logger className="org.apache.catalina.logger.FileLogger"
> >>>>>>>directory="logs" prefix="mydomain1." suffix=".log"
timestamp="true"/>
> >>>>>>>     <Context path="" docBase="mydomain1" debug="0"
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>reloadable="true"/>
> >>>
> >>>
> >>>
> >>>
> >>>>>>>     <Context path="/test" docBase="mydomain1" debug="0"
> >>>>>>>reloadable="true"/>
> >>>>>>> </Host>
> >>>>>>> <Host name="mydomain2.com" debug="0" appBase="webapps"
> >>>>>>>unpackWARs="true">
> >>>>>>>     <Logger className="org.apache.catalina.logger.FileLogger"
> >>>>>>>directory="logs" prefix="mydomain2." suffix=".log"
timestamp="true"/>
> >>>>>>>     <Context path="" docBase="mydomain2" debug="0"
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>reloadable="true"/>
> >>>
> >>>
> >>>
> >>>
> >>>>>>>     <Context path="/test" docBase="mydomain2" debug="0"
> >>>>>>>reloadable="true"/>
> >>>>>>> </Host>    i appreciate any kind of help ...
> >>>>>>>i am using tomcat 4.1.12
> >>>>>>>
> >>>>>>>thanks a lot
> >>>>>>>sangam dash
> >>>>>>>
> >>>>>>>
>
>>>>>>>---------------------------------------------------------------------
> >>>>>>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >>>>>>>For additional commands, e-mail:
tomcat-user-help@jakarta.apache.org
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>>
> >>>>>>
> >>>>>>
> >>>>>---------------------------------------------------------------------
> >>>>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >>>>>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >>>>>
> >>>>--
> >>>>
> >>>>
> >>>>
> >>>>                   Lajos Moczar
> >>>>      ----------------------------------------
> >>>>    Open Source Support, Consulting and Training
> >>>>      ----------------------------------------
> >>>>            Cocoon Developer's Handbook
> >>>> (www.amazon.com/exec/obidos/tg/detail/-/0672322579)
> >>>>
> >>>>                   _      _____
> >>>>                  / \         /
> >>>>                 /___\      /
> >>>>                /     \   /____
> >>>>
> >>>>     http://www.galatea.com -- powered by AzSSL
> >>>>
> >>>>
> >>>>---------------------------------------------------------------------
> >>>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >>>>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>
> >>>---------------------------------------------------------------------
> >>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >>>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >>>
> >>>
> >>>
> >>>
> >>>
> >>
> >>
> >>
> >
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >
> >
> >
>
>
>



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message