I've got a problem with my IIS (10.0.14393.0), that I've never seen before.
I used a standard installation for it, and didn't touch the logging options. Still though, it never writes logs during the day. Instead ALL of the logs for the whole day are written in one go at around 2 AM every day.
What option am I overlooking here and thus how can I change it to normal continuous log writing (instead of a whole day in one go) ?
答案1
Open IIS Manager.
In the Connections tree view, select your website.
In Features View, double-click Logging.
In the Log File Rollover section, select one of the following options:
Schedule: to create new log file that is based on one of the following values:
- Hourly: a new log file is created each hour.
- Daily: a new log file is created each day.
- Weekly: a new log file is created each week.
- Monthly: a new log file is created each month.
Maximum file size (in bytes): to create a log file when the file reaches a certain size (in bytes).The minimum file size is 1048576 bytes. If this attribute is set to a value less than 1048576 bytes, the default value is implicitly assumed as 1048576 bytes.
Do not create a new log file: there is a single log file that continues to grow as information is logged.
https://docs.microsoft.com/en-us/iis/manage/provisioning-and-managing-iis/configure-logging-in-iis
(emphasis mine)