Connecting to a Windows AMI
There is a free instance of Microsoft Server 2008 R2 that you can launch, but connecting to it is quite different than connecting to Linux. You can start up your windows instance much like your Linux instance, as shown below. You select your instance, name it, and create your key pair for it, just like you did with Linux.
Since there is quite a bit more “stuff” that needs to happen to get your windows system up and running, it will take a few minutes before we can actually connect to the instance. Go get some coffee or visit the restroom because you have some time right now. Basically the system has to go through sysprep in order to become a unique instance from the machine image we started it from… it takes time… so be patient. When your instance view shows the instance running and 2/2 checks are green, you are ready to connect.
Same as before, right-click on your instance and select “Connect”. This time, however, the dialog that appears will be slightly different from the Linux one as you can see below. This is because we won’t be using SSH to connect to Windows… we’ll be using RDP which requires a username and password.
The first thing we need to do here is retrieve your password (which is based on your Key Pair). So click on the Retrieve Password Link, which will take you to the screen below.
Unlike in Linux, we can actually browse to where we have the Key Pair file stored. In this example, we named our key pair Svr2008R2.pem. So click browse and locate your Key Pair file. Once you have it selected you will then see the option to decrypt your password.
Once you have selected “Decrypt Password” your dialog window will update with your credentials. Note them down and click “Download shortcut file”, which will allow you to save the basic connection information in a RDP shortcut on your local computer.
When you click on download, you’ll be prompted for a file name… by default it’ll be your Machine name, which isn’t too intuitive. So type in something you’ll remember.
I simply saved the shortcut to my desktop, and when I launch it (from my MAC) I get the following connection screen (Even if you’re running windows, it will be similar)
When you click Connect, you will be prompted for your Username and Password. This is the password we just generated. You will not enter anything for Domain.
You will be prompted that the server name on the certificate is incorrect, simply click OK to continue to log into your instance.
Once you click Connect you are on your way to your desktop.
Since this is a micro instance, don’t expect this environment to be speedy. But if you are looking for a R2 server to beat up, mess around in, test your admin skills on, etc… this is the way to do it. By sticking with the micro instance you can run this sever 24/7 for one full year at no cost to you. Remember that if you spin up 2 or more you will begin chewing up your 750 hours/month more quickly than if you had just one. Also with windows, disk space can be an issue. Monitor it and make sure you a) don’t run out of space or b) allocate yourself more space because the former will cost you clean up time and the latter will cost you money.
Terminating your Windows Server 2008 R2 Instance
Remember, if you instance is running you are “On the Amazon clock”. Shutdown your server when you’re not using it. If you have been experimenting and gotten to a place where your instance is useless, just terminate it. As we did with the Linux instance, just right-click on your instance from your Instance View and select “Terminate”.
Be sure to delete your associated EBS volumes (off-instance storage). If you don’t you may end up being charged for using the space.
So now you know how to connect to a Windows free micro instance on Amazon Web Services. Here’s the thing to keep in mind… these are sandboxes for you. You can create, destroy, terminate anything you want as many times as you want so you can learn what you want to learn when you wan to learn it. With the micro instances you have 750 hours of free usage per month for one year. Make the most of that year. Experiment, create, try, fail, try again… and come out the other side knowing more than you did when you went in.
Best of luck and let me know if you have any questions!
PS – I have already terminated all the instance that have been used in these posts. That’s why I haven’t obscured anything in the images. You get to see what I saw when I spun them up so you get a feel for what you expect to see… but don’t waste your time trying to hack into any of these instances… they’re gone… long gone.