Since turning off logging for IIS 7 folders or files is not as straight forward (or intuitive) as it is in IIS 6. I thought I would post the steps here. For IIS 6 you can follow the instructions in this MS Knowledge Base Article.
Disable IIS logging for a folder
- Open up IIS 7 Manager
- Expand the website in the left pane to see the folder structure.
- Click on the folder name to select it.
- Double click on the Logging entry in the folder home page.
- Click the Disable link under Actions on the right pane.
Disable IIS Logging for a file
The steps for a file are almost identical for an individual file.
- After you select the folder where the file resides, click the Content View at the bottom of the middle pane to see all the contents of the folder.
- Select the file that you want, then click Switch to Features view under Actions on the right pane.
- Then follow same last two steps as above to turn off Logging for that file.