Azure cloud service app pool error - azure

I'm trying to update a cloud service deployment on azure.
I can deploy fine to a test cloud service.
However, when I try to deploy to our production cloud service's staging slot the publish to azure from visual studio completes with no errors but in azure I don't see the new deployment in the staging slot.
I have verified that it deployed to the staging slot instances because I can Remote Desktop into each of the servers and see the new code in IIS.
The only errors I see are on the servers, where there are IIS event warnings regarding:
The application / belonging to site xxx has an invalid AppPoolId.
Site xxx was disabled because the root application defined for the site is invalid.
A process serving application pool xxx terminated unexpectedly.
Sure enough, when I browse the website the old site is running and not the new one.
Greatly appreciate any pointers!

Making sure we are on the same page...
- if you RDP into the staging deployment, you can verify that new code has been published
- when you browse to the website, you see the old code.
A couple of things to check...
When you say 'browse to the website', do you mean you attempted to reach the website via (1) a custom domain that points to the xxxxx.cloudapp.net, (2) directly at xxxx.cloudapp.net, or (3) {some long guid}.cloudapp.net?
Did you attempt to perform a VIP SWAP, and if so, when you click on SWAP, does the portal correctly reflect the date and time that the staging was deployed?

Related

Azure Resources WebApp deployed but not accessible from url

I'm trying to access my app, hosted on azure.
I've a finished c# solution. When I commit changes to Azure DevOps it triggers a (working & successful) build-pipeline.
It runs tests, publishes an artifact & testresults.
In my ServicePlan status is Ready and I see Data Exchanges on DataIn & DataOut graphs.
The Deployment Center:
Bu when I click the https://mywebsite.azurewebsites.net, No webpage was found for the web address.
I have Some basic Azure DevOps expierence, but this Azure Portal is something else :)
My basic questions would be:
Why is it not working?
Do I need a second pipeline, only for release? Or can I recycle the build pipeline?
Do I need some kind of deployment slots? Before I select a not-free slot, I want to know if this is necessary
What else could I be missing?
(My Azure resources include a sql-server, a sql-db, the actual appservice & a app service plan)
Thanks!
If you deploy web app to Azure and login https://<app-name>.azurewebsites.net, then the page still shows Microsoft page instead you owner page. You need check the default document, please ensure that the default page is listed in here.
Steps: login azure portal->App Service->configuration->Default documents
In Azure Web Apps, the default document is the web page that is displayed at the root URL for a website. The first matching file in the list is used. Refer File structure on azure to know more about the files and directories on Azure Web App.
Update1
When I go to the azurewebsites.net url I get a 404: No webpage was found for the web address.
Check this doc:
If you receive an HTTP 404 (Not Found) error when you browse to the URL of your custom domain, verify that your domain resolves to your app's IP address by using WhatsmyDNS.net. If not, it might be because of one of the following reasons:
The custom domain configured is missing an A record or a CNAME
record.
The browser client has cached the old IP address of your domain.
Clear the cache, and test DNS resolution again. On a Windows machine,
you clear the cache with ipconfig /flushdns.
Update2
the URL in my appservice is Azure-generated right?
Yes, then app service url is generated by Azure.
With making a new app service and going to the URL I do get a message app service is up and running.Time to take the next step and deploy your code.
And now, we should get this page, we need create new service connection and re-configure build and release pipeline and deploy your app.
Note: We need use the same user account and AAD domain to do this.

Azure cloud services: Redirect existing x.cloudapp.net site without a machine running

Is there some way to redirect an existing x.cloudapp.net cloud service URL without having to have a machine deployed. I would like to find a free solution to this problem. I could of course deploy a minimal machine that does this and get away really cheap.
The reason I'm asking is that we're taking down an application that has been linked to by some of our partners using a cloudapp.net url, so just deleting the cloud service would break their links.
Well, it doesn't become available until you delete the cloud service.
Yes, you could keep the sub domain without having anything deployed. But we can't do anything with the Cloud Service until we deploy any roles(Web Role or Worker Role) to it. All the setting panel shows "This slot has no deployment. Deploy roles to the slot to configure your cloud service."
The only way is deploying a minimal machine as your mentioned in your post.

