IIS7 post #42 – Flush log buffer immediately to disk

This is a handy feature I discovered in Windows Server 2008.  You can force http.sys to flush cached log entries immediately to disk.  The next time you are waiting for requests to flush to your IISLogs, go to the command prompt and type

netsh http flush logbuffer 
You’ll see an Ok.  

Then open your log files and your entries should be present.

Take care,


4 thoughts on “IIS7 post #42 – Flush log buffer immediately to disk”

  1. Good info.

    I was wondering if there’s any way to have IIS write the logs in multiple locations. Basically, I want to implement the real-time stats and the closest I can get using IIS logs is hourly.

    Can you think of any other way (except writing my own HttpModule and every request would parse through that)?


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: