I have an Azure App Service that contains 1 Web App with 1 slot. I have 2 instances assigned to the App Service. This week, the App Service shows about 60% CPU usage, and its usually about 10-15%. Upon further investigation, it looks like 1 of the two instances is maxed out. When opening up the Site Metrics per Instance, I can see that HTTP Response times are in the 1000s of milliseconds for one instance, and less than 200ms for the other. I have tried restarting the W3P process on the offending instance, but that doesn't seem to help. I have also tried scaling up to additional instances. The new instances look good, but when I scale back down, the fabric won't kill the offending instance.
How can I force the fabric controller to kill off a specific instance?
I found the AzureRestartRole powershell command here (https://msdn.microsoft.com/en-us/library/azure/dn495202.aspx), but my Azure Powershell Command Prompt doesn't seem to recognize the command, so I tried upgrading to Azure SDK 1.3 with the install-module command, but the 'AzureRestartRole' command isn't found.
From the Azure Portal, navigate to List of App Services Pages. You can easily get there if you have App Services pined in your favorites menu. Select the checkboxes for the App services to stop or restart. That's it.
What is an Azure Instance? Simply put, an instance in Azure can be understood as a Virtual Machine. Microsoft Azure Websites can be defined as a high-density, multi-tenancy platform.
To restore to a new app, select Create new under the App Service box. To restore to a new deployment slot, select Create new under the Deployment slot box. If you choose an existing slot, all existing data in its file system is erased and overwritten. The production slot has the same name as the app name.
I recently encounter a similar issue (one bad instance always read null from ConfigurationManager.AppSettings
while the other instance was fine). I found that restarting a particular instance of a Azure App service (web app) is do-able from the Azure portal. :D
Updated Aug 16th, 2019:
The short version is that if you go in the portal for your web app under Diagnose and Solve Problems, search for Advanced Application Restart and you will get an option that allows you to pick just the instance you want.
Hope that helps.
the commandlet you mentioned is not supposed to be used with the Azure App Service, but with the Azure Cloud Services and role model, so you do not need it here. Azure SDK 1.3 is very old as well, today the latest is 2.9.
Next, try to use Auto-Healing feature - it is difficult to understand why your web app is so resources consuming, especially if you tried to restart the W3WP (did you kill it in the Process Explorer of the dashboard?), so built-in feature can be helpful.
And you can find the webapp id and execute PowerShell, for example, Stop and Start it. If that will not help, i would suggest to re-create the instance.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With