[prev] [thread] [next] [Date index for 2004/12/06]
------=_NextPart_000_0111_01C4DB8B.D9A78CB0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi! I am having difficulty setting cookies once we changed our production = modperl system. We changed from a single machine front-end/backend setup two a two = machine setup Both use apache 2.x for the front server on ports 80 and 443, and = modperl 1.3.x server running on ports 8001,8000. The problem is only occurring on the 2 machine setup with server 1 = running apache 2.x using proxypass and modrewrite to proxy back to = server 2. The problem is: after the server is restarted, cookies are set just = fine. But, after each of the new child processes have been used, cookies = are no longer set. The Perl application continues to see the client's = existing cookie, but new cookies are not set. Here are some questions: 1)=20 If I am using Apache 2.x, do I still need to compile in = mod_proxy_add_forward to the apache server? I was somehow under the = impression that this exists under apache2.x. 2) In the lines of the example preload.pl script it shows=20 unless ($r->connection->remote_ip eq "127.0.0.1") and = $r->header_in('X-Forwarded-For'); I assume that this setup (127.0.0.1) is for when both versions of apache = are run on the same machine? If I have a 2 machine setup with server1_ip_addr and server2_ip_addr = then I should have: unless ($r->connection->remote_ip eq "server1_ip_addr") and = $r->header_in('X-Forwarded-For'); Is this correct? The docs don't make this clear. Sorry for so many questions. I have searched the mailing list and cannot = find the answers to these questions. Thanks, Joe Junkin ------=_NextPart_000_0111_01C4DB8B.D9A78CB0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META http-equiv=3DContent-Type content=3D"text/html; = charset=3Diso-8859-1"> <META content=3D"MSHTML 6.00.2800.1476" name=3DGENERATOR> <STYLE></STYLE> </HEAD> <BODY bgColor=3D#ffffff> <DIV><FONT face=3DArial size=3D2>Hi!</FONT></DIV> <DIV><FONT face=3DArial size=3D2>I am having difficulty setting cookies = once we=20 changed our production modperl system.</FONT></DIV> <DIV><FONT face=3DArial size=3D2>We changed from a single machine=20 front-end/backend setup two a two machine setup</FONT></DIV> <DIV><FONT face=3DArial size=3D2>Both use apache 2.x for the front = server on ports=20 80 and 443, and modperl 1.3.x server running on ports = 8001,8000.</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>The problem is only occurring on the 2 = machine=20 setup with server 1 running apache 2.x using proxypass and modrewrite to = proxy=20 back to server 2.</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>The problem is: after the server = is restarted,=20 cookies are set just fine. But, after each of the new child processes = have been=20 used, cookies are no longer set. The Perl application continues to see = the=20 client's existing cookie, but new cookies are not set.</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>Here are some questions:</FONT></DIV> <DIV><FONT face=3DArial size=3D2>1) </FONT></DIV> <DIV><FONT face=3DArial size=3D2>If I am using Apache 2.x, do I still = need to=20 compile in <FONT size=3D3><FONT=20 face=3D"Courier New">mod_proxy_add_forward</FONT> </FONT> to = the apache=20 server? I was somehow under the impression that this exists under=20 apache2.x.</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>2)</FONT></DIV> <DIV><FONT face=3DArial size=3D2>In the lines of the example preload.pl = script it=20 shows </FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2> unless = ($r->connection->remote_ip eq=20 "127.0.0.1") and $r->header_in('X-Forwarded-For');</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>I assume that this setup (127.0.0.1) is = for when=20 both versions of apache are run on the same machine?</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>If I have a 2 machine setup with = server1_ip_addr=20 and server2_ip_addr then I should have:</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2> unless = ($r->connection->remote_ip eq=20 "server1_ip_addr") and $r->header_in('X-Forwarded-For');</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>Is this correct? The docs don't make = this=20 clear.</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>Sorry for so many questions. I have = searched the=20 mailing list and cannot find the answers to these = questions.</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial size=3D2>Thanks,</FONT></DIV> <DIV><FONT face=3DArial size=3D2></FONT> </DIV> <DIV><FONT face=3DArial = size=3D2>Joe Junkin</FONT></DIV></BODY></HTML> ------=_NextPart_000_0111_01C4DB8B.D9A78CB0--
![]() |
Q about ProxyRemoteAddr
|
![]() |
![]() |
Re: Q about ProxyRemoteAddr
|
Generated at 11:26 on 21 Dec 2004 by mariachi v0.52