简体   繁体   中英

Old Asp.Net web forms app does not log web requests arriving via IIS URL Rewrite module

We maintain an old Asp.Net Web Forms application used by thousands of clients. The application (upgraded to .NET 4.5.2) writes logs via NLog(v.4.4.10), abstracted by LibLog(v.4.2). No problems here.

One important client requested to have its own custom URL to our app. We provided this though the following steps:

  1. Added the new URL to our DNS server;
  2. Created new virtual web site in IIS (v.8.5), pointing to an empty physical folder;
  3. On the new web site added binding to the special client's URL;
  4. In the the empty folder we added new web.config with a special URL rewrite rule. The rule redirects web requests to the original fully qualified URL.

All of the above works fine, requests are being redirected and processed. IIS logs look fine too. However, no application logs are written for these redirected requests.

  • We know that logs are not created anywhere else on the server, so most likely this seems like some sort of permission issue.
  • We tried playing with application pools and identity - did not help.
  • We looked into physical folder permissions - everything is identical to the original web site.

What makes the application logs to disappear? Any thoughts would be helpful. Many thanks in advance.

It's been a while since we found out what the problem was. It appears that two different applications pools were mistakenly used at the same time - one for original web site and another one for the new web site. Once we started to use the same app pool name for both, the logs started to come in.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM