UPDATED as of 5/22/2017:
Nearly everything has changed. This information is no longer valid. The App Service update in April 2017 moved the location of most of the troubleshooting tools. The post linked above contains some details, but for the most part, you can fine these under the
Diagnose and Solve problems section. If you are running in the main app (not a Slot), then it will show up in the
Tools section. If you are running in a Slot, then is shows up under the,
Diagnose and Solve problems will say it is not available, and a link to the
event logs will show up under the FAQ entitled "My App is returning HTTP 5xx errors".
UPDATED with new location as of 9/1/2016
Every now and then, I need to view the application logs (think the Windows Event Viewer) on our Azure Web App. And every time, I spend about 15 minutes trying to find it in the "New" Azure Portal. Typically, I can't find it, then spend a few more minutes googling for it. Documentation on this sort of thing is all over the place. Search results sure talk about it, but none of them seem to show how to do this in the Portal. They are usually:
- How to get them via PowerShell
- How to get it from the logging file system
- How to enable / disable them
- View them in Azure Table Storage
On top of that, if you do find something, it talks about the old Azure Portal, or if you are lucky the new one - but everything has moved since the post. This is a recurring pattern in Azure Documentation that is a major problem in my mind - but alas, that's not a topic for this post. I am sure this post will be outdated soon too.
Enable Application Logging
In order to even view the section in the Portal where Application Logs will appear, you have to turn it on first.
In your Web Application, click on
Settings in the toolbar.
The Settings blade will open up. In your Web Application, scroll towards the bottom of the list of actions, look under the
MONITORING section for
A new blade will open, at the top, choose
Application Logging (Filesystem). I guess by turning this on, it writes the logs to disk, but also enables the Viewer in the portal. Obviously you can set the level too in the dropdown below the setting.
Click Save in the toolbar.
Viewing the Application Events
Go to the parent Settings blade, and scroll back up. Look for the
SUPPORT + TROUBLESHOOTING section, and the
Application Events entry.
Sometimes, it takes a few seconds for this entry to show up. It just pops into the middle of the
SUPPORT + TROUBLESHOOTING list, so beware.
There you have it. You'll see a standard looking Application Event Log. Clicking on each log, an additional pane will open with the details.
Hope this helps, and for future me - hope this saved you time!