LetsEncrypt not working with multiple domains managed by Apache web server running on Apache Tomcat.
Hello friends, To start of with, my apologies for sending the mail to two lists, but as the problem involves around both Tomcat and Apache, I am sending this email on both lists. Situation : I have a Debian X64 server running Apache Web-server which is running a CMS on its own and also redirecting requests to Tomcat based upon the URL. I have a single Tomcat, which hosts 3 webapps for 3 different domains. In Apache web-server I have set the ServerName and ServerAlias, which will then redirect the request to Apache Tomcat, and the proper webapp will be called. Now, this all works when we are dealing only with HTTP, situation with HTTPS is completely different though. WHenever I install SSL certificate for one domain, redirect based on domain-name and port 443, then I get a redirection error or I am simply redirected to the hosted CMS. Other domains which are not on https keep working. This setup works very nicely with port-80 or http, but with HTTPs it's completely useless. What changes do I need to make such a setup work. Thank you. Apache config : workers.properties : > worker.list = worker_app1 > worker.worker_app1.type = lb > worker.worker_app1.balance_workers = app1_instance1 > worker.worker_app1.sticky_session = true > worker.worker_app1.sticky_session_force = false > worker.worker_app1.method = busyness > > worker.app1_instance1.type = ajp13 > worker.app1_instance1.host = 127.0.0.1 > worker.app1_instance1.port = 8010 > worker.app1_instance1.host = localhost > worker.app1_instance1.lbfactor = 1 > worker.app1_instance1.socket_timeout = 40 > worker.app1_instance1.socket_keepalive = true > worker.app1_instance1.reply_timeout = 3 > 000-default below : > > Listen 443 > > ServerAdmin webmaster@localhost > ServerName www.webserver-domain.com > ServerAlias webserver-domain.com > DocumentRoot /var/www > > Options FollowSymLinks > AllowOverride None > > > Options Indexes FollowSymLinks MultiViews > AllowOverride All > Order allow,deny > allow from all > > > ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/ > > AllowOverride None > Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch > Order allow,deny > Allow from all > > > ErrorLog ${APACHE_LOG_DIR}/error.log > > # Possible values include: debug, info, notice, warn, error, > crit, > # alert, emerg. > LogLevel warn > ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/ > > AllowOverride None > Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch > Order allow,deny > Allow from all > > > ErrorLog ${APACHE_LOG_DIR}/error.log > > # Possible values include: debug, info, notice, warn, error, > crit, > # alert, emerg. > LogLevel warn > > CustomLog ${APACHE_LOG_DIR}/access.log combined > > > > ServerName www.tomcat-domain1.de > ServerAlias tomcat-domain1.de > ProxyRequests off > ProxyPreserveHost On > > Order deny,allow > Allow from all > > #ErrorDocument 503 /maintenance.html > # ErrorDocument 404 /maintenance.html > # ErrorDocument 500 /maintenance.html > > #ProxyPass /maintenance.html ! > ProxyPass / http://localhost:8080/ > ProxyPassReverse / http://localhost:8080/ > >> Order allow,deny > Allow from all > > > > > > > ServerName www.tomcat-domain2.de > ServerAlias tomcat-domain2.de > ProxyRequests off > ProxyPreserveHost On > > Order deny,allow > Allow from all > > SSLProxyCheckPeerExpire off > SSLEngine on > SSLCertificateFile /etc/letsencrypt/live/ > www.tomcat-domain2.de/ende.crt > SSLCertificateKeyFile /etc/letsencrypt/live/ > www.tomcat-domain2.de/private.key > > > ErrorDocument 503 /maintenance.html > ErrorDocument 404 /maintenance.html > ErrorDocument 500 /maintenance.html > > ProxyPass /maintenance.html ! > > ProxyPass / http://localhost:8080/ > ProxyPassReverse / http://localhost:8080/ > > > Order allow,deny > Allow from all > > > > > > ServerName www.tomcat-domain3.de > ServerAlias tomcat-domain3.de > ProxyRequests off > ProxyPreserveHost On > > Order deny,allow > Allow from all > > > ErrorDocument 503 /maintenance.html > ErrorDocument 404 /maintenance.html > ErrorDocument 500 /maintenance.html > > ProxyPass /maintenance.html ! > > ProxyPass / http://localhost:8080/ > ProxyPassReverse / http://localhost:8080/ > > > Order allow,deny > Allow from all > > > > > > ServerName www.tomcat-domain4.com > ServerAlias tomcat-domain4.com > > ProxyRequests off > ProxyPreserveHost On > > Order deny,allow > Allow from all > > > ErrorDocument 503 /maintenance.html > ErrorDocument 404 /maintenance.html > ErrorDocument 500 /maintenance.html > > ProxyPass /maintenance.html ! >
Multiple domains accessing same Tomcat content
I thought i would understand how to config a 2nd domain to access the same content after configuring for the first domain but that proved wrong. I have multiple domains that need to access the same content. For example, http://share.domain1.com should result in http://share.domain1.com/share and http://share.domain2.com should result in http://share.domain2.com/share. Thanks to Ranier, i have 1 working config accessing http://share.domain.com. Now, how do i add a 2nd domain so they will type http://share.domain2.com and get http://share.domain2.com/share? Here is the workers.properties file configured for domain2: worker.properties: # Define two status worker: # - jk-status for read-only use # - jk-manager for read/write use worker.list=jk-status worker.jk-status.type=status worker.jk-status.read_only=true worker.list=jk-manager worker.list=worker1 worker.list=worker2 worker.jk-manager.type=status # We define a load balancer worker # with name balancer worker.list=balancer worker.balancer.type=lb # error_escalation_time: seconds, default = recover_time/2 (=30) # Determines, how fast a detected error should switch from # local error state to global error state # Since: 1.2.28 #worker.balancer.error_escalation_time=0 # - max_reply_timeouts: number, default=0 # If there are to many reply timeouts, a worker # is put into the error state, i.e. it will become # unavailable for all sessions residing on the respective # Tomcat. The number of tolerated reply timeouts is # configured with max_reply_timeouts. The number of # timeouts occuring is divided by 2 once a minute and the # resulting counter is compared against max_reply_timeouts. # If you set max_reply_timeouts to N and the errors are # occuring equally distributed over time, you will # tolerate N/2 errors per minute. If they occur in a burst # you will tolerate N errors. # Since: 1.2.24 worker.balancer.max_reply_timeouts=10 # Now we add members to the load balancer # First member is node1, most # attributes are inherited from the # template worker.template. worker.balancer.balance_workers=worker1 worker.worker1.reference=worker.template worker.worker1.host=localhost worker.worker1.port=8009 # Activation allows to configure # whether this node should actually be used # A: active (use node fully) # D: disabled (only use, if sticky session needs this node) # S: stopped (do not use) # Since: 1.2.19 worker.worker1.activation=A # Second member is node2, most # attributes are inherited from the # template worker.template. worker.balancer.balance_workers=worker2 worker.worker2.reference=worker.template worker.worker2.host=localhost worker.worker2.port=8009 # Activation allows to configure # whether this node should actually be used # A: active (use node fully) # D: disabled (only use, if sticky session needs this node) # S: stopped (do not use) # Since: 1.2.19 worker.worker2.activation=A # Finally we put the parameters # which should apply to all our ajp13 # workers into the referenced template # - Type is ajp13 worker.template.type=ajp13 # - socket_connect_timeout: milliseconds, default=0 # Since: 1.2.27 #worker.template.socket_connect_timeout=5000//not supported in the version of mod_jk running 1.2.26 # - socket_keepalive: boolean, default=false # Should we send TCP keepalive packets # when connection is idle (socket option)? worker.template.socket_keepalive=true # - ping_mode: Character, default=none # When should we use cping/cpong connection probing? # C = directly after establishing a new connection # P = directly before sending each request # I = in regular intervals for idle connections # using the watchdog thread # A = all of the above # Since: 1.2.27 #worker.template.ping_mode=A//not supported in the version of mod_jk running 1.2.26 # - ping_timeout: milliseconds, default=1 # Wait timeout for cpong after cping # Can be overwritten for modes C and P # Using connect_timeout and prepost_timeout. # Since: 1.2.27 #worker.template.ping_timeout=1//not supported in the version of mod_jk running 1.2.26 # - connection_pool_minsize: number, default=connection_pool_size # Lower pool size when shrinking pool due # to idle connections # We want all connections to be closed when # idle for a long time in order to prevent # firewall problems. # Since: 1.2.16 worker.template.connection_pool_minsize=0 # - connection_pool_timeout: seconds, default=0 # Idle time, before a connection is eligible # for being closed (pool shrinking). # This should be the same value as connectionTimeout # in the Tomcat AJP connector, but there it is # milliseconds, here seconds. worker.template.connection_pool_timeout=600 # - reply_timeout: milliseconds, default=0 # Any pause longer than this timeout during waiting # for a part of the reply will abort handling the request # in mod_jk. The request will proceed running in # Tomcat, but the web server resources will be freed
RE: Tomcat with multiple domains
-Original Message- From: André Warnier [mailto:a...@ice-sa.com] Sent: Friday, November 30, 2012 9:11 AM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Jeffrey Janner wrote: -Original Message- From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Sent: Wednesday, November 28, 2012 5:29 PM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Hi! Thanks for your quick and detailed answers. Actually I think I did all the things you mentioned but it still does not work. So here are the changes I made: 1. I checked that the following entries are in the engine tag: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true [Jeff Janner] You need a /Host here. All elements must have a begin tag and an end tag! If there are no sub-elements, you can combine the begin and end tags as tagname ... /. Please find a good introductory reference on XML markup language before continuing. Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host Haaa. Good catch, Jeffrey. Everyone else missed that. So it probably swallowed the second Host's tags in the first, with who knows which results. Surprising that Tomcat still starts. You wouldn't believe how any times I've had to correct something like this for customer self-installs, even with what I think is proper documentation to guide them. It really does come down to understanding the structure of XML. Jeff - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
Thank you guys for your great help. It was indeed an error in the xml that I entered in the server.xml file. I put something like this: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host /Host /Engine /Service /Server Notice that I nested the virtual host definition within the host definition tags of the default host. So, therefore it did not work and I didn't see it. Okay now it works perfectly fine. Again, thanks for your fantastic support! 2012/11/30 Hassan Schroeder hassan.schroe...@gmail.com: On Fri, Nov 30, 2012 at 2:12 PM, Christopher Schultz ch...@christopherschultz.net wrote: OP never posted the whole XML, so we don't know that it's definitely not well-formed. Good point -- should have asked for the whole file before jumping to that conclusion. But it certainly looked sketchy :-) -- Hassan Schroeder hassan.schroe...@gmail.com http://about.me/hassanschroeder twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
Paul, you shouldn't top-post. It makes it hard to follow the logical gist of the conversation. 2012/11/30 Hassan Schroeder hassan.schroe...@gmail.com: On Fri, Nov 30, 2012 at 2:12 PM, Christopher Schultz ch...@christopherschultz.net wrote: OP never posted the whole XML, so we don't know that it's definitely not well-formed. Good point -- should have asked for the whole file before jumping to that conclusion. But it certainly looked sketchy :-) -- Paul van Hoven wrote: Thank you guys for your great help. It was indeed an error in the xml that I entered in the server.xml file. I put something like this: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host /Host /Engine /Service /Server Notice that I nested the virtual host definition within the host definition tags of the default host. So, therefore it did not work and I didn't see it. Okay now it works perfectly fine. Again, thanks for your fantastic support! So, taking into account Christoper's detailed explanation of why Tomcat would not detect this as an error in server.xml, we are still left with something strange here. Assuming that Paul previously reported the result correctly (he requested a URL mapping to the first host, and got a response from an app of the second Host instead), that would mean that in the process of parsing the above, Tomcat somehow overwrote the appBase of the first Host tag, with the appBase of the second Host tag, no ? - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat with multiple domains
-Original Message- From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Sent: Wednesday, November 28, 2012 5:29 PM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Hi! Thanks for your quick and detailed answers. Actually I think I did all the things you mentioned but it still does not work. So here are the changes I made: 1. I checked that the following entries are in the engine tag: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true [Jeff Janner] You need a /Host here. All elements must have a begin tag and an end tag! If there are no sub-elements, you can combine the begin and end tags as tagname ... /. Please find a good introductory reference on XML markup language before continuing. Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host /Engine /Service /Server 2. In the host file I altered the entries to 88.84.140.85 www.my2nddomain.com 88.84.140.85 www.my1rstdomain.com 3. I actually did not really understand what you meant by Also, since you are using the /etc/hosts file instead of the DNS system, the client (browser) also has those entries in its hosts file. And, as Konstantin pointed out, you don't put the port number in the /etc/hosts file. If you are using DNS for the clients, make sure that it has entries for both hosts, pointing to the same IP address. I'm not shure if I understand the meaning of DNS in this case correctly. Do you mean a DNS on my local machine or do you mean the DNS on a remote machine? I've got a pure domain hoster and I set an A record entry such that the domain is forwarded to my server / ip address 88.84.140.85. Both domains are actually pointing to this ip address since both are hosted by the same domain hoster. I do not explicitly use DNS on my local machine, at least I did not configure it. And how can the client (browser) have entries in a host file? The current status is that when calling www.my1rstdomain.com:8080 points to the webapp installed for www.my2nddomain.com:8080. 2012/11/27 Jeffrey Janner jeffrey.jan...@polydyne.com: -Original Message- From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Sent: Tuesday, November 27, 2012 2:13 PM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Thanks for the answer. I followed the tutorial you propose ( http://wiki.apache.org/tomcat/TomcatDevelopmentVirtualHosts ). But it is still not working. Here is my new configuration server.xml Host name=2nddomain.com appBase=/opt/apache-tomcat-7.0.32/2nddomain.com unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Alias2nddomain.com/Alias Aliaswww.2nddomain.com/Alias /Host The directory /opt/apache-tomcat-7.0.32/2nddomain.com contains a ROOT.war file. I edited the /etc/hosts file and added the following entries: 88.84.140.88 www.2nddomain.com:8080 88.84.140.88 www.1rstdomain.com:8080 Then I restarted the system and the tomcat server. Entering www.2nddomain.com:8080 sends me to 1rstdomain.com. I noticed that the file /opt/apache-tomcat-7.0.32/2nddomain.com/ROOT.war remains untouched by tomcat, at least nothing is extracted from the war file. So what else am I missing here? Make sure that the new Host/Host definition is nested inside the Engine/Engine tags. You also do not need the first Alias line. The name= parameter takes care of that mapping for you. In general, the nesting works this way: Server ... Service ... Connector ... / Connector ... / Engine ... Host name=host1.com ... Aliaswww.host1.com/Alias /Host Host name=www.host2.com ... Aliashost2.com/Alias /Host Host name=www.myhost.com ... / /Engine /Service /Server There are a myriad other tag sets that could be included in there and it's very important that they be nested properly to work properly. Also, since you are using the /etc/hosts file instead of the DNS system, the client (browser) also has those entries in its hosts file. And, as Konstantin pointed out, you don't put the port number in the /etc/hosts file. If you are using DNS for the clients, make sure that it has entries for both hosts, pointing to the same IP address. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
Re: Tomcat with multiple domains
Jeffrey Janner wrote: -Original Message- From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Sent: Wednesday, November 28, 2012 5:29 PM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Hi! Thanks for your quick and detailed answers. Actually I think I did all the things you mentioned but it still does not work. So here are the changes I made: 1. I checked that the following entries are in the engine tag: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true [Jeff Janner] You need a /Host here. All elements must have a begin tag and an end tag! If there are no sub-elements, you can combine the begin and end tags as tagname ... /. Please find a good introductory reference on XML markup language before continuing. Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host Haaa. Good catch, Jeffrey. Everyone else missed that. So it probably swallowed the second Host's tags in the first, with who knows which results. Surprising that Tomcat still starts. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 André, On 11/30/12 10:11 AM, André Warnier wrote: Jeffrey Janner wrote: -Original Message- From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Sent: Wednesday, November 28, 2012 5:29 PM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Hi! Thanks for your quick and detailed answers. Actually I think I did all the things you mentioned but it still does not work. So here are the changes I made: 1. I checked that the following entries are in the engine tag: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true [Jeff Janner] You need a /Host here. All elements must have a begin tag and an end tag! If there are no sub-elements, you can combine the begin and end tags as tagname ... /. Please find a good introductory reference on XML markup language before continuing. Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host Haaa. Good catch, Jeffrey. Everyone else missed that. +1 So it probably swallowed the second Host's tags in the first, with who knows which results. Surprising that Tomcat still starts. Unfortunately, Tomcat does not validate against an XML schema or DTD and so otherwise insane configurations can generally be launched without any errors being generated. This is a double-edged sword. In this case, it made it difficult to detect a configuration error. In other cases, it makes it possible to use very complex configuration that the Tomcat developers didn't expect beforehand. One reason Tomcat cannot validate against a schema or DTD is because of things like Resource: they allow a user to specify any attribute name and have its value get set on the component being configured. This is not possible with a strictly-validating parser. I'm unaware of a technique to allow partial structural validity (say, element nesting) without also explicitly specifying which attributes are allowed. Use of the Apache commons-digester component means that detecting structural missteps would require that the component be configured with all possible missteps in advance which is quite impossible. I haven't looked, but it might be nice if the digester supported fallback rules where an event that didn't match an existing rule could fire a catch-all rule. That way, an unexpected element could generate an error message and possibly prevent Tomcat from even starting. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with undefined - http://www.enigmail.net/ iEYEARECAAYFAlC5KjQACgkQ9CaO5/Lv0PBR4wCgijyZWhQEcknzui7Dm6CUwnTY x+kAoLXjE9IsomYVwhp9hNgoBDYgx3Ek =OmWc -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
On Fri, Nov 30, 2012 at 1:50 PM, Christopher Schultz ch...@christopherschultz.net wrote: I'm unaware of a technique to allow partial structural validity (say, element nesting) without also explicitly specifying which attributes are allowed. Wait, what? The OP's example isn't even well-formed XML, and any decent text editor should flag that. Attribute names and values aren't relevant to well-formed-ness. -- Hassan Schroeder hassan.schroe...@gmail.com http://about.me/hassanschroeder twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hassan, On 11/30/12 5:04 PM, Hassan Schroeder wrote: On Fri, Nov 30, 2012 at 1:50 PM, Christopher Schultz ch...@christopherschultz.net wrote: I'm unaware of a technique to allow partial structural validity (say, element nesting) without also explicitly specifying which attributes are allowed. Wait, what? The OP's example isn't even well-formed XML, and any decent text editor should flag that. Attribute names and values aren't relevant to well-formed-ness. OP never posted the whole XML, so we don't know that it's definitely not well-formed. Tomcat definitely bombs if the document isn't well-formed: Nov 30, 2012 5:08:28 PM org.apache.tomcat.util.digester.Digester endElement WARNING: No rules found matching 'Server/Service/Engine/Host/Host'. Nov 30, 2012 5:08:28 PM org.apache.tomcat.util.digester.Digester fatalError SEVERE: Parse Fatal Error at line 152 column 7: The element type Host must be terminated by the matching end-tag /Host. org.xml.sax.SAXParseException; systemId: file:/CATALINA_BASE/conf/server.xml; lineNumber: 152; columnNumber: 7; The element type Host must be terminated by the matching end-tag /Host. at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAX ParseException(ErrorHandlerWrapper.java:198) [] If the OP was using an XML editor (again, without any Schema or DTD), it might have let him (or even auto-fixed the structure to) do this: Service Engine Host Host /Host /Host /Engine /Service This message would have showed up in catalina.out: Nov 30, 2012 5:11:47 PM org.apache.tomcat.util.digester.Digester endElement WARNING: No rules found matching 'Server/Service/Engine/Host/Host'. ...but such a thing is easy to miss. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with undefined - http://www.enigmail.net/ iEYEARECAAYFAlC5L2sACgkQ9CaO5/Lv0PD/1wCgpJIRrwYORoDhSZaxYOx2cG2Z /VgAoLd0WLVjOwohYT+gC1z+AEIq2mTT =kDgf -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
Christopher Schultz wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 André, On 11/30/12 10:11 AM, André Warnier wrote: Jeffrey Janner wrote: -Original Message- From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Sent: Wednesday, November 28, 2012 5:29 PM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Hi! Thanks for your quick and detailed answers. Actually I think I did all the things you mentioned but it still does not work. So here are the changes I made: 1. I checked that the following entries are in the engine tag: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true [Jeff Janner] You need a /Host here. All elements must have a begin tag and an end tag! If there are no sub-elements, you can combine the begin and end tags as tagname ... /. Please find a good introductory reference on XML markup language before continuing. Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host Haaa. Good catch, Jeffrey. Everyone else missed that. +1 So it probably swallowed the second Host's tags in the first, with who knows which results. Surprising that Tomcat still starts. Unfortunately, Tomcat does not validate against an XML schema or DTD and so otherwise insane configurations can generally be launched without any errors being generated. This is a double-edged sword. In this case, it made it difficult to detect a configuration error. In other cases, it makes it possible to use very complex configuration that the Tomcat developers didn't expect beforehand. One reason Tomcat cannot validate against a schema or DTD is because of things like Resource: they allow a user to specify any attribute name and have its value get set on the component being configured. This is not possible with a strictly-validating parser. I'm unaware of a technique to allow partial structural validity (say, element nesting) without also explicitly specifying which attributes are allowed. Use of the Apache commons-digester component means that detecting structural missteps would require that the component be configured with all possible missteps in advance which is quite impossible. I haven't looked, but it might be nice if the digester supported fallback rules where an event that didn't match an existing rule could fire a catch-all rule. That way, an unexpected element could generate an error message and possibly prevent Tomcat from even starting. I wasn't complaining or criticising, just wondering. It isn't so easy to compose an XML document, miss a closing tag and still having it be valid XML. If you go back the the OP's last post and the described symptoms, and assume that he did describe accurately what happened, it means that the missing /Host tag had some really interesting effects. What we really need on this user list, is an interactive XML parser where we can check configuration snippets posted by users. (one which would of course first and automatically get rid of all the email artifacts, in-between comments etc.) - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
On Fri, Nov 30, 2012 at 2:12 PM, Christopher Schultz ch...@christopherschultz.net wrote: OP never posted the whole XML, so we don't know that it's definitely not well-formed. Good point -- should have asked for the whole file before jumping to that conclusion. But it certainly looked sketchy :-) -- Hassan Schroeder hassan.schroe...@gmail.com http://about.me/hassanschroeder twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
Hi. Here is a brief tutorial on how the virtual host thing works. (I find that many times, reminding someone of these basic things helps in diagnosing things quickly). 1) the browser is given a URL to retrieve, say http://myhost.mycompany.com:8080/home.html; 2) the browser parses this URL in : protocol : http hostname : myhost.mycompany.com port : 8080 URI : /home.html (note : if the port is not given, it becomes the default for the protocol; for example, for http this would be 80, and for https it would be 443) 2) the browser first asks it's local O.S. resolver, to translate the hostname into an IP address. The resolver is the part of the OS which does these translations, and usually - it first looks at the local hosts file, to find a name-to-address translation (under Unix/Linux, this is /etc/hosts; under Windows, it is usually (windows_dir)/system32/drivers/etc/hosts ) - if it is not in the local hosts file, it will contact a DNS server host, and ask it to tranalate the address. In a LAN, the DNS host is usually a local DNS server system. Otherwise, it is a DNS server on the Internet. (Note: DNS stands for Domain Name System and is a standard feature on the Internet) 3) if the browser could not get a name-to-address translation, it will print an error message host 'myhost.mycompany.com' could not be found. If the browser received an IP address from the resolver, it believes it unconditionally, even if it happens to be false, and goes to the next step. 4) the browser establishes a TCP connection to the obtained IP address, and the port determined from the URL. If the browser cannot establish this connection, it will print an error message host 'myhost.mycompany.com' is not responding - try again later. (Note: if you get this far, it means at least that the hostname was translated to an IP address in some way. It does not mean that the IP address is correct, but it's a start.) 5) on this established TCP connection, the browser sends a HTTP request, consisting of several lines, as a minimum the following 2 lines : GET /home.html HTTP/1.1 Host: myhost.mycompany.com .. 6) at the receiving end, it is assumed that a webserver has accepted the TCP connection, and is reading what the browser sends on it. It thus reads the request, as a minimum the same 2 lines : GET /home.html HTTP/1.1 Host: myhost.mycompany.com 7) the webserver parses the HTTP request headers, in particular the Host: header. This tells it the name of the virtual host to which this request is addressed. 8) the webserver looks through it's own list of virtual hosts, to find one of which either the hostname or an alias matches the Host: header exactly. 9) If the webserver finds such a virtual host, then it sets itself up so that this request is handled according to the configuration of that virtual host. 10) If the webserver does not find such a virtual host (neither hostname nor alias match any defined virtual host), then it will direct the request to its default virtual host. This varies a bit from webserver to webserver, but - for Tomcat it is the Host named in the Engine tag - for Apache httpd, it is the first VirtualHost named in the httpd configuration Now, I suggest that you go through the above steps, one by one, really thinking about what happens and if it happens, and make sure that you eliminate all the possibilities that do not apply. And as Sherlock Holmes would say, once you have eliminated all the unlikely things, what remains, even if it is impossible, must be the truth. In your case, according to your last post, you send a request with a URL of http:// www.my1rstdomain.com:8080, and you say that the webapp which answers is started in the Host with hostname www.my2nddomain.com. That does /not/ make sense according to the above scenario. So either you are not showing us your real configuration, or you have not restarted Tomcat after making configuration changes, or you are not describing accurately what you are doing. Check again. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Paul, On 11/28/12 6:29 PM, Paul van Hoven wrote: Thanks for your quick and detailed answers. Actually I think I did all the things you mentioned but it still does not work. So here are the changes I made: 1. I checked that the following entries are in the engine tag: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host /Engine /Service /Server This looks correct to me. 2. In the host file I altered the entries to 88.84.140.85 www.my2nddomain.com 88.84.140.85 www.my1rstdomain.com Is this on the server or the client? Or both? Go to the machine you are using as an HTTP client (e.g. web browser) and type this on the command line: nslookup www.my2nddomain.com You should get 88.84.140.85 back. Next, you need to make sure that the client is sending a Host header with the HTTP message. The Host header is required for HTTP/1.1, so if the client is not specifying the Host, it is non-compliant. Tomcat can't determine the virtual host to use if the Host header is absent. If the Host header is absent or the value of Host does not match anything Tomcat has configured, the default Host for the Engine will be used. In your case, it's the localhost host. The current status is that when calling www.my1rstdomain.com:8080 points to the webapp installed for www.my2nddomain.com:8080. That seems very odd, since you don't have any configuration for www.my1rstdomain.com, so you should get the default. What happens when you request www.my2nddomain.com? Can you post an HTTP protocol trace of a request/response? - -chris -BEGIN PGP SIGNATURE- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with undefined - http://www.enigmail.net/ iEYEARECAAYFAlC35rMACgkQ9CaO5/Lv0PBg7wCfbZ5FAYwfrCQfx0vb1KjB3j/2 QxwAnjFvdrNhV+XhxQ+ttDDpOiaJtp3d =EUkh -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
Hi! Thanks for your quick and detailed answers. Actually I think I did all the things you mentioned but it still does not work. So here are the changes I made: 1. I checked that the following entries are in the engine tag: Server port=8005 shutdown=SHUTDOWN ... Service name=Catalina ... Engine name=Catalina defaultHost=localhost Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true Host name=www.my2nddomain.com appBase=/opt/apache-tomcat-7.0.32/my2nddomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host /Engine /Service /Server 2. In the host file I altered the entries to 88.84.140.85www.my2nddomain.com 88.84.140.85www.my1rstdomain.com 3. I actually did not really understand what you meant by Also, since you are using the /etc/hosts file instead of the DNS system, the client (browser) also has those entries in its hosts file. And, as Konstantin pointed out, you don't put the port number in the /etc/hosts file. If you are using DNS for the clients, make sure that it has entries for both hosts, pointing to the same IP address. I'm not shure if I understand the meaning of DNS in this case correctly. Do you mean a DNS on my local machine or do you mean the DNS on a remote machine? I've got a pure domain hoster and I set an A record entry such that the domain is forwarded to my server / ip address 88.84.140.85. Both domains are actually pointing to this ip address since both are hosted by the same domain hoster. I do not explicitly use DNS on my local machine, at least I did not configure it. And how can the client (browser) have entries in a host file? The current status is that when calling www.my1rstdomain.com:8080 points to the webapp installed for www.my2nddomain.com:8080. 2012/11/27 Jeffrey Janner jeffrey.jan...@polydyne.com: -Original Message- From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Sent: Tuesday, November 27, 2012 2:13 PM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Thanks for the answer. I followed the tutorial you propose ( http://wiki.apache.org/tomcat/TomcatDevelopmentVirtualHosts ). But it is still not working. Here is my new configuration server.xml Host name=2nddomain.com appBase=/opt/apache-tomcat-7.0.32/2nddomain.com unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Alias2nddomain.com/Alias Aliaswww.2nddomain.com/Alias /Host The directory /opt/apache-tomcat-7.0.32/2nddomain.com contains a ROOT.war file. I edited the /etc/hosts file and added the following entries: 88.84.140.88 www.2nddomain.com:8080 88.84.140.88 www.1rstdomain.com:8080 Then I restarted the system and the tomcat server. Entering www.2nddomain.com:8080 sends me to 1rstdomain.com. I noticed that the file /opt/apache-tomcat-7.0.32/2nddomain.com/ROOT.war remains untouched by tomcat, at least nothing is extracted from the war file. So what else am I missing here? Make sure that the new Host/Host definition is nested inside the Engine/Engine tags. You also do not need the first Alias line. The name= parameter takes care of that mapping for you. In general, the nesting works this way: Server ... Service ... Connector ... / Connector ... / Engine ... Host name=host1.com ... Aliaswww.host1.com/Alias /Host Host name=www.host2.com ... Aliashost2.com/Alias /Host Host name=www.myhost.com ... / /Engine /Service /Server There are a myriad other tag sets that could be included in there and it's very important that they be nested properly to work properly. Also, since you are using the /etc/hosts file instead of the DNS system, the client (browser) also has those entries in its hosts file. And, as Konstantin pointed out, you don't put the port number in the /etc/hosts file. If you are using DNS for the clients, make sure that it has entries for both hosts, pointing to the same IP address. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
Thanks for the answer. I followed the tutorial you propose ( http://wiki.apache.org/tomcat/TomcatDevelopmentVirtualHosts ). But it is still not working. Here is my new configuration server.xml Host name=2nddomain.com appBase=/opt/apache-tomcat-7.0.32/2nddomain.com unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Alias2nddomain.com/Alias Aliaswww.2nddomain.com/Alias /Host The directory /opt/apache-tomcat-7.0.32/2nddomain.com contains a ROOT.war file. I edited the /etc/hosts file and added the following entries: 88.84.140.88www.2nddomain.com:8080 88.84.140.88www.1rstdomain.com:8080 Then I restarted the system and the tomcat server. Entering www.2nddomain.com:8080 sends me to 1rstdomain.com. I noticed that the file /opt/apache-tomcat-7.0.32/2nddomain.com/ROOT.war remains untouched by tomcat, at least nothing is extracted from the war file. So what else am I missing here? 2012/11/22 Caldarale, Charles R chuck.caldar...@unisys.com: From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Subject: Tomcat with multiple domains I found the following tutorial (very old) on the web: http://onjava.com/pub/a/onjava/2006/08/30/publishing-multiple-sites-using-single-tomcat.html Probably best to completely ignore anything that old. I payed attention to the offical Tomcat documentation in regard of this: http://tomcat.apache.org/tomcat-7.0-doc/virtual-hosting-howto.html That's good to look at, as is this: http://wiki.apache.org/tomcat/HowTo#How_do_I_set_up_Tomcat_virtual_hosts_in_a_development_environment.3F The steps apply to production as well as development. In my $CATALINA_HOME (which is /opt/apache-tomcat-7.0.32) I created the folder my2ndDomain This is only speculation (too lazy to look at the code right now), but domain names are defined to be case-insensitive, and typically presented only in lower case. What happens if you change my2ndDomain to my2nddomain everywhere? Context path=my2ndDomain debug=0 reloadable=false/ The above is really, really bad. You shouldn't be putting Context elements in server.xml, and besides, the contents of that one are gibberish. What did you expect to achieve with it? - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Tomcat with multiple domains
2012/11/28 Paul van Hoven paul.van.ho...@googlemail.com: I edited the /etc/hosts file and added the following entries: 88.84.140.88www.2nddomain.com:8080 88.84.140.88www.1rstdomain.com:8080 Domain Name Service resolves host names. A port number is not part of a host name. The above two lines are invalid. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat with multiple domains
-Original Message- From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Sent: Tuesday, November 27, 2012 2:13 PM To: Tomcat Users List Subject: Re: Tomcat with multiple domains Thanks for the answer. I followed the tutorial you propose ( http://wiki.apache.org/tomcat/TomcatDevelopmentVirtualHosts ). But it is still not working. Here is my new configuration server.xml Host name=2nddomain.com appBase=/opt/apache-tomcat-7.0.32/2nddomain.com unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Alias2nddomain.com/Alias Aliaswww.2nddomain.com/Alias /Host The directory /opt/apache-tomcat-7.0.32/2nddomain.com contains a ROOT.war file. I edited the /etc/hosts file and added the following entries: 88.84.140.88 www.2nddomain.com:8080 88.84.140.88 www.1rstdomain.com:8080 Then I restarted the system and the tomcat server. Entering www.2nddomain.com:8080 sends me to 1rstdomain.com. I noticed that the file /opt/apache-tomcat-7.0.32/2nddomain.com/ROOT.war remains untouched by tomcat, at least nothing is extracted from the war file. So what else am I missing here? Make sure that the new Host/Host definition is nested inside the Engine/Engine tags. You also do not need the first Alias line. The name= parameter takes care of that mapping for you. In general, the nesting works this way: Server ... Service ... Connector ... / Connector ... / Engine ... Host name=host1.com ... Aliaswww.host1.com/Alias /Host Host name=www.host2.com ... Aliashost2.com/Alias /Host Host name=www.myhost.com ... / /Engine /Service /Server There are a myriad other tag sets that could be included in there and it's very important that they be nested properly to work properly. Also, since you are using the /etc/hosts file instead of the DNS system, the client (browser) also has those entries in its hosts file. And, as Konstantin pointed out, you don't put the port number in the /etc/hosts file. If you are using DNS for the clients, make sure that it has entries for both hosts, pointing to the same IP address. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Tomcat with multiple domains
Hi! I'm trying to setup virtual hosts for my single tomcat webserver. I've got the following setup: Apache Tomcat 7.0.32 running on a server with one IP address. I forward any requests coming in on port 80 to port 8080 and from 443 to 8443 with a firewall rule. I have 2 domains and I would like to run these two domains on the same Tomcat machine. Therefore I had a look at the virtual host concept. I found the following tutorial (very old) on the web: http://onjava.com/pub/a/onjava/2006/08/30/publishing-multiple-sites-using-single-tomcat.html and I payed attention to the offical Tomcat documentation in regard of this: http://tomcat.apache.org/tomcat-7.0-doc/virtual-hosting-howto.html So I made the following: 1. In my $CATALINA_HOME (which is /opt/apache-tomcat-7.0.32) I created the folder my2ndDomain 2. Then I copied the war file I'd like to deploy into the folder and renamed it. Such that now I have the following file in my folder /opt/apache-tomcat-7.0.32/my2ndDomain/ROOT.war 3. Then I modified my /opt/apache-tomcat-7.0.32/conf/server.xml the following way: Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true Host name=wettprofi appBase=my2ndDomain unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Aliasmy2ndDomain.com/Alias Aliaswww.my2ndDomain.com/Alias Context path=my2ndDomain debug=0 reloadable=false/ /Host 4. I restarted my Tomcat but nothing happened, entering www.my2ndDomain.com was routed to the standard first domain running. I'm wondering what I am doing wrong here. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Tomcat with multiple domains
From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Subject: Tomcat with multiple domains I found the following tutorial (very old) on the web: http://onjava.com/pub/a/onjava/2006/08/30/publishing-multiple-sites-using-single-tomcat.html Probably best to completely ignore anything that old. I payed attention to the offical Tomcat documentation in regard of this: http://tomcat.apache.org/tomcat-7.0-doc/virtual-hosting-howto.html That's good to look at, as is this: http://wiki.apache.org/tomcat/HowTo#How_do_I_set_up_Tomcat_virtual_hosts_in_a_development_environment.3F The steps apply to production as well as development. In my $CATALINA_HOME (which is /opt/apache-tomcat-7.0.32) I created the folder my2ndDomain This is only speculation (too lazy to look at the code right now), but domain names are defined to be case-insensitive, and typically presented only in lower case. What happens if you change my2ndDomain to my2nddomain everywhere? Context path=my2ndDomain debug=0 reloadable=false/ The above is really, really bad. You shouldn't be putting Context elements in server.xml, and besides, the contents of that one are gibberish. What did you expect to achieve with it? - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Splitting Content Across Multiple Domains
On 19/10/2010 03:49, Caldarale, Charles R wrote: From: Ðavîd Låndïs [mailto:dlan...@gmail.com] Subject: Splitting Content Across Multiple Domains I am considering creating another Host in my Tomcat server and creating another .war file with static content for that additional host. So the links to static content generated by my primary application will point to the domain name of this new host. Here is an article discussing this general technique: http://www.yuiblog.com/blog/2007/04/11/performance-research-part-4/ I think you may be wasting your time. Have you determined that you actually have a performance problem, or are you fixing a non-existent problem? The cited article is over three years old, and since then all of the popular browsers have increased their default for the number of parallel connections to something larger than two - usually six. I'd suggest just putting things back the way they were, so your images are automatically protected by the main logon. And I'm not sure what actual performance gain you'd get from hosting it on the same IP address. From memory, my experience was that the performance gain was barely detectable and only occurred when the app was on a separate IP address. Have you configured the Tomcat native (APR) component? That'll give you improved performance, if it's an issue. p 0x62590808.asc Description: application/pgp-keys signature.asc Description: OpenPGP digital signature
Re: Splitting Content Across Multiple Domains
On Mon, Oct 18, 2010 at 10:49 PM, Caldarale, Charles R chuck.caldar...@unisys.com wrote: I think you may be wasting your time. Have you determined that you actually have a performance problem, or are you fixing a non-existent problem? I don't expect the technique to make that much difference on its own, but it's an architecture that seems like it would better facilitate creating a cookie-free domain as well as eventually migrating to a CDN. But I guess that's part of my problem, I haven't been able to find any information on splitting content across multiple domains while still protecting the stuff that is outside the primary app. And don't worry I don't want to do anything too crazy with hacking jsession Ids I'm more just wondering if there is a legitimate way to actually accomplish this on Tomcat. The cited article is over three years old, and since then all of the popular browsers have increased their default for the number of parallel connections to something larger than two - usually six. I'd suggest just putting things back the way they were, so your images are automatically protected by the main logon. Yes you are right, here is a handy site listing the differences between some of the browsers we are supporting: http://www.browserscope.org/?category=networkv=1ua=Chrome%205,Chrome%206,Firefox%202,Firefox%203,IE%206,IE%207,IE%208,Safari%204,Safari%205 And in the business world as I'm sure you know, popular still means IE 6 and IE 7. Anyway I am just investigating the technique at this point, thanks for your response. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Splitting Content Across Multiple Domains
On Tue, Oct 19, 2010 at 7:35 AM, Pid p...@pidster.com wrote: And I'm not sure what actual performance gain you'd get from hosting it on the same IP address. From memory, my experience was that the performance gain was barely detectable and only occurred when the app was on a separate IP address. Hmm, interesting. I think in theory at least it shouldn't matter if it's on the same IP unless the increased load offset any gains made with the parallelization of the downloads. In any case once I had everything split up I think then it would be easy to add more IP's into the mix as needed. Also I did find a newer article from Google that recommends this technique: http://code.google.com/intl/en/speed/page-speed/docs/rtt.html#ParallelizeDownloads If your pages serve large numbers of static resources, such as images, from a single hostname, consider splitting them across multiple hostnames using DNS aliases. We recommend this technique for any page that serves more than 10 resources from a single host. But yes your point is taken that probably there are more important optimizations to make at this point. Have you configured the Tomcat native (APR) component? That'll give you improved performance, if it's an issue. That is on my very short list of things to do, thanks. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Splitting Content Across Multiple Domains
I am considering creating another Host in my Tomcat server and creating another .war file with static content for that additional host. So the links to static content generated by my primary application will point to the domain name of this new host. Here are the two hostnames for example: app.example.com static1.example.com Here is an article discussing this general technique (not Tomcat specific): http://www.yuiblog.com/blog/2007/04/11/performance-research-part-4/ Creating the new Host elements is no problem and creating new DNS aliases that refer to those Hosts is also no problem. My issue is that my application requires a login and I only want to expose those static resources to someone who has logged into the primary application. Does anyone have any recommendations on how to accomplish that? Or is this the wrong approach entirely? One thing I thought might be possible would be to append a session Id onto the url's of the images located on the static content host and then just create a Filter that would check that id somehow. That's pretty much as far as I've got; any advice would be appreciated. Thanks. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Multiple Domains on one Tomcat Server now MySQL not working
Hi Chuck, thanks for this detailed answer. I'm running tomcat 6 on an ubuntu server. I read the official documentation and modified the configuration of my tomcat. The complete current server.xml (without comments and after my latest modification) looks like this: server.xml: Server port=8005 shutdown=SHUTDOWN Listener className=org.apache.catalina.core.AprLifecycleListener SSLEngine=on / Listener className=org.apache.catalina.core.JasperListener / Listener className=org.apache.catalina.mbeans.ServerLifecycleListener / Listener className=org.apache.catalina.mbeans.GlobalResourcesLifecycleListener / GlobalNamingResources 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 Connector port=8080 protocol=HTTP/1.1 connectionTimeout=2 redirectPort=8443 / Connector port=8009 protocol=AJP/1.3 redirectPort=8443 / Engine name=Catalina defaultHost=localhost Realm className=org.apache.catalina.realm.UserDatabaseRealm resourceName=UserDatabase/ Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host Host name=localhost.localdomain debug=0 appBase=webapps2 unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Aliaswww.clubpirat.de/Alias /Host /Engine /Service /Server I checked that in /etc/hosts the two domains localhost and localhost.localdomain are assigned to 127.0.0.1. Now, i have the following directory structure: CATALINA_HOME/webapps CATALINA_HOME/webapps2 CATALINA_HOME/conf/Catalina/localhost CATALINA_HOME/conf/Catalina/localhost.localdomain CATALINA_HOME/webapps2/ROOT/META-INF In CATALINA_HOME/conf/Catalina/localhost.localdomain i got the following files: ROOT.xml log4j_errors.log manager.xml And the latter ROOT.xml looks like this: ?xml version='1.0' encoding='utf-8'? Context displayName=localhost.localdomain workDir=work/Catalina/clubpirat.de/_ /Context I also copied my war file into the CATALINA_HOME/webapps2 directory and tomcat has deploied the file. Okay, i when enter the url www.clubpirat.de but i get an 404 error. The other url works fine, no problems. Caldarale, Charles R schrieb: From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Subject: Multiple Domains on one Tomcat Server now MySQL not working I'm not shure if this problem really relates to Tomcat but it happened after altering the tomcat configuration. Care to give us a hint about version of Tomcat you're using? Configuration is different from level to level. Therefore i search on the internet how to manage multiple domains on Tomcat. Might be better to read the real documentation first: http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html http://tomcat.apache.org/tomcat-5.5-doc/virtual-hosting-howto.html I found this resource: http://www.westsoftware.net/java/domains-on-tomcat.jsp. It's unfortunate you found that, since it's chock full of errors. Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host Host name=mydomain.de debug=0 appBase=webapps/myapp2 The above is not good; the different appBase directories must be distinct, not one under another. unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Logger className=org.apache.catalina.logger.FileLogger directory=logs prefix=mydomain.de-log. suffix=.txt timestamp=true/ Logger elements have not been used in Tomcat for some years. Aliaswww.mydomain.de/Alias /Host /Engine /Service /Server and i added the follwing ROOT.xml file in the folder $CATALINA_HOME/conf/Catalina/mydomain.de ROOT.xml: ?xml version='1.0' encoding='utf-8'? Context displayName=mydomain.de docBase= path= workDir=work/Catalina/mydomain.de/_ /Context Both the docBase and path attributes have invalid values; luckily, neither one is allowed here, and they are hopefully being ignored. Actually it works fine, i can now differentiate between the two webapps by the domain. What two webapps? You have only shown us one Context element. But while the first webapp has no problems accessing the mysql database i do have problems with the second webapp for which i added the new configuration. What's the first webapp? What Resource
Re: Multiple Domains on one Tomcat Server now MySQL not working
On Mon, Oct 12, 2009 at 11:40 PM, Paul van Hoven paul.van.ho...@googlemail.com wrote: Host name=localhost.localdomain ... Aliaswww.clubpirat.de/Alias I checked that in /etc/hosts the two domains localhost and localhost.localdomain are assigned to 127.0.0.1. Okay, i when enter the url www.clubpirat.de but i get an 404 error. And does www.clubpirat.de resolve to your local computer? Either through an entry in /etc/hosts or DNS? -- Hassan Schroeder hassan.schroe...@gmail.com twitter: @hassan - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Multiple Domains on one Tomcat Server now MySQL not working
Hi Hassan, yeah, acutually that was the problem, I just discovered it an instant before you answered me :). I made the appropriate changes and now it is working fine. Thanks for your answer anyway. Tom Hassan Schroeder schrieb: On Mon, Oct 12, 2009 at 11:40 PM, Paul van Hoven paul.van.ho...@googlemail.com wrote: Host name=localhost.localdomain ... Aliaswww.clubpirat.de/Alias I checked that in /etc/hosts the two domains localhost and localhost.localdomain are assigned to 127.0.0.1. Okay, i when enter the url www.clubpirat.de but i get an 404 error. And does www.clubpirat.de resolve to your local computer? Either through an entry in /etc/hosts or DNS? - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Multiple Domains on one Tomcat Server now MySQL not working
I'm not shure if this problem really relates to Tomcat but it happened after altering the tomcat configuration. I've two different domains for two differnt webapps. Therefore i search on the internet how to manage multiple domains on Tomcat. I found this resource: http://www.westsoftware.net/java/domains-on-tomcat.jsp. I modified the corrensponding configuration file in the following way: Extract server.xml: ... Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host Host name=mydomain.de debug=0 appBase=webapps/myapp2 unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Logger className=org.apache.catalina.logger.FileLogger directory=logs prefix=mydomain.de-log. suffix=.txt timestamp=true/ Aliaswww.mydomain.de/Alias /Host /Engine /Service /Server and i added the follwing ROOT.xml file in the folder $CATALINA_HOME/conf/Catalina/mydomain.de ROOT.xml: ?xml version='1.0' encoding='utf-8'? Context displayName=mydomain.de docBase= path= workDir=work/Catalina/mydomain.de/_ /Context Actually it works fine, i can now differentiate between the two webapps by the domain. But while the first webapp has no problems accessing the mysql database i do have problems with the second webapp for which i added the new configuration. The problem that i have now: I don't know what is happening here. I already checked the log files in the CATALINA_HOME/logs folder but i could not find anything. I also checked that the mysql connection for the second webapp works when invoking it by www.regulardomain.de/myapp2. Has anybody an idea what could cause this problem? - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Multiple Domains on one Tomcat Server now MySQL not working
From: Paul van Hoven [mailto:paul.van.ho...@googlemail.com] Subject: Multiple Domains on one Tomcat Server now MySQL not working I'm not shure if this problem really relates to Tomcat but it happened after altering the tomcat configuration. Care to give us a hint about version of Tomcat you're using? Configuration is different from level to level. Therefore i search on the internet how to manage multiple domains on Tomcat. Might be better to read the real documentation first: http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html http://tomcat.apache.org/tomcat-5.5-doc/virtual-hosting-howto.html I found this resource: http://www.westsoftware.net/java/domains-on-tomcat.jsp. It's unfortunate you found that, since it's chock full of errors. Host name=localhost appBase=webapps unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false /Host Host name=mydomain.de debug=0 appBase=webapps/myapp2 The above is not good; the different appBase directories must be distinct, not one under another. unpackWARs=true autoDeploy=true xmlValidation=false xmlNamespaceAware=false Logger className=org.apache.catalina.logger.FileLogger directory=logs prefix=mydomain.de-log. suffix=.txt timestamp=true/ Logger elements have not been used in Tomcat for some years. Aliaswww.mydomain.de/Alias /Host /Engine /Service /Server and i added the follwing ROOT.xml file in the folder $CATALINA_HOME/conf/Catalina/mydomain.de ROOT.xml: ?xml version='1.0' encoding='utf-8'? Context displayName=mydomain.de docBase= path= workDir=work/Catalina/mydomain.de/_ /Context Both the docBase and path attributes have invalid values; luckily, neither one is allowed here, and they are hopefully being ignored. Actually it works fine, i can now differentiate between the two webapps by the domain. What two webapps? You have only shown us one Context element. But while the first webapp has no problems accessing the mysql database i do have problems with the second webapp for which i added the new configuration. What's the first webapp? What Resource elements have you defined, and where are they? You might want to post your complete server.xml and all Context elements. - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Hosting multiple domains on a single application
Hey, I have a webapplication with different pages for each client which is accessible from URL www.myDomain.com/action/clientId client Id is different for each client. Now I want to provide different domains to these clients and want to map them to these URLs.. So that www.domain1.com automatically hit my application at www.myDomain.com/action/client1 www.domain2.com automatically hit my application at www.myDomain.com/action/client2 and in the browser the URL should be www.domain1.com only. can any body tell me what should be the process to handle such mapping. Thanks in advance. Regards Vikas Garg -- View this message in context: http://www.nabble.com/Hosting-multiple-domains-on-a-single-application-tp25220862p25220862.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
RE: Hosting multiple domains on a single application
From: mailvgarg [mailto:mailvg...@gmail.com] Subject: Hosting multiple domains on a single application can any body tell me what should be the process to handle such mapping. Try this: http://tuckey.org/urlrewrite/ - 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 unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: Hosting multiple domains on a single application
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Vikas, On 8/31/2009 5:53 AM, mailvgarg wrote: I have a webapplication with different pages for each client which is accessible from URL www.myDomain.com/action/clientId client Id is different for each client. Now I want to provide different domains to these clients and want to map them to these URLs.. So that www.domain1.com automatically hit my application at www.myDomain.com/action/client1 www.domain2.com automatically hit my application at www.myDomain.com/action/client2 Other than Chuck's suggestion to use the Tuckey's venerable url-rewrite, you could also deploy your webapps differently, like this: Host name=www.domain1.com appBase=./domain1 / Host name=www.domain2.com appBase=./domain2 / Host name=www.domain3.com appBase=./domain3 / ...and then deploy your webapp into each of the appBase directories as the ROOT webapp. Of course, each one would need to be configured to act as the appropriate webapp for that client id. I'm not sure how complicated that would be for you. - -chris -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkqb4TIACgkQ9CaO5/Lv0PBJ8ACdHO/O4JeQi41JvpZ0DwkV2lyX Jk4An0baSPLJOXG4NSYDFC/rMGj60EcT =J7ra -END PGP SIGNATURE- - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
how do i configure multiple domains in one tomcat inatance
hi, I am using apache http server, openSSL, mod_jk and tomcat 5.5.9 on solaris 10 server. I need a way to create multiple domains in the same tomcat instance or server. for example i should be able to copy my war files into two dirs dir1 and dir2. Same Tomcat should be able to pickup applications and host them from both the directories. I know that this is possible in Weblogic but not sure how to implement this in tomcat. Sincerely, Srinivas Jonnalagadda - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
Re: how do i configure multiple domains in one tomcat inatance
Srinivas Jonnalagadda wrote: hi, I am using apache http server, openSSL, mod_jk and tomcat 5.5.9 on solaris 10 server. I need a way to create multiple domains in the same tomcat instance or server. for example i should be able to copy my war files into two dirs dir1 and dir2. Same Tomcat should be able to pickup applications and host them from both the directories. I know that this is possible in Weblogic but not sure how to implement this in tomcat. This is for 6 but should gove you the idea. http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html Mark - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org
How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Hi. This is a simple question (i think) After playing with server,xml (and various other .xml files) I am unable to work out how to host multiple domains on a Tomcat 6 (standalone) server (running on port 80) .. I have read - http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html I.e - I have uploaded 2 contexts /mrpink /mrblue - mrpink was uploaded first (as root context). - I have 2 domains www.mrpink.com www.mrblue.com - both domains point to the same ip (tomcat server) - however when visiting both sites they go to the ROOT context. - I want www.mrpink.com to go to www.mrpink.com/mrpink and www.mrblue.comto go to www.mrblue.com/mrblue - how is this possible ? Please note : that both contexts are fine when you put the URL in (i.e www.mrpink.com/mrpink) - I just want Tomcat to understand when you visit www.mrpink.com to automatically goes to www.mrpink.com/mrpink I have tried editing server.xml (as shown in above link) also tried using the tomcat host-manager - every time I try to use this I get file/folder not found when visiting the page - i.e the host-manager seems to work fine but visiting the page after adding a virtual host i get a blank page (in firefox) - file/folder not found in konqueror Here is an example I tried - to get www.mrblue.com to point to www.mrblue.com/mrblue using the host-manager - First I uploaded the mrblue tomcat application using the tomcat manager.. Using host-manager ... www.mrpink.com/host-manager/html name : mrblue.com alias : www.mrblue.com app base : /opt/tomcat/webapps/mrblue/ The webapp is located in - /opt/tomcat/webapps/mrblue/ I understand I can do what I want using mod_jk - however it seems crazy using apache when I do not really need to ... Can anyone help - its slowly driving me mad.. Cheers
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Can you tell us on what kind of host system you are running this ? It would help guessing where the files are. Thanks. P.S. I am not the expert, but it should indeed be relatively simple, so I'll try. In a nutshell : - start again from the original server.xml file. - in it, locate the Host name=localhost ./Host section, copy it, and re-insert it after the original section. - then replace the name=localhost attribute by name=www.mrpink.com - then redo the same one more time, this time with www.mrblue.com The above takes care of letting Tomcat known that there are 3 Virtual Hosts : - www.mrpink.com - www.mrblue.com - and localhost, which will also be (remain) the Host by default, if the name given in the request does not match either of the other ones (for example, if someone calls up http://xxx.xxx.xxx.xxx:8180 (with the IP address of your server). (I suggest to keep that one as it is, to access the documentation etc..) Now what is left is to tell Tomcat where, for each of the virtual hosts, he finds the corresponding documents and webapps. I would recommend to create 2 additional directories, at the same level as your current webapps, say webapps-pink and webapps-blue. Then move the respective documents/applications in these directories, checking ownership and permissions etc.. They must at least be readable by the user-id running Tomcat. Now go back to your individual Hosts sections, and change appBase=webapps by appBase=webapps-pink and appBase=webapps-blue Now restart Tomcat. You should now be able to access blue by calling up http://www.mrblue.com/mrblue;. To make this trailing /mrblue go away, you should make this webapp into the ROOT webapp for that virtual server, but for that I'll let an expert give you the instructions. Have I got it right ? Morgan Cox wrote: Hi. This is a simple question (i think) After playing with server,xml (and various other .xml files) I am unable to work out how to host multiple domains on a Tomcat 6 (standalone) server (running on port 80) .. I have read - http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html I.e - I have uploaded 2 contexts /mrpink /mrblue - mrpink was uploaded first (as root context). - I have 2 domains www.mrpink.com www.mrblue.com - both domains point to the same ip (tomcat server) - however when visiting both sites they go to the ROOT context. - I want www.mrpink.com to go to www.mrpink.com/mrpink and www.mrblue.comto go to www.mrblue.com/mrblue - how is this possible ? Please note : that both contexts are fine when you put the URL in (i.e www.mrpink.com/mrpink) - I just want Tomcat to understand when you visit www.mrpink.com to automatically goes to www.mrpink.com/mrpink I have tried editing server.xml (as shown in above link) also tried using the tomcat host-manager - every time I try to use this I get file/folder not found when visiting the page - i.e the host-manager seems to work fine but visiting the page after adding a virtual host i get a blank page (in firefox) - file/folder not found in konqueror Here is an example I tried - to get www.mrblue.com to point to www.mrblue.com/mrblue using the host-manager - First I uploaded the mrblue tomcat application using the tomcat manager.. Using host-manager ... www.mrpink.com/host-manager/html name : mrblue.com alias : www.mrblue.com app base : /opt/tomcat/webapps/mrblue/ The webapp is located in - /opt/tomcat/webapps/mrblue/ I understand I can do what I want using mod_jk - however it seems crazy using apache when I do not really need to ... Can anyone help - its slowly driving me mad.. Cheers - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Hi. It is on an Ubuntu Gutsy server.. As mentioned the tomcat applications are working I can just figure out to point domains at the contexts.. cheers 2008/9/26 André Warnier [EMAIL PROTECTED] Can you tell us on what kind of host system you are running this ? It would help guessing where the files are. Thanks. P.S. I am not the expert, but it should indeed be relatively simple, so I'll try. In a nutshell : - start again from the original server.xml file. - in it, locate the Host name=localhost ./Host section, copy it, and re-insert it after the original section. - then replace the name=localhost attribute by name=www.mrpink.com - then redo the same one more time, this time with www.mrblue.com The above takes care of letting Tomcat known that there are 3 Virtual Hosts : - www.mrpink.com - www.mrblue.com - and localhost, which will also be (remain) the Host by default, if the name given in the request does not match either of the other ones (for example, if someone calls up http://xxx.xxx.xxx.xxx:8180 (with the IP address of your server). (I suggest to keep that one as it is, to access the documentation etc..) Now what is left is to tell Tomcat where, for each of the virtual hosts, he finds the corresponding documents and webapps. I would recommend to create 2 additional directories, at the same level as your current webapps, say webapps-pink and webapps-blue. Then move the respective documents/applications in these directories, checking ownership and permissions etc.. They must at least be readable by the user-id running Tomcat. Now go back to your individual Hosts sections, and change appBase=webapps by appBase=webapps-pink and appBase=webapps-blue Now restart Tomcat. You should now be able to access blue by calling up http://www.mrblue.com/mrblue;. To make this trailing /mrblue go away, you should make this webapp into the ROOT webapp for that virtual server, but for that I'll let an expert give you the instructions. Have I got it right ? Morgan Cox wrote: Hi. This is a simple question (i think) After playing with server,xml (and various other .xml files) I am unable to work out how to host multiple domains on a Tomcat 6 (standalone) server (running on port 80) .. I have read - http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html I.e - I have uploaded 2 contexts /mrpink /mrblue - mrpink was uploaded first (as root context). - I have 2 domains www.mrpink.com www.mrblue.com - both domains point to the same ip (tomcat server) - however when visiting both sites they go to the ROOT context. - I want www.mrpink.com to go to www.mrpink.com/mrpink and www.mrblue.comto go to www.mrblue.com/mrblue - how is this possible ? Please note : that both contexts are fine when you put the URL in (i.e www.mrpink.com/mrpink) - I just want Tomcat to understand when you visit www.mrpink.com to automatically goes to www.mrpink.com/mrpink I have tried editing server.xml (as shown in above link) also tried using the tomcat host-manager - every time I try to use this I get file/folder not found when visiting the page - i.e the host-manager seems to work fine but visiting the page after adding a virtual host i get a blank page (in firefox) - file/folder not found in konqueror Here is an example I tried - to get www.mrblue.com to point to www.mrblue.com/mrblue using the host-manager - First I uploaded the mrblue tomcat application using the tomcat manager.. Using host-manager ... www.mrpink.com/host-manager/html name : mrblue.com alias : www.mrblue.com app base : /opt/tomcat/webapps/mrblue/ The webapp is located in - /opt/tomcat/webapps/mrblue/ I understand I can do what I want using mod_jk - however it seems crazy using apache when I do not really need to ... Can anyone help - its slowly driving me mad.. Cheers - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Sorry - didn't see your complete response... http://www.mrblue.com/mrblu http://www.mrblue.com/mrbluee - already goes to the mrblue context - i want http://www.mrblue.comhttp://www.mrblue.com/mrblueto go the mrblue context. Thanks for the advise - it seems that I do need to set the ROOT webapp for each virtual server - anyone got any ideas of how to do this. Thanks for your response André Cheers 2008/9/26 Morgan Cox [EMAIL PROTECTED] Hi. It is on an Ubuntu Gutsy server.. As mentioned the tomcat applications are working I can just figure out to point domains at the contexts.. cheers 2008/9/26 André Warnier [EMAIL PROTECTED] Can you tell us on what kind of host system you are running this ? It would help guessing where the files are. Thanks. P.S. I am not the expert, but it should indeed be relatively simple, so I'll try. In a nutshell : - start again from the original server.xml file. - in it, locate the Host name=localhost ./Host section, copy it, and re-insert it after the original section. - then replace the name=localhost attribute by name=www.mrpink.com - then redo the same one more time, this time with www.mrblue.com The above takes care of letting Tomcat known that there are 3 Virtual Hosts : - www.mrpink.com - www.mrblue.com - and localhost, which will also be (remain) the Host by default, if the name given in the request does not match either of the other ones (for example, if someone calls up http://xxx.xxx.xxx.xxx:8180 (with the IP address of your server). (I suggest to keep that one as it is, to access the documentation etc..) Now what is left is to tell Tomcat where, for each of the virtual hosts, he finds the corresponding documents and webapps. I would recommend to create 2 additional directories, at the same level as your current webapps, say webapps-pink and webapps-blue. Then move the respective documents/applications in these directories, checking ownership and permissions etc.. They must at least be readable by the user-id running Tomcat. Now go back to your individual Hosts sections, and change appBase=webapps by appBase=webapps-pink and appBase=webapps-blue Now restart Tomcat. You should now be able to access blue by calling up http://www.mrblue.com/mrblue;. To make this trailing /mrblue go away, you should make this webapp into the ROOT webapp for that virtual server, but for that I'll let an expert give you the instructions. Have I got it right ? Morgan Cox wrote: Hi. This is a simple question (i think) After playing with server,xml (and various other .xml files) I am unable to work out how to host multiple domains on a Tomcat 6 (standalone) server (running on port 80) .. I have read - http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html I.e - I have uploaded 2 contexts /mrpink /mrblue - mrpink was uploaded first (as root context). - I have 2 domains www.mrpink.com www.mrblue.com - both domains point to the same ip (tomcat server) - however when visiting both sites they go to the ROOT context. - I want www.mrpink.com to go to www.mrpink.com/mrpink and www.mrblue.comto go to www.mrblue.com/mrblue - how is this possible ? Please note : that both contexts are fine when you put the URL in (i.e www.mrpink.com/mrpink) - I just want Tomcat to understand when you visit www.mrpink.com to automatically goes to www.mrpink.com/mrpink I have tried editing server.xml (as shown in above link) also tried using the tomcat host-manager - every time I try to use this I get file/folder not found when visiting the page - i.e the host-manager seems to work fine but visiting the page after adding a virtual host i get a blank page (in firefox) - file/folder not found in konqueror Here is an example I tried - to get www.mrblue.com to point to www.mrblue.com/mrblue using the host-manager - First I uploaded the mrblue tomcat application using the tomcat manager.. Using host-manager ... www.mrpink.com/host-manager/html name : mrblue.com alias : www.mrblue.com app base : /opt/tomcat/webapps/mrblue/ The webapp is located in - /opt/tomcat/webapps/mrblue/ I understand I can do what I want using mod_jk - however it seems crazy using apache when I do not really need to ... Can anyone help - its slowly driving me mad.. Cheers - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Morgan Cox wrote: Sorry - didn't see your complete response... http://www.mrblue.com/mrblu http://www.mrblue.com/mrbluee - already goes to the mrblue context - i want http://www.mrblue.comhttp://www.mrblue.com/mrblueto go the mrblue context. Thanks for the advise - it seems that I do need to set the ROOT webapp for each virtual server - anyone got any ideas of how to do this. Rename $CATALINA_BASE\webapps-blue\mrblue ro $CATALINA_BASE\webapps-blue\ROOT Note that each virtual host must have its own appBase. Mark - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
From: Morgan Cox [mailto:[EMAIL PROTECTED] Subject: Re: How to have multiple domains/contexts with Tomcat ? they all go to same context .. Thanks for the advise - it seems that I do need to set the ROOT webapp for each virtual server - anyone got any ideas of how to do this. Read *all* of Andre's post - he already told you, in great detail, exactly how to do it. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Thanks to everybody whos responded. I shall try these suggestions and let you know how it goes.. 2008/9/26 Caldarale, Charles R [EMAIL PROTECTED] From: Morgan Cox [mailto:[EMAIL PROTECTED] Subject: Re: How to have multiple domains/contexts with Tomcat ? they all go to same context .. Thanks for the advise - it seems that I do need to set the ROOT webapp for each virtual server - anyone got any ideas of how to do this. Read *all* of Andre's post - he already told you, in great detail, exactly how to do it. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Caldarale, Charles R wrote: From: Morgan Cox [mailto:[EMAIL PROTECTED] Subject: Re: How to have multiple domains/contexts with Tomcat ? they all go to same context .. Thanks for the advise - it seems that I do need to set the ROOT webapp for each virtual server - anyone got any ideas of how to do this. Read *all* of Andre's post - he already told you, in great detail, exactly how to do it. Well, not really about making them the ROOT application. So I'll try that one too, but someone should probably come after me to clean up. Morgan, if you followed the previous instructions, you now have this directory structure : (CATALINA_HOME being the top of your Tomcat installation) CATALINA_HOME/webapps (with the standard webapps and documents from the original Tomcat installation) CATALINA_HOME/webapps-pink/mrpink/ with your pink webapp CATALINA_HOME/webapps-blue/mrblue/ with your blue webapp Turn off Tomcat. Under /webapps-pink/, rename the directory /mrpink to /ROOT (uppercase). Under /webapps-blue/, rename the directory /mrblue to /ROOT (uppercase). And restart Tomcat. And unless someone contradicts the above within the next 15 minutes, you should now be able to access your applications directly via http://www.mrpink.com[:port] and http://www.mrblue.com[:port] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Hi André - between yours and Mark's advice I have managed to do what i needed to. Thank you all - i'm amazed at the level of response... (half expected to look in a month and see no responses.) One last thing - If you upload the .war files with the tomcat manager / host-manager is there a way to do this - or will it always involve hand editing the server.xml file (and renaming directories). ? Thanks again everybody - you've possible just saved my monitor from being throw out the window. Cheers ! 2008/9/26 André Warnier [EMAIL PROTECTED] Caldarale, Charles R wrote: From: Morgan Cox [mailto:[EMAIL PROTECTED] Subject: Re: How to have multiple domains/contexts with Tomcat ? they all go to same context .. Thanks for the advise - it seems that I do need to set the ROOT webapp for each virtual server - anyone got any ideas of how to do this. Read *all* of Andre's post - he already told you, in great detail, exactly how to do it. Well, not really about making them the ROOT application. So I'll try that one too, but someone should probably come after me to clean up. Morgan, if you followed the previous instructions, you now have this directory structure : (CATALINA_HOME being the top of your Tomcat installation) CATALINA_HOME/webapps (with the standard webapps and documents from the original Tomcat installation) CATALINA_HOME/webapps-pink/mrpink/ with your pink webapp CATALINA_HOME/webapps-blue/mrblue/ with your blue webapp Turn off Tomcat. Under /webapps-pink/, rename the directory /mrpink to /ROOT (uppercase). Under /webapps-blue/, rename the directory /mrblue to /ROOT (uppercase). And restart Tomcat. And unless someone contradicts the above within the next 15 minutes, you should now be able to access your applications directly via http://www.mrpink.com[:port] and http://www.mrblue.com[:port] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Morgan Cox wrote: Hi André - between yours and Mark's advice I have managed to do what i needed to. Thank you all - i'm amazed at the level of response... (half expected to look in a month and see no responses.) One last thing - If you upload the .war files with the tomcat manager / host-manager is there a way to do this - or will it always involve hand editing the server.xml file (and renaming directories). ? You'll need to configure the manager webapp for each virtual host. See the end of http://tomcat.apache.org/tomcat-6.0-doc/virtual-hosting-howto.html Once you have done that, if you upload a file called ROOT.war it will be treated as the ROOT application. Mark - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
From: Morgan Cox [mailto:[EMAIL PROTECTED] Subject: Re: How to have multiple domains/contexts with Tomcat ? they all go to same context .. One last thing - If you upload the .war files with the tomcat manager / host-manager is there a way to do this Once the Host elements are set up, you shouldn't have to do any more editing of server.xml - just deploy the default webapp as ROOT under each Host. However, you will have to deploy the manager app for each Host, since each instance is tied to a given Host (at least it was last time I tried). The easiest way to do that is just copy the manager directory to each of your Host's appBase directories. You can also do it by putting a Context element for each manager in conf/Catalina/[host]/manager.xml, but all that does is save a minimal amount of disk space. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
Thanks everybody for your input. I'll try to deploy the manager for each host as suggested. Cheers everybody. 2008/9/26 Caldarale, Charles R [EMAIL PROTECTED] From: Morgan Cox [mailto:[EMAIL PROTECTED] Subject: Re: How to have multiple domains/contexts with Tomcat ? they all go to same context .. One last thing - If you upload the .war files with the tomcat manager / host-manager is there a way to do this Once the Host elements are set up, you shouldn't have to do any more editing of server.xml - just deploy the default webapp as ROOT under each Host. However, you will have to deploy the manager app for each Host, since each instance is tied to a given Host (at least it was last time I tried). The easiest way to do that is just copy the manager directory to each of your Host's appBase directories. You can also do it by putting a Context element for each manager in conf/Catalina/[host]/manager.xml, but all that does is save a minimal amount of disk space. - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to have multiple domains/contexts with Tomcat ? they all go to same context ..
- Original Message - From: André Warnier [EMAIL PROTECTED] To: Tomcat Users List users@tomcat.apache.org Sent: Friday, September 26, 2008 12:10 PM Subject: Re: How to have multiple domains/contexts with Tomcat ? they all go to same context .. Can you tell us on what kind of host system you are running this ? It would help guessing where the files are. Thanks. P.S. I am not the expert, but it should indeed be relatively simple, so I'll try. In a nutshell : - start again from the original server.xml file. - in it, locate the Host name=localhost ./Host section, copy it, and re-insert it after the original section. - then replace the name=localhost attribute by name=www.mrpink.com - then redo the same one more time, this time with www.mrblue.com The above takes care of letting Tomcat known that there are 3 Virtual Hosts : - www.mrpink.com - www.mrblue.com - and localhost, which will also be (remain) the Host by default, if the name given in the request does not match either of the other ones (for example, if someone calls up http://xxx.xxx.xxx.xxx:8180 (with the IP address of your server). (I suggest to keep that one as it is, to access the documentation etc..) Now what is left is to tell Tomcat where, for each of the virtual hosts, he finds the corresponding documents and webapps. I would recommend to create 2 additional directories, at the same level as your current webapps, say webapps-pink and webapps-blue. Then move the respective documents/applications in these directories, checking ownership and permissions etc.. They must at least be readable by the user-id running Tomcat. Now go back to your individual Hosts sections, and change appBase=webapps by appBase=webapps-pink and appBase=webapps-blue Now restart Tomcat. You should now be able to access blue by calling up http://www.mrblue.com/mrblue;. To make this trailing /mrblue go away, you should make this webapp into the ROOT webapp for that virtual server, but for that I'll let an expert give you the instructions. Have I got it right ? Any better... and we'll have to pay you a consulting fee ;) --- HARBOR : http://www.kewlstuff.co.za/index.htm The most powerful application server on earth. The only real POJO Application Server. See it in Action : http://www.kewlstuff.co.za/cd_tut_swf/whatisejb1.htm --- - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
multiple domains
Hi guys, I have this server that has two domains pointing at it, the tomcat server 5 is running there, I have two wep applications for the two domains, so i like: www.domain1.com will call the app1 www.domain2.com will call the app2 how to configure tomcat to work like this? thanks Angelo -- View this message in context: http://www.nabble.com/multiple-domains-tp15865530p15865530.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multiple domains
dont send me tomcat hereafter!! - Original Message - From: Angelo Chen [EMAIL PROTECTED] To: users@tomcat.apache.org Sent: Thursday, March 06, 2008 8:29 AM Subject: multiple domains Hi guys, I have this server that has two domains pointing at it, the tomcat server 5 is running there, I have two wep applications for the two domains, so i like: www.domain1.com will call the app1 www.domain2.com will call the app2 how to configure tomcat to work like this? thanks Angelo -- View this message in context: http://www.nabble.com/multiple-domains-tp15865530p15865530.html Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: multiple domains
From: Angelo Chen [mailto:[EMAIL PROTECTED] Subject: multiple domains www.domain1.com will call the app1 www.domain2.com will call the app2 In conf/server.xml, configure two Host elements, one for each domain. Create a separate appBase directory for each Host, and configure the appBase in each appropriately. Place app1 under domain1's appBase as ROOT, app2 under domain2's appBase as ROOT. You're done. Doc references: http://tomcat.apache.org/tomcat-5.5-doc/config/host.html http://tomcat.apache.org/tomcat-5.5-doc/config/context.html - 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: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Can Tomcat support multiple SSL certificates for multiple domains?
Ooops, my fault! I've read and replied too fast (maybe because it's Monday? :-)) Of course this shouldn't be done with *two domain names* only with two host names in the same domain... I suppose it won't work in actual browsers but if it does I let you all know... Sorry Jan Hassan Schroeder schrieb: On Feb 11, 2008 5:00 AM, Jan Mönnich [EMAIL PROTECTED] wrote: You can get one certificate with both domain names in the Subject Alternative Name of the Certificate. All modern browsers can handle that and you can use just one Certificate for both domains. That's the workaround we are recommending to all of our customers. Have you actually seen this deployed? I ask because I've only seen Subject Alternative Name used as e.g. foo.example.com, bar.example.com -- never two *domain* names. If that really works, it'd be good to know :-) -- Dipl.-Inf. (FH) Jan Mönnich, PKI Team Phone: +49 40 808077-632, Fax: +49 40 808077-556, [EMAIL PROTECTED] DFN-CERT Services GmbH, https://www.dfn-cert.de, Phone +49 40 808077-555 Sitz / Register: Hamburg, AG Hamburg, HRB 88805, Ust-IdNr.: DE 232129737 Sachsenstraße 5, 20097 Hamburg/Germany, CEO: Dr. Klaus-Peter Kossakowski 15 Jahre DFN-CERT + 15. DFN-Workshop Sicherheit in vernetzten Systemen am 13./14. Februar 2008 im CCH Hamburg - https://www.dfn-cert.de/ws2008/ smime.p7s Description: S/MIME Cryptographic Signature
Re: Can Tomcat support multiple SSL certificates for multiple domains?
On Feb 11, 2008 5:00 AM, Jan Mönnich [EMAIL PROTECTED] wrote: You can get one certificate with both domain names in the Subject Alternative Name of the Certificate. All modern browsers can handle that and you can use just one Certificate for both domains. That's the workaround we are recommending to all of our customers. Have you actually seen this deployed? I ask because I've only seen Subject Alternative Name used as e.g. foo.example.com, bar.example.com -- never two *domain* names. If that really works, it'd be good to know :-) -- Hassan Schroeder [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Can Tomcat support multiple SSL certificates for multiple domains?
Hi, I have one JBoss instance (4.0.5GA) running on Linux. The machine has one IP with two domains. www.domain1.com www.domain2.com I have two SSL certificates, one for each domain, imported into keystore. I need to use both without any warnings from browser https://www.domain1.com https://www.domain2.com Can Tomcat pick the right certificate based on current domain name? But according to http://tomcat.apache.org/tomcat-5.5-doc/ssl-howto.html keyAlias Add this element if your have more than one key in the KeyStore. If the element is not present the first key read in the KeyStore will be used. How to work around this? Thanks for help! Dave - Looking for last minute shopping deals? Find them fast with Yahoo! Search.
Re: Can Tomcat support multiple SSL certificates for multiple domains?
Dave wrote: Hi, I have one JBoss instance (4.0.5GA) running on Linux. The machine has one IP with two domains. www.domain1.com www.domain2.com I have two SSL certificates, one for each domain, imported into keystore. I need to use both without any warnings from browser https://www.domain1.com https://www.domain2.com Can Tomcat pick the right certificate based on current domain name? But according to http://tomcat.apache.org/tomcat-5.5-doc/ssl-howto.html keyAlias Add this element if your have more than one key in the KeyStore. If the element is not present the first key read in the KeyStore will be used. How to work around this? Thanks for help! Dave Refer to the following link: http://marc.info/?l=tomcat-userm=120239893800741w=2 For additional info: http://marc.info/?l=tomcat-userw=2r=1s=sslq=b -- Regards Gabe Wong NGASI AppServer Manager JAVA AUTOMATION and SaaS Enablement a href=http://www.ngasi.comhttp://www.ngasi.com/a NEW! 8.0 - Centrally manage multiple physical servers - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tomcat SSL for multiple domains
Hi I am running JBoss w/tomcat on a Linux machine. the machine has one IP address. But there are two top-level domains (not subdomains) mapping to the ip address. www.domain1.com www.domain2.com I need to setup SSL. As far as I know, SSL certificate is set up for one domain only. Using the different domains will get a security warning from web browser. (domain name does not match) Can SSL certificate be ip address based? Or Tomcat support SSL multiple domains(prevent warnings from browser)? Thanks, Dave - Looking for last minute shopping deals? Find them fast with Yahoo! Search.
RE: Tomcat SSL for multiple domains
From: Dave [mailto:[EMAIL PROTECTED] the machine has one IP address. But there are two top-level domains (not subdomains) mapping to the ip address. www.domain1.com www.domain2.com I need to setup SSL. As far as I know, SSL certificate is set up for one domain only. Using the different domains will get a security warning from web browser. (domain name does not match) Can SSL certificate be ip address based? Or Tomcat support SSL multiple domains(prevent warnings from browser)? Tomcat can support multiple SSL domains. *But* there is a fundamental point about SSL: the secure connection is negotiated before the HTTP host header is sent. That means that _no web server, of any kind, can successfully host SSL for multiple domains on the same port on the same IP address_. You have two possible workarounds: - Get a second IP address assigned to the machine. This is often easier than it sounds. Map one domain to each IP address, and bind each of your two SSL connectors to one IP. At this point, everything Just Works for the user. - Run SSL for one domain on port 443, and for the other domain on a different port - say 8443. This gives a slightly messy user experience, as you have https://www.domain1.com but https://www.domain2.com:8443. This is a limitation of SSL; it is not Tomcat-specific. - Peter - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat SSL for multiple domains
On Feb 7, 2008 7:25 AM, Dave [EMAIL PROTECTED] wrote: Hi I am running JBoss w/tomcat on a Linux machine. the machine has one IP address. But there are two top-level domains (not subdomains) mapping to the ip address. I need to setup SSL. As far as I know, SSL certificate is set up for one domain only. Yep, you need two IPs, and a cert for each domain. That's just the way it works. :-) -- Hassan Schroeder [EMAIL PROTECTED] - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Windows Authentication against multiple domains
I can't suggest any open-source/free products but allow me to suggest reading the following article if you want to roll your own solution one of these days in the windows world: http://www.microsoft.com/msj/0899/kerberos/kerberos.aspx Once you read it, I hope you will be able to see how you can put some amount of work in from your side and leverage Kerberos as a solution across Windows domains. But may be I misunderstood your problem, may be you don't want SSO across multiple domains. Maybe you simply want a piece of code that can connect to multiple ADs instead of just one? I suggest a bit more clarification so that the list readers may understand your use-case. Cheers! On 2/9/07, Suneet Shah [EMAIL PROTECTED] wrote: Hello, We have this capability in our open source identity and access management solution where you can use more then one use more then one repository for authentication. You may be able to use just the authentication service as taking on the rest of it may be more then what you need. The project is OpenIAM on sourceforge. We will be putting a new release this weekend. If you are interested in taking a look, let me know and I can send you a link. Regards Suneet On 2/9/07, Uwe_77 [EMAIL PROTECTED] wrote: Sure, I will let you know. Perhaps we need third party tools. Doese someone knows a solution? -- View this message in context: http://www.nabble.com/RE%3A-Windows-Authentication-against-multiple-domains-tf3203321.html#a8895171 Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Windows Authentication against multiple domains
Hi, I am having a tomcat webapplication and logon needs to be done via windows-authentication (ldap). I configured authentication against ldap, that works fine for one domain. The problem is, that we are having users in multiple domains. Is there a way to configure authentication against the whole active directory forest? Thanks for your help! Uwe
RE: Windows Authentication against multiple domains
if you find out, please let me know...I'm barking up that tree, too. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Friday, February 09, 2007 4:50 PM To: users@tomcat.apache.org Subject: Windows Authentication against multiple domains Hi, I am having a tomcat webapplication and logon needs to be done via windows-authentication (ldap). I configured authentication against ldap, that works fine for one domain. The problem is, that we are having users in multiple domains. Is there a way to configure authentication against the whole active directory forest? Thanks for your help! Uwe - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Windows Authentication against multiple domains
Sure, I will let you know. Perhaps we need third party tools. Doese someone knows a solution? -- View this message in context: http://www.nabble.com/RE%3A-Windows-Authentication-against-multiple-domains-tf3203321.html#a8895171 Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Windows Authentication against multiple domains
Hello, We have this capability in our open source identity and access management solution where you can use more then one use more then one repository for authentication. You may be able to use just the authentication service as taking on the rest of it may be more then what you need. The project is OpenIAM on sourceforge. We will be putting a new release this weekend. If you are interested in taking a look, let me know and I can send you a link. Regards Suneet On 2/9/07, Uwe_77 [EMAIL PROTECTED] wrote: Sure, I will let you know. Perhaps we need third party tools. Doese someone knows a solution? -- View this message in context: http://www.nabble.com/RE%3A-Windows-Authentication-against-multiple-domains-tf3203321.html#a8895171 Sent from the Tomcat - User mailing list archive at Nabble.com. - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Windows Authentication against multiple domains
I am yet another barking up that tree. --- Propes, Barry L [GCG-NAOT] [EMAIL PROTECTED] wrote: if you find out, please let me know...I'm barking up that tree, too. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Friday, February 09, 2007 4:50 PM To: users@tomcat.apache.org Subject: Windows Authentication against multiple domains Hi, I am having a tomcat webapplication and logon needs to be done via windows-authentication (ldap). I configured authentication against ldap, that works fine for one domain. The problem is, that we are having users in multiple domains. Is there a way to configure authentication against the whole active directory forest? Thanks for your help! Uwe - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Sucker-punch spam with award-winning protection. Try the free Yahoo! Mail Beta. http://advision.webevents.yahoo.com/mailbeta/features_spam.html - To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
configure tomcat and iis for multiple domains
Hi all I want to configure Tomcat with IIS to service multiple domains same as Web Hostings.My purpose is establish an Internet Hosting server. Can any one help me or address useful documet for this? Thanks __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com