« Previous Next »

Thread: Missing Date Field in IISW3C logfile

Last post 01-11-2008 10:53 AM by dinder. 1 replies.

Average Rating Rate It (5)

RSS

Page 1 of 1 (2 items)

Sort Posts:

  • 01-11-2008, 10:21 AM

    • dinder
    • Not Ranked
    • Joined on 01-11-2008, 10:16 AM
    • Posts 2

    Missing Date Field in IISW3C logfile

    Hi

     I need to parse logfile from server, but notice that no Date Field are configure

    --------------

    #Software: Microsoft Internet Information Services 6.0
    #Version: 1.0
    #Date: 2008-01-06 00:01:02
    #Fields: time cs-method cs-uri-stem cs-uri-query cs-username c-ip cs-version cs(User-Agent) cs(Cookie) cs(Referer) sc-status sc-substatus sc-bytes cs-bytes time-taken
    00:01:02 GET /i.php - - 90.24.187.16 HTTP/1.1 Mozilla/4.0+(compatible;+MSIE+7.0;+Windows+NT+5.1;+.NET+CLR+1.1.4322;+InfoPath.2;+.NET+CLR+2.0.50727) - - 200 0 2587 427 62

    --------------------------

    I would like to use Logparser to rewrite my log, is it possible to extract the line 3 (#Date: 2008-01-06 00:01:02) to create and add the date field to my new file log ?

     

    Thks

  • 01-11-2008, 10:53 AM In reply to

    • dinder
    • Not Ranked
    • Joined on 01-11-2008, 10:16 AM
    • Posts 2

    Re: Missing Date Field in IISW3C logfile

    i found the answer on log Parser Help.

    i user the option -dirTime:ON

    "C:\Program Files\Log Parser 2.2\LogParser.exe" -i:IISW3C -o:W3C -dirTime:ON "select date,time,cs-method,cs-uri-stem,cs-uri-query,cs-username,c-ip,cs(User-Agent),cs(Cookie),cs(Referer),sc-status,sc-bytes from D:\works\NcNumericable\ex080106.log" -q > D:\works\NcNumericable\test\file.log

Page 1 of 1 (2 items)
Microsoft Communities