http://www.microsoft.com/technet/scriptcenter/tools/logparser/lpexamples.mspx
http://forums.iis.net/default.aspx?GroupID=51
http://128.175.24.251/forensics/logparser.htm
logparser.exe -i:EVT -o:DATAGRID “SELECT TimeGenerated, EventID, message FROM System”
http://blogs.iis.net/chrisad/archive/2006/07/13/Chris.aspx
http://www.codinghorror.com/blog/archives/000369.html
Slowest 10 pages
SELECT TOP 10 cs-uri-stem AS Url, MIN(time-taken) as [Min],
AVG(time-taken) AS [Avg], max(time-taken) AS [Max],
count(time-taken) AS Hits
FROM ex*.log
WHERE time-taken < 120000
GROUP BY Url
ORDER BY [Avg] DESC
WIN32 errors in IIS log
SELECT cs-uri-stem AS Url,
WIN32_ERROR_DESCRIPTION(sc-win32-status) AS Error, Count(*) AS Total
FROM ex*.log
WHERE (sc-win32-status > 0)
GROUP BY Url, Error
ORDER BY Total DESC
http://www.lazydba.com/sql/1__21454.html
LogParser “select STRCAT(STRCAT(DATE,’ ‘), TIME) as LogDateTime, SOURCE,
Message From ‘c:\program files\Microsoft SQL Server\mssql\log\ERRORLOG.1′”
-i:TSV -iseparator:spaces -iHeaderFile:c:\formatfile.txt -headerRow:OFF
-nskiplines:9
LogParser “select STRCAT(STRCAT(DATE,’ ‘), TIME) as LogDateTime, SOURCE,
Message INTO MY_ERROR_LOG_TABLE From ‘c:\program files\Microsoft SQL
Server\mssql\log\ERRORLOG.1′” -i:TSV -iseparator:spaces
-iHeaderFile:c:\formatfile.txt -headerRow:OFF -nskiplines:9 -o:SQL
-server:LAZYDEVELOPER -database:Pubs -driver:”SQL Server”
-username:TestSQLUser -password:TestSQLPassword -createTable:ON
SELECT Area AS [Area], Category AS [Category], Level AS Level], COUNT(*) AS [Count] INTO %COMPUTER_NAME%-area-category-level.tsv FROM %COMPUTER_NAME%-*.log GROUP BY Area, Category, Level HAVING [COUNT] > 1000 ORDER BY [Count] DESC
LogParser -i:tsv -o:tsv file:area-category-level.sql?COMPUTER_NAME=mossidx01