You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by dan sutton <da...@gmail.com> on 2011/09/07 11:26:37 UTC

logging client ip address

Hi,

We're using log4j with solr which is working fine and I'm wondering
how I might be able to log the client ip address?

Has anyone else been able to do this?

Cheers,
Dan

Re: logging client ip address

Posted by Markus Jelsma <ma...@openindex.io>.
You could configure your proxy or application to send any key/value pair not 
being using by Solr. Solr will ignore the parameter but still log it as part 
of params={}.

We use this to send various pieces of information that's being analyzed later 
together with the query information.

On Wednesday 07 September 2011 13:09:53 dan sutton wrote:
> Does anyone know how I would be able to include the client ip address
> for tomcat 6 with log4j?
> 
> Cheers,
> Dan
> 
> On Wed, Sep 7, 2011 at 11:03 AM, Shalin Shekhar Mangar
> 
> <sh...@gmail.com> wrote:
> > On Wed, Sep 7, 2011 at 2:56 PM, dan sutton <da...@gmail.com> wrote:
> >> Hi,
> >> 
> >> We're using log4j with solr which is working fine and I'm wondering
> >> how I might be able to log the client ip address?
> >> 
> >> Has anyone else been able to do this?
> > 
> > Your application container should have an access log facility. That is
> > the best way to record client IPs. Solr does not have that capability.
> > 
> > --
> > Regards,
> > Shalin Shekhar Mangar.

-- 
Markus Jelsma - CTO - Openindex
http://www.linkedin.com/in/markus17
050-8536620 / 06-50258350

Re: logging client ip address

Posted by dan sutton <da...@gmail.com>.
Does anyone know how I would be able to include the client ip address
for tomcat 6 with log4j?

Cheers,
Dan

On Wed, Sep 7, 2011 at 11:03 AM, Shalin Shekhar Mangar
<sh...@gmail.com> wrote:
> On Wed, Sep 7, 2011 at 2:56 PM, dan sutton <da...@gmail.com> wrote:
>
>> Hi,
>>
>> We're using log4j with solr which is working fine and I'm wondering
>> how I might be able to log the client ip address?
>>
>> Has anyone else been able to do this?
>>
>
> Your application container should have an access log facility. That is the
> best way to record client IPs. Solr does not have that capability.
>
> --
> Regards,
> Shalin Shekhar Mangar.
>

Re: logging client ip address

Posted by Shalin Shekhar Mangar <sh...@gmail.com>.
On Wed, Sep 7, 2011 at 2:56 PM, dan sutton <da...@gmail.com> wrote:

> Hi,
>
> We're using log4j with solr which is working fine and I'm wondering
> how I might be able to log the client ip address?
>
> Has anyone else been able to do this?
>

Your application container should have an access log facility. That is the
best way to record client IPs. Solr does not have that capability.

-- 
Regards,
Shalin Shekhar Mangar.