... for the quotes simply use the predefined xml entity:
"
Maurice Yarrow schrieb:
> Hello, again, Tomcat community:
>
> I found the answer to my own question below:
> Use:
>
> pattern="%{X-Forwarded-for}i %l %u %t %r %s %b"
>
> in the access log valve config.
>
> Only thing: I would like to surround the %r with "%r", as
> is done in the "common" setup.
> What byzantine combination of single quote, double quote,
> backslashes is required for this to be acceptable to the
> serverl.xml XML readin ? (I tried a whole bunch of different
> combinations but all error'ed out on startup.)
>
> Maurice
>
>
>
>
> Maurice Yarrow wrote:
>
>> Hello Tomcat community
>>
>> I have tomcat (5.0.28) running behind pound (2.1.3)
>> reverse-proxy-load-balancer.
>>
>> This is a very effective setup, as I have pound also fronting apache
>> and mongrel-rails
>> clusters.
>>
>> Question:
>> Pound adds the following to its request to backend servers:
>> X-Forwarded-for: client-IP-address
>>
>> I would like to be able to obtain this client-IP address in the tomcat
>> access logs.
>> I tried all available formats (%a, %A, %b, %B, etc.,etc.) for the
>> logger pattern,
>> but of course, none produced the client IP address placed in the
>> request by
>> Pound.
>> I could, of course, grep through the Pound log output which, by
>> default, winds
>> up on /var/log/messages, but would rather just be able to see this in the
>> tomcat access log.
>>
>> How could I, say, derive my own logger class and capture this header
>> info that
>> pound places in the request to backend server ??
>>
>> Is there a simpler way ? Am I unaware of a direct way to do this ?
>>
>> Maurice Yarrow
>>
>>
>> ---------------------------------------------------------------------
>> To start a new topic, e-mail: [email protected]
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: [email protected]
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To start a new topic, e-mail: [email protected]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]