It might seem natural for Microsoft system administrators to turn to Microsoft’s own Azure cloud platform when looking to provision server instances in the cloud, but Amazon’s cloud platform is a mature product with some compelling features. In this how-to article, I’ll look at some of the basic concepts you need to understand in Amazon Web Services (AWS), how to get Windows Server 2012 up and running in a VM, and how to attach an additional disk.
Amazon offers a one-year free trial that allows you to provision Windows Server micro-instances with up to 750 hours of compute time per month (but with limited storage and network I/O). During the sign-up process, you will need to provide a contact phone number, which Amazon will use to contact you to confirm your identity using an automated system. You’ll also need to provide credit card details to cover any additional fees should you exceed any of the free-tier limits during the first year of your subscription.
As most of us already have an account for use on Amazon.com, the sign-up process is simple using your existing email address and password. You’ll just be required to confirm a security code using your phone’s dial pad. It’s possible to enable multi-factor authentication during the sign-up procedure, but for simplicity’s sake, you might want to wait until you are more familiar with AWS before switching on additional security for your account.
The management console can be accessed from http://aws.amazon.com. Head over to the top-right corner, click My Account / Console and select AWS Management Console from the menu. If you are not already signed in to AWS, you’ll be prompted to enter your email address and password.
In the list of services, we’re interested in EC2 (Elastic Compute Cloud). We’ll also need some of the other services, such as Elastic Block Store (EBS), but we’ll look at them later in the article. Click EC2 under Amazon Web Services to get started.
Before we create a VM, it’s helpful to understand some terminology. An Amazon Machine Image (AMI) is a template from which instances can be launched. You can create your own AMIs or use the provided Amazon Web Images (AWIs). Multiple instances can be launched from a single AMI, and instances can be based on different hardware configurations.
AMIs are instance store backed or Amazon EBS backed; you can find this information in the description of the AMI. AMIs that use instance stores for the root device (system disk) will lose any information stored on the disk when the instance is terminated, or if the storage fails for some reason. Stop operations are not supported.
Amazon EBS-backed root devices can be stopped and restarted without losing data. By default, Amazon EBS-backed storage devices are deleted when an instance is terminated, but this behavior can be changed when you create instances by deselecting the Delete on Termination option for the root volume.
Let’s create a new VM, or instance in AWS parlance, with Windows Server 2012 provisioned from an Amazon Web Image (AWI). You probably noticed that I haven’t mentioned Windows Server 2012 R2, because at the time of writing this article, R2 is still not supported or provided as an AWI.
I’ve bypassed advanced configuration options at this stage. If you continue through this wizard, it’s possible to add additional storage and modify inbound network rules, but these options can also be changed at later. By default, you have one 30GB OS volume attached to the instance, and inbound connectivity for RDP TCP port 3389 is allowed from any IP address.
Within a minute, you should see a message stating that Your instance in now launching. Click View Instances in the bottom right of the console to view the current state of your new instance. Your new instance should be up and running fairly quickly, but you might need to wait up to 30 minutes before a password is generated so that you can connect and remotely authenticate.
Now that our new VM has been successfully created, let’s start it up and connect to it.
There are two options under the Action menu for shutting down a VM instance. Stop shuts down the instance, but retains it for further use, and Terminate shuts down the VM and deletes the instance. When an instance is stopped, you are not charged for instance hours, but every time you transition from stopped to running, a full instance hour is the minimum charge.
Terminating an instance deletes the instance itself and any attached EBS storage, unless the instance’s deleteOnTermination attribute is marked as false. This parameter can be set when you launch a new instance in step 4 of the wizard.
Connecting additional EBS backed storage is easy. First we need to create a new volume in the management console.
The new volume should now appear in the list in the right pane of the management console.
Start the instance if it is not already running and connect to it using Remote Desktop Connection. Open File Explorer and you should see the new disk. Unlike Microsoft Azure, you don’t need to use Server Manager to bring the disk online.