Proxied output is corrupted by extraneous numbers

Proxied output is corrupted by extraneous numbers

am 03.05.2002 13:23:54 von mlewis

Hello,

While preparing to upgrade our production servers, I encountered
a problem that may involve mod_proxy code. When html code is
generated and printed by our mod_perl handler initiated directly
from the back end the output is correct. When the same operation
is initiated via the front end proxy server the output is corrupted
by extraneous numbers. I have set up a test scenario to isolate
the problem. Our new server configurations include this software:

Front End Back End
--------- --------
kernel-2.4.9-31 kernel-2.4.9-31
apache_1.3.24 apache_1.3.24
mod_ssl-2.8.8-1.3.24 mod_perl-1.26
openssl-0.9.6c
mm-1.1.3

The front end apache configuration includes:


ServerName gelco5.yvod.com
DocumentRoot /www/gelcompany/html

RewriteEngine On
RewriteLogLevel 9
RewriteOptions 'inherit'

RewriteRule ^/$ http://192.168.20.111:8089/ [proxy,last]

RewriteRule ^/(.+)$ /www/gelcompany/html/$1 [last]


The back end apache configuration includes:

NameVirtualHost 192.168.20.111:8089
Listen 8089

ServerName gelco5.yvod.com
DocumentRoot /www/gelcompany/html

Alias / /www/gelcompany/modperl


SetHandler perl-script
PerlHandler YVOD::welcome



The test handler code looks like this:

#!/usr/bin/perl -w -d
package YVOD::welcome;
use strict;

