The Web role was started in a wrong port

So you have started to trying out the Windows Azure Toolkit for Windows Phone 7, and created your first sample application. Then , when you launch the admin page, you get this error:

Sorry, an error occurred while processing your request.
WP7CloudApp1.Web.Infrastructure.RoleInWrongPortException: The Web role was started in a wrong port. For this sample application to work correctly, please make sure that it is running in port 443. Please review the Troubleshooting section of the sample documentation for instructions on how to do this.


Interesting. You notice that in the address bar, Internet Explorer has for some reason browsed to port 444 instead of the expected port 443. Looking at the documentation on MSDN for Azure, in the paragraph Testing an HTTPS endpoint in the compute emulator, one can find this little tidbit: If a port that you specify is not available, in the case of an HTTPS endpoint 443, the compute emulator will increment the port number until it finds one that is free.

And the Compute Emulator confirms the fact that is started to listen on port 444 instead:


So what’s is keeping port 443 busy?

Netstat –a –b says nothing of interest really, other than the fact that something is indeed listening on port 443 (and port 80 also, BTW):

Active Connections

Proto  Local Address          Foreign Address        State
TCP             Magnus-PC:0            LISTENING
Can not obtain ownership information
TCP            Magnus-PC:0            LISTENING
TCP            Magnus-PC:0            LISTENING
Can not obtain ownership information
So you start to close down the usual suspects, as IIs etc. but still something is listening on port 443.

It took me some time, but I finally figured it out…. SQL Server Reporting Services.


Maybe you are like me, when installing SQL Server, you opt in for all features, just in case… Well, this time it bit me hard.

Stopping the SQL Reporting Services Service, and restarting the Compute Emulator, my Windows Azure sample application for Phone 7 started to work again:


7 thoughts to “The Web role was started in a wrong port”

  1. I did have this problem and used the TcpView (sysinternals tool) to find out who was listening on 443. It was Skype. There is an option setting to turn off to disable its use of 80 and 443.

    Unfortunately, now I have another similar error about port 5100. I got around this by removing the node from the config to prevent it using IIS7.5.

    Still struggling with this. I have not decided if this is the best option for WP7 membership – it seems sort of heavy.


  2. Hurray. I had the same problem and wasn’t able to solve it for hours.
    What made thing even worse, prior to this, was that I was receiving just global exception, so I had to reinstall the iis for correct .NET runtime.
    Thanks for help here.

  3. i have the same problem and i tried both of above strategies but both of them didn’t work for me is there any other way pls im stacked

  4. @dani. You will try to find out which process is using port 443 already. First, use netstat -a -b to see if there is actually something using the port.

Leave a Reply

Your email address will not be published. Required fields are marked *