Compartilhar via


Introducing: Auto-upgrade mode to manage the Windows Azure guest OS for your service

Summary

Today we released the Windows Azure guest OS Auto-upgrade feature to help you keep your service running on the latest operating system available for Windows Azure. The platform automatically upgrades your service to use the latest OS whenever it becomes available without you have to worry about it. This helps you keep your service running on the most secure OS available for Windows Azure with no extra effort.

When you create a new service on Windows Azure and do not specify a particular OS Version to use in your Service Configuration file (.cscfg), your service will be created in auto-upgrade mode. For an existing service you can choose to change mode from Manual to Auto using this new feature set.

This feature is currently available via an attribute in the Service Configuration (.cscfg) file. It will soon be available even more conveniently on the Developer Portal.

What is OS Upgrade?

In Windows Azure, instances of your service run in a Virtual Machine, with an operating system installed on it. The operating system in use today is a customized OS designed for the Windows Azure environment and is substantially compatible with Windows Server 2008 SP2.

We try to keep this OS updated with the latest security fixes released for Microsoft Windows Server OS and that are applicable to Windows Azure Operating System as well. We release an updated version of the Windows Azure OS, roughly on a monthly schedule. The list of OS releases can be found here.

OS upgrade support till now

Up till now, users had the ability to perform an OS Upgrade for their service in a manual mode, by using the osVersion attribute in Service Configuration (.cscfg) file.

1. New Deployment: When a service is deployed for the first time the user can specify the osVersion attribute in their .cscfg file. E.g.

<?xml version="1.0" encoding="utf-16"?>

<ServiceConfiguration xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="https://www.w3.org/2001/XMLSchema" serviceName="" osVersion="WA-GUEST-OS-1.1_201001-01" xmlns="https://schemas.microsoft.com/ServiceHosting/2008/10/ServiceConfiguration">

</ServiceConfiguration>

 

If nothing is specified, the platform picks the latest OS available at the time of deployment and fixes the services on this OS. E.g. a new service deployed before today with osVersion would be fixed to use version WA-GUEST-OS-1.2_202003-01.

2. Existing Deployment: To upgrade the OS for an existing deployment, the user will need to perform a configuration update with a new value for the osVersion attribute

When the user requests an OS upgrade, the platform performs a regular In-Place upgrade of the service, by walking the upgrade domains.

The new OS Auto-upgrade feature

 

With the new feature coming online today, users can set up their service for OS auto-upgrades very simply by using the same Service Configuration (.cscfg) based mechanism.

1. New Deployment

You can use the configuration file to set the auto-upgrade mode.

<?xml version="1.0" encoding="utf-16"?>

<ServiceConfiguration xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="https://www.w3.org/2001/XMLSchema" serviceName="" osVersion="* " xmlns="https://schemas.microsoft.com/ServiceHosting/2008/10/ServiceConfiguration">

</ServiceConfiguration>

 

If the osVersion attribute is not specified, the service is put into auto-upgrade mode by default.

 

2. Existing Deployment: If you already have a service with a fixed osVersion, you can change the mode to Auto-upgrade by updating the configuration for your service with osVersion = “*” .

 

Service Management APIs

With this new feature, we are also introducing a couple of additions to Service Management APIs

1. Getting the OS Version for your Service

The GetDeploymentAPI now supports getting the OSVersion of your service.

 

Given below is the output from CSManage tool to get the version of the OS for my service:

>csmanage /view-deployment /hosted-service:td-tnv1-we /slot:production

 

Using certificate: CN=SUMITM2.redmond.corp.microsoft.com

Getting Deployment

Name:7dce3813-eb2c-4101-af21-752e9785d9c2

Label:td-tnv2-we

Url:https://td-tnv1-we.cloudapp.net/

Status:Running

DeploymentSlot:Production

PrivateID:cefbd53a10fa4593891eb671f84c2469

UpgradeDomainCount:1

RoleList contains 2 item(s).

    RoleName: Thumbnails_WorkerRole

    OperatingSystemVersion : WA-GUEST-OS-1.3_201004-01

    RoleName: Thumbnails_WebRole

   OperatingSystemVersion : WA-GUEST-OS-1.3_201004-01

RoleInstanceList contains 2 item(s).

    RoleName: Thumbnails_WorkerRole

    InstanceName: Thumbnails_WorkerRole_IN_0

    InstanceStatus: Ready

    RoleName: Thumbnails_WebRole

    InstanceName: Thumbnails_WebRole_IN_0

    InstanceStatus: Ready

Operation ID: 84cad57a5a1f41b18228226bfef1ad26

HTTP Status Code: OK

StatusDescription: OK

 

2. Getting a list of OSs available on Windows Azure.

The APIs support getting a list of guest operating system version available. Here’s the documentation for the API.

Given below is the output from CSManage tool to get the list of OSes using the APIs. The output shows that there are 4 releases of the OS available. All of them are available as choices for the osVersion attribute (IsActive = True). One of these (WA-GUEST-OS-1.3_201004-01) is the latest release available (IsDefault = True).  If the service was on auto-upgrade mode, it would be running on the latest OS release currently.

 

>csmanage.exe /list-operating-systems

 

Using certificate: CN=<EDITED>

Listing OperatingSystems

OperatingSystemList contains 4 item(s).

Operating System Version:WA-GUEST-OS-1.0_200912-01

Operating System Label:Windows Azure Guest OS 1.0 (Release 200912-01)

Operating System IsDefault:False

Operating System IsActive:True

Operating System Version:WA-GUEST-OS-1.1_201001-01

Operating System Label:Windows Azure Guest OS 1.1 (Release 201001-01)

Operating System IsDefault:False

Operating System IsActive:True

Operating System Version:WA-GUEST-OS-1.2_201003-01

Operating System Label:Windows Azure Guest OS 1.2 (Release 201003-01)

Operating System IsDefault:False

Operating System IsActive:True

Operating System Version:WA-GUEST-OS-1.3_201004-01

Operating System Label:Windows Azure Guest OS 1.3 (Release 201004-01)

Operating System IsDefault:True

Operating System IsActive:True

Operation ID: 2be9091a155347aab9d57e86f09f82a7

HTTP Status Code: OK

StatusDescription: OK