sub handler{
my $r = shift;
$r->send_http_header('text/html');
print qq|\n|;
print "You are Welcome at ", $r->get_remote_host, "

\n";
while (my ($key, $val) = each %ENV) {
print "$key = $val
\n"; }
print "";
return 1;
}
1;

The outout source looks like this when initiated directly from the
back end (http://192.168.20.111:8089/):


You are Welcome at 192.168.20.98


QUERY_STRING =

HTTP_ACCEPT_LANGUAGE = en

TZ = PST8PDT

REMOTE_PORT = 3201

HTTP_USER_AGENT = Mozilla/4.76 [en] (X11; U; Linux 2.2.14-5.0 i686)

HTTP_ACCEPT = image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
image/png, */*

HTTP_HOST = 192.168.20.111:8089

GATEWAY_INTERFACE = CGI-Perl/1.1

SCRIPT_NAME = /

SERVER_NAME = gelco5.yvod.com

HTTP_ACCEPT_ENCODING = gzip

MOD_PERL = mod_perl/1.26

HTTP_ACCEPT_CHARSET = iso-8859-1,*,utf-8

HTTP_COOKIE = YVOD_SESSION_ID=2e4046b477f9374f

SCRIPT_FILENAME = /www/gelcompany/modperl

PATH = /bin:/usr/bin

SERVER_ADDR = 192.168.20.111

MOD_PERL_TRACE = all

SERVER_PROTOCOL = HTTP/1.0

HTTP_CONNECTION = Keep-Alive

SERVER_SIGNATURE =

Apache/1.3.24 Server at gelco5.yvod.com Port
8089



SERVER_SOFTWARE = Apache/1.3.24 (Unix) mod_perl/1.26

SERVER_ADMIN = webmaster@yvod.com

REMOTE_ADDR = 192.168.20.98

DOCUMENT_ROOT = /www/gelcompany/html

REQUEST_URI = /

REQUEST_METHOD = GET

SERVER_PORT = 8089



The outout source looks like this when initiated via the front end
proxy server (http://gelco5.yvod.com/):

49a

You are Welcome at 192.168.20.111


QUERY_STRING =

HTTP_ACCEPT_LANGUAGE = en

TZ = PST8PDT

REMOTE_PORT = 2462

HTTP_USER_AGENT = Mozilla/4.76 [en] (X11; U; Linux 2.2.14-5.0 i686)

HTTP_ACCEPT = image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
image/png, */*

HTTP_HOST = 192.168.20.111:8089

GATEWAY_INTERFACE = CGI-Perl/1.1

SCRIPT_NAME = /

SERVER_NAME = gelco5.yvod.com

HTTP_ACCEPT_ENCODING = gzip

MOD_PERL = mod_perl/1.26

HTTP_ACCEPT_CHARSET = iso-8859-1,*,utf-8

HTTP_VIA = 1.0 gelco5.yvod.com (Apache/1.3.24)

SCRIPT_FILENAME = /www/gelcompany/modperl

PATH = /bin:/usr/bin

HTTP_X_FORWARDED_FOR = 192.168.20.96

SERVER_ADDR = 192.168.20.111

MOD_PERL_TRACE = all

SERVER_PROTOCOL = HTTP/1.1

HTTP_CONNECTION = close

SERVER_SIGNATURE =
Apache/1.3.24 Server at gelco5.yvod.com Port
8089



SERVER_SOFTWARE = Apache/1.3.24 (Unix) mod_perl/1.26

SERVER_ADMIN = webmaster@yvod.com

REMOTE_ADDR = 192.168.20.111

DOCUMENT_ROOT = /www/gelcompany/html

REQUEST_URI = /

REQUEST_METHOD = GET

SERVER_PORT = 8089


0

In the second case, there is about a 15 second delay before the '0'
prints at the bottom of the display and 'Document Done.' is indicated.
The number that prints at the beginning changes depending upon the
content (it may be a length value), but the number at the end is
always '0'. Also, the following messages are written to error_log:

[Fri May 3 03:42:39 2002] [debug] proxy_cache.c(1026):
Request for http://192.168.20.111:8089/, pragma_req=no-cache, ims=0
[Fri May 3 03:42:39 2002] [debug] proxy_util.c(1401):
File /opt1/httpd_docs/proxy/A/a/R/8dpIO_pSaxiSOa1CyWg not found
[Fri May 3 03:42:39 2002] [debug] proxy_cache.c(1280):
Local copy not present or expired. Declining.
[Fri May 3 03:42:49 2002] [debug] proxy_cache.c(1391):
Response is not cacheable,
unlinking /opt1/httpd_docs/proxy/A/a/R/8dpIO_pSaxiSOa1CyWg
[Fri May 3 03:42:49 2002] [debug] proxy_http.c(583):
Content-Type: text/html

Although I've abbreviated it for testing, the basic configuration
is the same as I've been using in production for over two years,
but it's quite possible that the source of the problem is in the
configuration. It's also possible that the problem has nothing to
do with mod_proxy - it could be related to Apache::PRINT. If you
can provide any help I would be very grateful as I've been pounding
at this for several days now. And if there is any other info I can
get for you please let me know.

Thanks, Michael...
--
Michael E. Lewis YVOD, LLC / Comprehend.Com Phone: 510-655-3974
mlewis@comprehend.com 5816 Ocean View Drive Cell: 510-435-3180
michael@yvod.com Oakland, CA 94618-1535 Fax: 419-781-9206

Re: Proxied output is corrupted by extraneous numbers

am 03.05.2002 13:43:43 von Graham Leggett

This is a cryptographically signed message in MIME format.

--------------msC2354F9614640063AA48C2D3
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

"Michael E. Lewis" wrote:

> While preparing to upgrade our production servers, I encountered
> a problem that may involve mod_proxy code.

This is a known bug, which is fixed in v1.3.25-dev.

What Apache is doing is not dechunking incoming requests properly.
"chunking" refers to a special encoding that allows an HTTP client to
know how much to download from the server without there having to be a
valid Content-Length on the request. The numbers you see are the
"lengths" within the protocol, which are supposed to be stripped out.

There should be a release of 1.2.25 shortly, which will fix this
problem.

Regards,
Graham
--
-----------------------------------------
minfrin@sharp.fm "There's a moon
over Bourbon Street
tonight..."
--------------msC2354F9614640063AA48C2D3
Content-Type: application/x-pkcs7-signature; name="smime.p7s"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="smime.p7s"
Content-Description: S/MIME Cryptographic Signature

MIIHyAYJKoZIhvcNAQcCoIIHuTCCB7UCAQExCzAJBgUrDgMCGgUAMAsGCSqG SIb3DQEHAaCC
BcYwggKVMIIB/qADAgECAgMEyOwwDQYJKoZIhvcNAQEEBQAwgZIxCzAJBgNV BAYTAlpBMRUw
EwYDVQQIEwxXZXN0ZXJuIENhcGUxEjAQBgNVBAcTCUNhcGUgVG93bjEPMA0G A1UEChMGVGhh
d3RlMR0wGwYDVQQLExRDZXJ0aWZpY2F0ZSBTZXJ2aWNlczEoMCYGA1UEAxMf UGVyc29uYWwg
RnJlZW1haWwgUlNBIDIwMDAuOC4zMDAeFw0wMTA1MTEwMDE3NDZaFw0wMjA1 MTEwMDE3NDZa
MF0xEDAOBgNVBAQTB0xlZ2dldHQxDzANBgNVBCoTBkdyYWhhbTEXMBUGA1UE AxMOR3JhaGFt
IExlZ2dldHQxHzAdBgkqhkiG9w0BCQEWEG1pbmZyaW5Ac2hhcnAuZm0wgZ8w DQYJKoZIhvcN
AQEBBQADgY0AMIGJAoGBALX2zJvQ/9l+sCEpkfMNNwtnMcF8vmPM2sRpibT5 nR87bYWyLVCt
XXWXU+UyDOkiQJt6UahnmYZV7u40a1/osbNnjHjyNybejOuUFjHYy1gDwjsE lnxYbRRA2SZc
CmrZ4V0QFI0ZKuimGryZQj77UroiIV+Qq+v+PaxDEGwiqJqnAgMBAAGjLTAr MBsGA1UdEQQU
MBKBEG1pbmZyaW5Ac2hhcnAuZm0wDAYDVR0TAQH/BAIwADANBgkqhkiG9w0B AQQFAAOBgQCO
l5bH8JXuFM+EZi01jfezzKML5iPBHx4BDj/4gl2lXw1t0v6o+9442F6TpnOV Ak3LL1KTupvc
HfM+Bn71iWuD8ASCoSsmVpeoCbOv3lPGltrDgywcmM8phZyK1hHLvvJgfd4I MZbuH/rm0ZWp
WjRORFfik8yuO9DgahgjgAhkujCCAykwggKSoAMCAQICAQwwDQYJKoZIhvcN AQEEBQAwgdEx
CzAJBgNVBAYTAlpBMRUwEwYDVQQIEwxXZXN0ZXJuIENhcGUxEjAQBgNVBAcT CUNhcGUgVG93
bjEaMBgGA1UEChMRVGhhd3RlIENvbnN1bHRpbmcxKDAmBgNVBAsTH0NlcnRp ZmljYXRpb24g
U2VydmljZXMgRGl2aXNpb24xJDAiBgNVBAMTG1RoYXd0ZSBQZXJzb25hbCBG cmVlbWFpbCBD
QTErMCkGCSqGSIb3DQEJARYccGVyc29uYWwtZnJlZW1haWxAdGhhd3RlLmNv bTAeFw0wMDA4
MzAwMDAwMDBaFw0wMjA4MjkyMzU5NTlaMIGSMQswCQYDVQQGEwJaQTEVMBMG A1UECBMMV2Vz
dGVybiBDYXBlMRIwEAYDVQQHEwlDYXBlIFRvd24xDzANBgNVBAoTBlRoYXd0 ZTEdMBsGA1UE
CxMUQ2VydGlmaWNhdGUgU2VydmljZXMxKDAmBgNVBAMTH1BlcnNvbmFsIEZy ZWVtYWlsIFJT
QSAyMDAwLjguMzAwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAN4zMqZj xwklRT7Sbngn
Z4HF2ogZgpcO40QpimM1Km1wPPrcrvfudG8wvDOQf/k0caCjbZjxw0+iZdsN +kvx1t1hpfmF
zVWaNRqdknWoJ67Ycvm6AvbXsJHeHOmr4BgDqHxDQlBRh4M88Dm0m1SKE4f/ s5udSWYALQmJ
7JRr6aFpAgMBAAGjTjBMMCkGA1UdEQQiMCCkHjAcMRowGAYDVQQDExFQcml2 YXRlTGFiZWwx
LTI5NzASBgNVHRMBAf8ECDAGAQH/AgEAMAsGA1UdDwQEAwIBBjANBgkqhkiG 9w0BAQQFAAOB
gQBzG28mZYv/FTRLWWKK7US+ScfoDbuPuQ1qJipihB+4h2N0HG23zxpTkUvh zeY42e1Q9Dps
NJKs5pKcbsEjAcIJp+9LrnLdBmf1UG8uWLi2C8FQV7XsHNfvF7bViJu3ooga 7TlbOX00/LaW
GCVNavSdxcORL6mWuAU8Uvzd6WIDSDGCAcowggHGAgEBMIGaMIGSMQswCQYD VQQGEwJaQTEV
MBMGA1UECBMMV2VzdGVybiBDYXBlMRIwEAYDVQQHEwlDYXBlIFRvd24xDzAN BgNVBAoTBlRo
YXd0ZTEdMBsGA1UECxMUQ2VydGlmaWNhdGUgU2VydmljZXMxKDAmBgNVBAMT H1BlcnNvbmFs
IEZyZWVtYWlsIFJTQSAyMDAwLjguMzACAwTI7DAJBgUrDgMCGgUAoIGGMBgG CSqGSIb3DQEJ
AzELBgkqhkiG9w0BBwEwHAYJKoZIhvcNAQkFMQ8XDTAyMDUwMzExNDM0NFow IwYJKoZIhvcN
AQkEMRYEFEqY5rQmTZsYO3uHwb5eodX7G9FgMCcGCSqGSIb3DQEJDzEaMBgw BwYFKw4DAgcw
DQYIKoZIhvcNAwICASgwDQYJKoZIhvcNAQEBBQAEgYBdEXdaV20ygfHKauTP SvCN2pgnodvo
qRG0RtFR4d8qYazbZ1kzpVznj4SWNAtoHi8zgETTvzn+dtzIe9EgpqjheAj/ LhdVGJ4QTnCo
ROj1Gm0r1OBH1ewWmSKpkqj5mtZLwLYREbaZ+sEfpFkS6w6/zJjD7tLvmkIz pUz8x/5wtQ==
--------------msC2354F9614640063AA48C2D3--

RE : Proxied output is corrupted by extraneous numbers

am 03.05.2002 14:59:16 von Gael Seroul

HI,
I think the HTML page you create via the front end proxy server is =
serving using chunked encoding (new support for HTTP/1.1 for mod_proxy =
since 1.3.23).

Gael



> -----Message d'origine-----
> De : Michael E. Lewis [mailto:mlewis@comprehend.com]=20
> Envoy=E9 : vendredi 3 mai 2002 13:24
> =C0 : modproxy-dev@apache.org
> Objet : Proxied output is corrupted by extraneous numbers
>=20
>=20
> Hello,
>=20
> While preparing to upgrade our production servers, I=20
> encountered a problem that may involve mod_proxy code. When=20
> html code is generated and printed by our mod_perl handler=20
> initiated directly from the back end the output is correct. =20
> When the same operation is initiated via the front end proxy=20
> server the output is corrupted by extraneous numbers. I have=20
> set up a test scenario to isolate the problem. Our new=20
> server configurations include this software:
>=20
> Front End Back End
> --------- --------
> kernel-2.4.9-31 kernel-2.4.9-31
> apache_1.3.24 apache_1.3.24
> mod_ssl-2.8.8-1.3.24 mod_perl-1.26
> openssl-0.9.6c
> mm-1.1.3
>=20
> The front end apache configuration includes:
>=20
>
> ServerName gelco5.yvod.com
> DocumentRoot /www/gelcompany/html
>=20
> RewriteEngine On
> RewriteLogLevel 9
> RewriteOptions 'inherit'
>=20
> RewriteRule ^/$ http://192.168.20.111:8089/ [proxy,last]
>=20
> RewriteRule ^/(.+)$ /www/gelcompany/html/$1 [last]
>

>=20
> The back end apache configuration includes:
>=20
> NameVirtualHost 192.168.20.111:8089
> Listen 8089
>
> ServerName gelco5.yvod.com
> DocumentRoot /www/gelcompany/html
>=20
> Alias / /www/gelcompany/modperl
>=20
>
> SetHandler perl-script
> PerlHandler YVOD::welcome
>

>

>=20
> The test handler code looks like this:
>=20
> #!/usr/bin/perl -w -d
> package YVOD::welcome;
> use strict;
>=20
> sub handler{
> my $r =3D shift;
> $r->send_http_header('text/html');
> print qq|\n|;
> print "You are Welcome at ", $r->get_remote_host,=20
> "

\n";
> while (my ($key, $val) =3D each %ENV) {
> print "$key =3D $val
\n"; }
> print "";
> return 1;
> }
> 1;
>=20
> The outout source looks like this when initiated directly=20
> from the back end (http://192.168.20.111:8089/):
>=20
>
> You are Welcome at 192.168.20.98


> QUERY_STRING =3D

> HTTP_ACCEPT_LANGUAGE =3D en

> TZ =3D PST8PDT

> REMOTE_PORT =3D 3201

> HTTP_USER_AGENT =3D Mozilla/4.76 [en] (X11; U; Linux=20
> 2.2.14-5.0 i686)

> HTTP_ACCEPT =3D image/gif, image/x-xbitmap, image/jpeg,=20
> image/pjpeg, image/png, */*

> HTTP_HOST =3D 192.168.20.111:8089

> GATEWAY_INTERFACE =3D CGI-Perl/1.1

> SCRIPT_NAME =3D /

> SERVER_NAME =3D gelco5.yvod.com

> HTTP_ACCEPT_ENCODING =3D gzip

> MOD_PERL =3D mod_perl/1.26

> HTTP_ACCEPT_CHARSET =3D iso-8859-1,*,utf-8

> HTTP_COOKIE =3D YVOD_SESSION_ID=3D2e4046b477f9374f

> SCRIPT_FILENAME =3D /www/gelcompany/modperl

> PATH =3D /bin:/usr/bin

> SERVER_ADDR =3D 192.168.20.111

> MOD_PERL_TRACE =3D all

> SERVER_PROTOCOL =3D HTTP/1.0

> HTTP_CONNECTION =3D Keep-Alive

> SERVER_SIGNATURE =3D

Apache/1.3.24 Server at=20
> gelco5.yvod.com Port 8089

>

> SERVER_SOFTWARE =3D Apache/1.3.24 (Unix) mod_perl/1.26

> SERVER_ADMIN =3D webmaster@yvod.com

> REMOTE_ADDR =3D 192.168.20.98

> DOCUMENT_ROOT =3D /www/gelcompany/html

> REQUEST_URI =3D /

> REQUEST_METHOD =3D GET

> SERVER_PORT =3D 8089

>
>=20
> The outout source looks like this when initiated via the=20
> front end proxy server (http://gelco5.yvod.com/):
>=20
> 49a
>
> You are Welcome at 192.168.20.111


> QUERY_STRING =3D

> HTTP_ACCEPT_LANGUAGE =3D en

> TZ =3D PST8PDT

> REMOTE_PORT =3D 2462

> HTTP_USER_AGENT =3D Mozilla/4.76 [en] (X11; U; Linux=20
> 2.2.14-5.0 i686)

> HTTP_ACCEPT =3D image/gif, image/x-xbitmap, image/jpeg,=20
> image/pjpeg, image/png, */*

> HTTP_HOST =3D 192.168.20.111:8089

> GATEWAY_INTERFACE =3D CGI-Perl/1.1

> SCRIPT_NAME =3D /

> SERVER_NAME =3D gelco5.yvod.com

> HTTP_ACCEPT_ENCODING =3D gzip

> MOD_PERL =3D mod_perl/1.26

> HTTP_ACCEPT_CHARSET =3D iso-8859-1,*,utf-8

> HTTP_VIA =3D 1.0 gelco5.yvod.com (Apache/1.3.24)

> SCRIPT_FILENAME =3D /www/gelcompany/modperl

> PATH =3D /bin:/usr/bin

> HTTP_X_FORWARDED_FOR =3D 192.168.20.96

> SERVER_ADDR =3D 192.168.20.111

> MOD_PERL_TRACE =3D all

> SERVER_PROTOCOL =3D HTTP/1.1

> HTTP_CONNECTION =3D close

> SERVER_SIGNATURE =3D
Apache/1.3.24 Server at=20
> gelco5.yvod.com Port 8089

>

> SERVER_SOFTWARE =3D Apache/1.3.24 (Unix) mod_perl/1.26

> SERVER_ADMIN =3D webmaster@yvod.com

> REMOTE_ADDR =3D 192.168.20.111

> DOCUMENT_ROOT =3D /www/gelcompany/html

> REQUEST_URI =3D /

> REQUEST_METHOD =3D GET

> SERVER_PORT =3D 8089

>
> 0
>=20
> In the second case, there is about a 15 second delay before=20
> the '0' prints at the bottom of the display and 'Document=20
> Done.' is indicated. The number that prints at the beginning=20
> changes depending upon the content (it may be a length=20
> value), but the number at the end is always '0'. Also, the=20
> following messages are written to error_log:
>=20
> [Fri May 3 03:42:39 2002] [debug] proxy_cache.c(1026):
> Request for http://192.168.20.111:8089/,=20
> pragma_req=3Dno-cache, ims=3D0
> [Fri May 3 03:42:39 2002] [debug] proxy_util.c(1401):
> File /opt1/httpd_docs/proxy/A/a/R/8dpIO_pSaxiSOa1CyWg not found
> [Fri May 3 03:42:39 2002] [debug] proxy_cache.c(1280):
> Local copy not present or expired. Declining.
> [Fri May 3 03:42:49 2002] [debug] proxy_cache.c(1391):
> Response is not cacheable,
> unlinking /opt1/httpd_docs/proxy/A/a/R/8dpIO_pSaxiSOa1CyWg
> [Fri May 3 03:42:49 2002] [debug] proxy_http.c(583):
> Content-Type: text/html
>=20
> Although I've abbreviated it for testing, the basic=20
> configuration is the same as I've been using in production=20
> for over two years, but it's quite possible that the source=20
> of the problem is in the configuration. It's also possible=20
> that the problem has nothing to do with mod_proxy - it could=20
> be related to Apache::PRINT. If you can provide any help I=20
> would be very grateful as I've been pounding at this for=20
> several days now. And if there is any other info I can get=20
> for you please let me know.
>=20
> Thanks, Michael...
> --=20
> Michael E. Lewis YVOD, LLC / Comprehend.Com Phone:=20
> 510-655-3974
> mlewis@comprehend.com 5816 Ocean View Drive Cell: =20
> 510-435-3180
> michael@yvod.com Oakland, CA 94618-1535 Fax: =20
> 419-781-9206
>=20

Re: Proxied output is corrupted by extraneous numbers - WAS: proxy for HTTP 1.0 clients

am 03.05.2002 20:58:18 von mlewis

I should have dug a little deeper into the archives.

Go to this URL: http://www.apache.org/mail/modproxy-dev/200204.gz
And search for: proxy for HTTP 1.0 clients


Graham Leggett wrote: (on 05/03/2002)
>
> This problem is fixed in v1.3.25-dev in CVS - I've asked that a new
> release of Apache be made, which should be ready in about a week or so
> (according to the release manager...).
>
> In the mean time, the latest CVS version of apache will solve the
> problem.

And: (on 04/10/2002)
> The 1.3.24 proxy did not know how to dechunk incoming responses from
> HTTP/1.1 servers, which meant the chunked encoding was being sent as is
> to the client. If the client was HTTP/1.1 it didn't complain, but
> obviously HTTP/1.0 clients have a problem. Now the proxy dechunks
> incoming chunked responses as required by RFC2616.


"Michael E. Lewis" wrote:
>
> While preparing to upgrade our production servers, I encountered
> a problem that may involve mod_proxy code. When html code is
> generated and printed by our mod_perl handler initiated directly
> from the back end the output is correct. When the same operation
> is initiated via the front end proxy server the output is corrupted
> by extraneous numbers. I have set up a test scenario to isolate
> the problem. Our new server configurations include this software:
>
> Front End Back End
> --------- --------
> kernel-2.4.9-31 kernel-2.4.9-31
> apache_1.3.24 apache_1.3.24
> mod_ssl-2.8.8-1.3.24 mod_perl-1.26
> openssl-0.9.6c
> mm-1.1.3
>
> The front end apache configuration includes:
>
>
> ServerName gelco5.yvod.com
> DocumentRoot /www/gelcompany/html
>
> RewriteEngine On
> RewriteLogLevel 9
> RewriteOptions 'inherit'
>
> RewriteRule ^/$ http://192.168.20.111:8089/ [proxy,last]
>
> RewriteRule ^/(.+)$ /www/gelcompany/html/$1 [last]
>

>
> The back end apache configuration includes:
>
> NameVirtualHost 192.168.20.111:8089
> Listen 8089
>
> ServerName gelco5.yvod.com
> DocumentRoot /www/gelcompany/html
>
> Alias / /www/gelcompany/modperl
>
>
> SetHandler perl-script
> PerlHandler YVOD::welcome
>

>

>
> The test handler code looks like this:
>
> #!/usr/bin/perl -w -d
> package YVOD::welcome;
> use strict;
>
> sub handler{
> my $r = shift;
> $r->send_http_header('text/html');
> print qq|\n|;
> print "You are Welcome at ", $r->get_remote_host, "

\n";
> while (my ($key, $val) = each %ENV) {
> print "$key = $val
\n"; }
> print "";
> return 1;
> }
> 1;
>
> The output source looks like this when initiated directly from the
> back end (http://192.168.20.111:8089/):
>
>
> You are Welcome at 192.168.20.98


> QUERY_STRING =

> HTTP_ACCEPT_LANGUAGE = en

> TZ = PST8PDT

> REMOTE_PORT = 3201

> HTTP_USER_AGENT = Mozilla/4.76 [en] (X11; U; Linux 2.2.14-5.0 i686)

> HTTP_ACCEPT = image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
> image/png, */*

> HTTP_HOST = 192.168.20.111:8089

> GATEWAY_INTERFACE = CGI-Perl/1.1

> SCRIPT_NAME = /

> SERVER_NAME = gelco5.yvod.com

> HTTP_ACCEPT_ENCODING = gzip

> MOD_PERL = mod_perl/1.26

> HTTP_ACCEPT_CHARSET = iso-8859-1,*,utf-8

> HTTP_COOKIE = YVOD_SESSION_ID=2e4046b477f9374f

> SCRIPT_FILENAME = /www/gelcompany/modperl

> PATH = /bin:/usr/bin

> SERVER_ADDR = 192.168.20.111

> MOD_PERL_TRACE = all

> SERVER_PROTOCOL = HTTP/1.0

> HTTP_CONNECTION = Keep-Alive

> SERVER_SIGNATURE =

Apache/1.3.24 Server at gelco5.yvod.com Port
> 8089

>

> SERVER_SOFTWARE = Apache/1.3.24 (Unix) mod_perl/1.26

> SERVER_ADMIN = webmaster@yvod.com

> REMOTE_ADDR = 192.168.20.98

> DOCUMENT_ROOT = /www/gelcompany/html

> REQUEST_URI = /

> REQUEST_METHOD = GET

> SERVER_PORT = 8089

>
>
> The output source looks like this when initiated via the front end
> proxy server (http://gelco5.yvod.com/):
>
> 49a
>
> You are Welcome at 192.168.20.111


> QUERY_STRING =

> HTTP_ACCEPT_LANGUAGE = en

> TZ = PST8PDT

> REMOTE_PORT = 2462

> HTTP_USER_AGENT = Mozilla/4.76 [en] (X11; U; Linux 2.2.14-5.0 i686)

> HTTP_ACCEPT = image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
> image/png, */*

> HTTP_HOST = 192.168.20.111:8089

> GATEWAY_INTERFACE = CGI-Perl/1.1

> SCRIPT_NAME = /

> SERVER_NAME = gelco5.yvod.com

> HTTP_ACCEPT_ENCODING = gzip

> MOD_PERL = mod_perl/1.26

> HTTP_ACCEPT_CHARSET = iso-8859-1,*,utf-8

> HTTP_VIA = 1.0 gelco5.yvod.com (Apache/1.3.24)

> SCRIPT_FILENAME = /www/gelcompany/modperl

> PATH = /bin:/usr/bin

> HTTP_X_FORWARDED_FOR = 192.168.20.96

> SERVER_ADDR = 192.168.20.111

> MOD_PERL_TRACE = all

> SERVER_PROTOCOL = HTTP/1.1

> HTTP_CONNECTION = close

> SERVER_SIGNATURE =
Apache/1.3.24 Server at gelco5.yvod.com Port
> 8089

>

> SERVER_SOFTWARE = Apache/1.3.24 (Unix) mod_perl/1.26

> SERVER_ADMIN = webmaster@yvod.com

> REMOTE_ADDR = 192.168.20.111

> DOCUMENT_ROOT = /www/gelcompany/html

> REQUEST_URI = /

> REQUEST_METHOD = GET

> SERVER_PORT = 8089

>
> 0
>
> In the second case, there is about a 15 second delay before the '0'
> prints at the bottom of the display and 'Document Done.' is indicated.
> The number that prints at the beginning changes depending upon the
> content (it may be a length value), but the number at the end is
> always '0'. Also, the following messages are written to error_log:
>
> [Fri May 3 03:42:39 2002] [debug] proxy_cache.c(1026):
> Request for http://192.168.20.111:8089/, pragma_req=no-cache, ims=0
> [Fri May 3 03:42:39 2002] [debug] proxy_util.c(1401):
> File /opt1/httpd_docs/proxy/A/a/R/8dpIO_pSaxiSOa1CyWg not found
> [Fri May 3 03:42:39 2002] [debug] proxy_cache.c(1280):
> Local copy not present or expired. Declining.
> [Fri May 3 03:42:49 2002] [debug] proxy_cache.c(1391):
> Response is not cacheable,
> unlinking /opt1/httpd_docs/proxy/A/a/R/8dpIO_pSaxiSOa1CyWg
> [Fri May 3 03:42:49 2002] [debug] proxy_http.c(583):
> Content-Type: text/html
>
> Although I've abbreviated it for testing, the basic configuration
> is the same as I've been using in production for over two years,
> but it's quite possible that the source of the problem is in the
> configuration. It's also possible that the problem has nothing to
> do with mod_proxy - it could be related to Apache::PRINT. If you
> can provide any help I would be very grateful as I've been pounding
> at this for several days now. And if there is any other info I can
> get for you please let me know.
>
> Thanks, Michael...

--
Michael E. Lewis YVOD, LLC / Comprehend.Com Phone: 510-655-3974
mlewis@comprehend.com 5816 Ocean View Drive Cell: 510-435-3180
michael@yvod.com Oakland, CA 94618-1535 Fax: 419-781-9206