Azure worker role does not seem to start

We are building webapplication with an AngularJS frontend and a Web.Api backend. Both need to be hosted in Azure. To support this we created two projects:
A worker role with an endpoint on 8080 for the web.api (converted from a selfhosting web.api)
A web role on port 80
Both roles are combined in one azure service project. When running the project local in the azure emulator we have two endpoints that are working as desired. Localhost gives back the website, localhost:8080/api gives back the api. Together a nice website is running.
When deploying it to the staging environment on azure it publishes correctly. After done publishing, when we go to the site the sites loads up. The api does not work though.
When we go to the instances tab in the azure portal, we get 2 instances running in the project. 1 for XX.Azure.Worker_IN_0 and one for XX.WebRole_IN_0.
We looked in the eventlog of the worker role, but we cannot find any problems. Is there anyplace where we should look for errors? We tried searching for it but we couldn't find a log on the server. Or are we doing things with azure that we are not supposed to do.

Setting Up And Using Web Deploy with Azure WebRole in Visual Studio (One-Click partial update)

I am using Windows Azure, and find it a lot difficult and useless make a new "Package" each time you make a small change, and want to test it on the Cloud. I heard about the opportunity to update the web roles without re-deploy the whole instance each time (about 15 minutes), and do a Web Deploy - upload just the modified files (some seconds).
None of the resources found on the web seems to describe this particular situation.
There are tutorials, on how to enable Web Deploy on Azure Web Roles, but not a one how to set it up. [This tutorial is showing the settings, but not for Azure]
To enable web deploy you first need to be able to do a standard Publish (not Package) from the CloudConfiguration project.
there are some good tutorials how to do that.
While the Publish dialog is open, make sure to select this option, and make a normal publish.
After this configuration is published, you are ready to set up the Publish settings for the Web Role project. Note, the CloudCongiguration project is used for Package deployment, and the Web project is used to deploy to Azure via Web Deploy as deploying to normal web hosting.
When you click on the "Publish" context menu of the Web project, a "Publish Web" dialog appears. All settings are easy to guess/standard, except the second tab: Connection.
Here the things go little hard, if you have not messed with Web Deployment before.
Must select the Web Deploy method
The URL to your Web Role (DNS or IP address found on Windows Azure Management portal)
The name of the web site in the IIS on the Host machine. In our case this is the Azure WebRole instance. So Login via RDP, start "Server Management", navigate to: Roles->WebServer(IIS)-> Internet Information Services Manager. In the Connections Pane (The Left part of the Manager) expand the tree-view pointing to the "localhost" service -> Sites -> and there you find the Website Name (should be something like : xxxxx_IN_0_Web)
This is the username you use for RDP connections /and the password below/
is that strange URL, that is pointing to the Web deploy Service, that will eventually update our website content.
you can check, if the Package deployment went OK, in the Azure Management portal, on the Overview page of the web deployment if the port 8172 is open.
Now "Validate Connection" should succeed!
If not, try "http://{0}.cloudapp.net//MSDEPLOYAGENTSERVICE" for Destination URL

Trying to deploy SSL Cert to Azure - Webrole stuck in "Waiting for role to start"

I have an Umbraco instance deployed on Azure via the Umbraco accelerator (created by smarx and Paul Sterling).
http://waacceleratorumbraco.codeplex.com
I am trying to install an SSL Certificate on Azure and am following these steps: http://sondreb.com/blog/post/windows-azure-secure-site-with-ssl-certificate.aspx.
I have deployed my certificate to my hosted service, that looks fine. I've also added HttpsIn with 443 as the public and private port with my certificate selected.
I then right click on my project and select package, this gives me a dialog and I choose Service Configuration: Default and Build Configuration: Release. This gives me a .cscfg file and a .cspkg file.
I then create a new staging deployment with these files through the azure silverlight interface.
The roles never spin up. They just cycle through waiting for roll to start and initializing roll.
Does anyone know how to debug this or what I might be doing wrong?
You need to leave the private port in the Azure configuration blank -- the load balancer will complete this on your behalf. Like so:
It's really hard to diagnose issues with the load balancer configuration, I do wish we'd see better messages!

Resources