Reputation: 13277
I'd like to use my IIS logs to track sessions in my app, but don't have a session key being pushed along the querystring in my pages.
What's the easiest way to start tracking that in the log - put a querystring value in the iis logs, or is there a way to append session to the logs as a custom field?
Using 32-bit classic asp against windows server 2003 64-bit.
Upvotes: 0
Views: 1877
Reputation: 155433
IIS (since version 5, at least) lets you log cookies in the "W3C Extended" log file format. Add the "cs-cookie" field to your logs and restart your website, they'll appear there.
You will need log analysis software that supports tracing sessions via the cs-cookie field, however - but it largely isn't necessary as most log analysis follows paths-through-site and sessions by tracing the cs-referer header instead.
If you have large cookie strings then expect your site log files to balloon in size.
Upvotes: 1