|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
IIS6 logging
Is there any way of changing the order of the columns in the IIS6 log? I'm trying to merge data from IIS5 and IIS6 for awstats, but awstats cannot recongize both (as it's setup for IIS5)
Can anyone help? |
|
#2
|
|||
|
|||
|
I don't have a clue on this one, sorry.
Maybe try altering the stats program rather than iis?
__________________
====== Doug G ====== "Hide, hide witch! The good folk come to burn thee. Their keen enjoyment hid behind their gothic mask of duty." -Mark Clifton |
|
#3
|
||||
|
||||
|
Found a crude but adequate solution
There's a tool in the IIS6 resource kit called logparser that has the ability to read in logs, transform them and spit them out again Here's the batch file I came up with: Code:
@echo off
for /f "tokens=1-3 delims=/ " %%a in ('doff mm/dd/yy -1') do (
set mm=%%a
set dd=%%b
set yy=%%c)
@echo on
cd "c:\logs\w3svc1\"
"c:\program files\iis resources\log parser\logparser.exe" -i:IISW3C -o:W3C "Select date, time, c-ip, cs-username, s-ip, s-port, cs-method, cs-uri-stem, cs-uri-query, sc-status, sc-bytes, cs-bytes, time-taken, cs-host, cs(User-Agent), cs(Referer) From ex%yy%%mm%%dd%.log to ez%yy%%mm%%dd%.log"
I run this batch file at 12:10am (10 mins after IIS has rolled over to the next log file) IIS6 Resource kit: http://www.microsoft.com/downloads/details.aspx?FamilyID=56fc92ee-a71a-4c73-b628-ade629c89499&DisplayLang=en LogParser (standalone): http://www.microsoft.com/downloads/details.aspx?FamilyID=890cd06b-abf8-4c25-91b2-f8d975cf8c07&displaylang=en Doff (used for grabbing yesterday's date): http://www.jfitz.com/dos/ |
|
#4
|
|||
|
|||
|
Thanks for posting your solution!
|
![]() |
| Viewing: Dev Shed Forums > System Administration > IIS > IIS6 logging |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|