Current User: Guest Login Register
Please consider registering


Register? | Lost Your Password?

Search Forums:


 






Minimum search word length is 3 characters – Maximum search word length is 84 characters
Wildcard Usage:
*  matches any number of characters    %  matches exactly one character

problem with %{X-Forwarded-For}i log analyze

Reply to Post Add a New Topic
UserPost

3:39 am
July 13, 2009


unstable

Member

posts 3

hi

i set awstats 6.9 on my centos box, everything work fine.

but i find many recorde like this:

10.126.195.114, 218.207.218.135 – - [09/Jul/2009:00:00:58 +0800] “GET /comic/images/splogo/1244779732836.gif HTTP/1.1″ 200 1525 “-” “-”
10.126.195.114, 218.207.218.135 – - [09/Jul/2009:00:01:01 +0800] “GET /wapbbmf/images/gif-0086.gif HTTP/1.1″ 200 78 “-” “-”
10.126.195.114, 218.207.218.135 – - [09/Jul/2009:00:01:03 +0800] “GET /wapbbmf/images/home_05.gif HTTP/1.1″ 200 948 “-” “-”
10.126.195.114, 218.207.218.135 – - [09/Jul/2009:00:01:07 +0800] “GET /comic/images/titleImg/1244108920259.gif HTTP/1.1″ 200 450 “-” “-”
10.126.195.114, 218.207.218.135 – - [09/Jul/2009:00:01:10 +0800] “GET /comic/images/titleImg/1244108550585.gif HTTP/1.1″ 200 414 “-” “-”
10.126.195.114, 218.207.218.135 – - [09/Jul/2009:00:01:12 +0800] “GET /comic/images/titleImg/1244108772817.gif HTTP/1.1″ 200 445 “-” “-”
10.126.195.114, 218.207.218.135 – - [09/Jul/2009:00:01:16 +0800] “GET /comic/images/titleImg/1243826188535.gif HTTP/1.1″ 200 1502 “-” “-”

awstats only analyze fist ip,but this is not real ip i think, i need analyze last ip, any one help me?

apache log format:

LogFormat “%{X-Forwarded-For}i %l %u %t \\”%r\\” %>s %b \\”%{Referer}i\\” \\”%{User-Agent}i\\”" combined

TIA

ps: sorry my poor english:(

5:33 am
July 13, 2009


Jean-Luc

Admin

posts 1043

Hi,

We got this question already. Have a look at Apache LogFormat containing %{X-Forwarded-For}i. The solution is in the last post.

9:03 am
July 13, 2009


unstable

Member

posts 3

thank you reply

i already read this port and change awstats.pl but not work, any good idea?

elsif ( $f =~ /%host_proxy$/ )
{ # if host_proxy tag used, host tag must not be used
$pos_host = $i;
$i++;
push @fieldlib, 'host';
$PerlParsingFormat .= "(?:(?:(?:\\\\d+\\\\.\\\\d+\\\\.\\\\d+\\\\.\\\\d+),\\\\s)*(\\\\d+\\\\.\\\\d+\\\\.\\\\d+\\\\.\\\\d+))";
}

1:19 pm
July 13, 2009


Jean-Luc

Admin

posts 1043

As LogFormat  definition in the AWStats config file, I suggest this :

LogFormat = "%host_proxy %other %logname %time1 %methodurl %code %bytesd %refererquot %uaquot"

I hope it helps.

9:25 pm
July 13, 2009


unstable

Member

posts 3

thank u, it works nowLaugh

Reply to Post

Reply to Topic:
problem with %{X-Forwarded-For}i log analyze

Guest Name (Required):

Guest Email (Required):

NOTE: New Posts are subject to administrator approval before being displayed

Smileys
Confused Cool Cry Embarassed Frown Kiss Laugh Smile Surprised Wink Yell
Post New Reply

Guest URL (required)

Math Required!
What is the sum of:
3 + 7
   


About the InternetOfficer.com Forum

Forum Timezone: UTC 1

Most Users Ever Online: 201

Currently Online: Jean-Luc
18 Guests

Currently Browsing this Topic:
1 Guest

Forum Stats:

Groups: 2
Forums: 9
Topics: 498
Posts: 2380

Membership:

There are 2068 Members
There have been 245 Guests

There is 1 Admin
There is 1 Moderator

Top Posters:

cssfsu – 55
albert_newton – 30
deepakgupta – 28
cosminpana – 20
DTNMike – 19
ahtshun83 – 17

Recent New Members: Diggy, mopl91, henrique, ScottWigle, mgshirinda, andersondj

Administrators: Jean-Luc (1043 Posts)

Moderators: Jean-Luc (1043 Posts)