in regards to Caching reverse squid proxy with debian

Discussion in 'HOWTO-Related Questions' started by nux, Feb 10, 2009.

  1. nux

    nux New Member

    Hey, I have a question that resulted from this howto:

    http://www.howtoforge.com/how-to-set-up-a-caching-reverse-proxy-with-squid-2.6-on-debian-etch

    I am trying to process logs passed to apache from squid with the X-Forwarded-For header.

    The issue is sometimes it sends multiple IP addresses, and I want to limit it to sending just the external (or the farthest right) IP. I just want to properly parse the logs with awstats.

    Not exactly sure how I would do this.

    Any suggestions would be appreciated.

    Thanks
     
  2. falko

    falko Super Moderator

    That's a good question. I think you could write a shell script that processes your access log and deletes the second, third, fourth... IP before awstats uses the access log to create its stats.
     

Share This Page