HTTP Error Message: The location or affinity group East US specified for source image

If you run into the following error trying to create VMs with PowerShell:

New-AzureVM : HTTP Status Code: BadRequest – HTTP Error Message: The location or affinity group East US specified for source image MSFT__Windows-Server-2012-RC-June2012-v1-en-us-30GB.vhd is invalid. The source image must reside in same affinity group or location as specified for hosted service West US.

The problem is your storage account is in a different location/affinity group then the VNET you are deploying to. There may be other causes but I hit this one today and thought it was a strange enough message to blog it so I would remember :)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s