MSDN Library

Determine the Current Guest OS of your Cloud Service

Updated: March 2, 2015

The procedures listed below show how to determine the Azure Guest operating system (Guest OS) version of the hosted service running web or worker roles.

All role instances in a deployment run on the same version of the Guest OS.

View the current Guest OS of a service in Azure Platform Management Portal

  1. Log into the Azure Management Portal.

  2. On the left pane choose Cloud Service, then choose the name of the service you want to modify.

  3. Choose CONFIGURE on the top menu.

  4. Choose either Staging or Production on the menu below the top menu. You need to configure each deployment independently. Changing the Guest OS configuration of one will not change the other.

  5. At the bottom of the page, find the operating system section.

    The version of the Guest OS you are running for this Cloud Service is identified by the OS SYSTEM FAMILY and OS SYSTEM VERSION drop downs. A value of Automatic means that you are running the latest version of the chosen OS FAMILY. A value of Retired OS or something similar means you are manually configured to use an older version of the Guest OS that is no longer supported. Consult the Azure Guest OS Releases and SDK Compatibility Matrix for the policy on retired Guest OS versions. If you do not take action at some point, your service will be force upgraded to a later Guest OS.

Retrieve the Guest OS using the Service Management API

The Service Management API provides the Get Deployment API call that returns configuration information and system properties for a deployment. This includes information about the roles in the service. The <Role> node returns the Guest OS version for each role. The Guest OS versions are listed in Azure Guest OS Releases and SDK Compatibility Matrix


The following code snippet shows how to call the Get Deployment operation to retrieve the deployment information for a specified cloud service. You will pass format the REST call to include your subscription ID, the name of your service, and the deployment slot (production or staging) in which the service is located.

            string uriFormat = "{0}/" +
            Uri uri = new Uri(String.Format(uriFormat, subscriptionId, serviceName, slot));

            HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(uri);
            request.Method = "GET";
            request.Headers.Add("x-ms-version", version);
               // Your X509 Service Management certificate
            request.ContentType = "application/xml";

            XDocument responseBody = null;
            HttpStatusCode statusCode;
            HttpWebResponse response;
                response = (HttpWebResponse)request.GetResponse();
            catch (WebException ex)
                // GetResponse throws a WebException for 400 and 500 status codes
                response = (HttpWebResponse)ex.Response;

See Also

© 2015 Microsoft