|
From: Jian J. <jia...@gm...> - 2008-03-24 19:38:51
|
Hello, I have a problem when I try to deploy Wayback. I have two servers running Wayback at the back end and a balancer controller at the front. My Wayback works well separatedly on the two back end servers. However, When I try to access Wayback using the URL of the balancer controller, there is always an error. It seems that Wayback does not know the access point. In the statement in index.jsp ArrayList<String> accessPoints = (ArrayList<String>) names accessPoints is always null. I already modified the wayback.xml to change the replayURIPrefix to the new domain. I don't know what's the wrong with it. Can you please help me to figure out what is the problem? Any help or suggestions would be appreciated. -- Best wishes, Jian |
|
From: Brad T. <br...@ar...> - 2008-03-27 17:05:32
|
Hi Jian, The problem is probably that the Wayback needs to know the fully qualified hostname where it is running, so it can generate links correctly. To do the kind of setup you're trying to, I know of two solutions using the current software: 1) use AJP to ensure that the requests are received by the Wayback with the correct hostname, port, and context information. 2) use the "ProxyHost" (and possibly "ProxyPort") settings on the "Connector" tag within tomcat's server.xml configuration file. This allows you to explicitly set the values returned by HttpServletRequest.getServer*(). These two settings do not allow as much flexibility (specifically with proxying a different path from a front end node to a backend wayback access point) so probably going forward we will change the software to allow the AccessPoint URI to be set explicitly within the wayback configuration. Please let me know if you have questions on this, and how it works for you. Brad Jian Jiao wrote: > Hello, > > I have a problem when I try to deploy Wayback. > I have two servers running Wayback at the back end and a balancer > controller at the front. > My Wayback works well separatedly on the two back end servers. > However, When I try to access Wayback using the URL of the balancer > controller, > there is always an error. > > It seems that Wayback does not know the access point. > > In the statement in index.jsp > ArrayList<String> accessPoints = (ArrayList<String>) names > accessPoints is always null. > > I already modified the wayback.xml to change the replayURIPrefix to > the new domain. > > I don't know what's the wrong with it. Can you please help me to > figure out what is the problem? > > Any help or suggestions would be appreciated. > > |
|
From: Jian J. <jia...@gm...> - 2008-03-28 01:10:53
|
Hello, Brad, Thanks for you reply. Yes, you are right. I think the correct full URL is not correctly sent to Wayback. But I still have no idea how to solve it. The problem probably lies in the communication between the Apache2 and Tomcat. Actually, we have AJP connectors setup on our back end servers and we map the port 80 to 8080. Suppose the back end servers A and B, and load balancer C. When I tried the URL http://A/wayback-webapp-1.2.0/wayback/, I got a successful message from access_log "GET /wayback-webapp-1.2.0/wayback/ HTTP/1.1" 200 3610. But when I tried the URL http://C/wayback-webapp-1.2.0/wayback/, I got an error message from access_log of Apache2 "GET /wayback-webapp-1.2.0/wayback/ HTTP/1.1" 404 1042. Obviously, the two requests are both successfully received by Apache2, why the responses are different? In the http.conf, I already added "JkMount /wayback* ajp13". Since we already use the AJP, so I prefer to do modification based on that. Would you please explain more clearly and detailedly what should I do to ensure the correct requests are received by Wayback. Thanks very much and best regards. Jian On Thu, Mar 27, 2008 at 1:06 PM, Brad Tofel <br...@ar...> wrote: > Hi Jian, > > The problem is probably that the Wayback needs to know the fully > qualified hostname where it is running, so it can generate links correctly. > > To do the kind of setup you're trying to, I know of two solutions using > the current software: > 1) use AJP to ensure that the requests are received by the Wayback with > the correct hostname, port, and context information. > 2) use the "ProxyHost" (and possibly "ProxyPort") settings on the > "Connector" tag within tomcat's server.xml configuration file. This > allows you to explicitly set the values returned by > HttpServletRequest.getServer*(). > > These two settings do not allow as much flexibility (specifically with > proxying a different path from a front end node to a backend wayback > access point) so probably going forward we will change the software to > allow the AccessPoint URI to be set explicitly within the wayback > configuration. > > Please let me know if you have questions on this, and how it works for you. > > Brad > > > > Jian Jiao wrote: > > Hello, > > > > I have a problem when I try to deploy Wayback. > > I have two servers running Wayback at the back end and a balancer > > controller at the front. > > My Wayback works well separatedly on the two back end servers. > > However, When I try to access Wayback using the URL of the balancer > > controller, > > there is always an error. > > > > It seems that Wayback does not know the access point. > > > > In the statement in index.jsp > > ArrayList<String> accessPoints = (ArrayList<String>) names > > accessPoints is always null. > > > > I already modified the wayback.xml to change the replayURIPrefix to > > the new domain. > > > > I don't know what's the wrong with it. Can you please help me to > > figure out what is the problem? > > > > Any help or suggestions would be appreciated. > > > > > > -- Best wishes, Jian Jiao |
|
From: Brad T. <br...@ar...> - 2008-04-17 21:54:16
|
For the rest of the list, this issue was discussed further, off-list, and the solution we came to was a missing AccessPoint configuration on the 2 back-end Wayback installations. Using AJP, requests arrive at the Wayback appearing as though they came in on the port they were received on the front-end host, in this case, port 80. Assuming the following configuration and hostname: Front end Apache running AJP, listening on port 80 named "www.example.com". AJP is configured to map incoming requests for "/wayback*" to the two back end Tomcat installations running the Wayback deployed under the context "wayback-1.2.0", which normally responds to local requests on port 8080. Adding this AccessPoint allows the backend wayback installations to map the requests correctly, and causes replay links to also arrive on the front end Apache. <bean name="80:wayback" parent="8080:wayback"> <property name="uriConverter"> <bean class="org.archive.wayback.archivalurl.ArchivalUrlResultURIConverter"> <property name="replayURIPrefix" value="http://www.example.com/wayback-webapp-1.2.0/wayback/" /> </bean> </property> </bean> Brad Jian Jiao wrote: > Hello, Brad, > > Thanks for you reply. > > Yes, you are right. I think the correct full URL is not correctly sent > to Wayback. But I still have no idea how to solve it. > > The problem probably lies in the communication between the Apache2 and > Tomcat. Actually, we have AJP connectors setup on our back end servers > and we map the port 80 to 8080. Suppose the back end servers A and B, > and load balancer C. > > When I tried the URL http://A/wayback-webapp-1.2.0/wayback/, I got a > successful message from access_log "GET /wayback-webapp-1.2.0/wayback/ > HTTP/1.1" 200 3610. > But when I tried the URL http://C/wayback-webapp-1.2.0/wayback/, I got > an error message from access_log of Apache2 "GET > /wayback-webapp-1.2.0/wayback/ HTTP/1.1" 404 1042. > Obviously, the two requests are both successfully received by Apache2, > why the responses are different? > > In the http.conf, I already added "JkMount /wayback* ajp13". > > Since we already use the AJP, so I prefer to do modification based on > that. Would you please explain more clearly and detailedly what should > I do to ensure the correct requests are received by Wayback. > > Thanks very much and best regards. > > Jian > > On Thu, Mar 27, 2008 at 1:06 PM, Brad Tofel <br...@ar...> wrote: > >> Hi Jian, >> >> The problem is probably that the Wayback needs to know the fully >> qualified hostname where it is running, so it can generate links correctly. >> >> To do the kind of setup you're trying to, I know of two solutions using >> the current software: >> 1) use AJP to ensure that the requests are received by the Wayback with >> the correct hostname, port, and context information. >> 2) use the "ProxyHost" (and possibly "ProxyPort") settings on the >> "Connector" tag within tomcat's server.xml configuration file. This >> allows you to explicitly set the values returned by >> HttpServletRequest.getServer*(). >> >> These two settings do not allow as much flexibility (specifically with >> proxying a different path from a front end node to a backend wayback >> access point) so probably going forward we will change the software to >> allow the AccessPoint URI to be set explicitly within the wayback >> configuration. >> >> Please let me know if you have questions on this, and how it works for you. >> >> Brad >> >> >> >> Jian Jiao wrote: >> > Hello, >> > >> > I have a problem when I try to deploy Wayback. >> > I have two servers running Wayback at the back end and a balancer >> > controller at the front. >> > My Wayback works well separatedly on the two back end servers. >> > However, When I try to access Wayback using the URL of the balancer >> > controller, >> > there is always an error. >> > >> > It seems that Wayback does not know the access point. >> > >> > In the statement in index.jsp >> > ArrayList<String> accessPoints = (ArrayList<String>) names >> > accessPoints is always null. >> > >> > I already modified the wayback.xml to change the replayURIPrefix to >> > the new domain. >> > >> > I don't know what's the wrong with it. Can you please help me to >> > figure out what is the problem? >> > >> > Any help or suggestions would be appreciated. >> > >> > >> >> >> > > > > |