Home > Windows Tips > > On the Microsoft Log Parser
Win IT Tips:
EMAIL THIS
 TIPS & NEWSLETTERS TOPICS 


On the Microsoft Log Parser


Serdar Yegulalp
12.24.2003
Rating: -4.11- (out of 5)


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


Many of Microsoft's best and most powerful utilities go almost unnoticed, and the Log Parser is certainly one of the best (and most overlooked). Log Parser 2.0 is a command-line program that allows a user or administrator to run SQL-like queries against log files of almost any format currently in use. The results can be reported to the console, to a flat text file or to a SQL/ODBC database. The program itself is free of charge.

Scanned logs can be in any of the following formats:

The syntax for using the Log Parser is essentially the standard SQL syntax, with each input source treated as a relational table. Each field is a table column with an appropriate auto-assigned data type (STRING, INTEGER, REAL or TIMESTAMP). Queries can either be passed on the command line or specified in a file. Log Parser also supports conversion between any of the above log types; a SQL log could be converted into a CSV, or vice versa.

Log Parser contains a number of unique and powerful features. The Multiplex feature allows the multiple files to be piped in or out as either source or target tables; this would allow, for instance, event log messages to be written out to di


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   


RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary


fferent files according to the event source. It is also possible to take piped input from STDIN, but only by using the IISMSID log format:

type iis5.log | LogParser "SELECT * from stdin" –i:IISMSID

This would pipe the file iis5.log into Log Parser using stdin as the SELECT...FROM table criterion.

Log Parser also includes a .DLL / COM-architecture version of the program, which allows it to be used by programming languages such as C++, Visual Basic or VBScript. A Web programmer could use Log Parser to produce a Web-based programmatic front-end for analyzing a Web server's own logs. With Log Parser, this is possible without having to spend money on a third-party solution or write complicated homebrew data-mining code.

The program and its associated documentation can be downloaded here. Note that the IIS 6.0 Resource Kit already contains Log Parser in its 2.1 incarnation.


Serdar Yegulalp is the editor of the Windows 2000 Power Users Newsletter. Check out his Windows 2000 blog for his latest advice and musings on the world of Windows network administrators – please share your thoughts as well!


Rate this Tip
To rate tips, you must be a member of SearchWinIT.com.
Register now to start rating these tips. Log in if you are already a member.




DISCLAIMER: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.



Windows Technology Updates, Reviews and Solutions

Laptop Discounts with free coupon codes, huge savings at Notebook Review

HomeNewsTopicsITKnowledge ExchangeTipsAsk the ExpertsMultimediaWhite PapersIT Downloads
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 1999 - 2009, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts