Back-end Engineering Articles

I write and talk about backend stuff like Ruby, Ruby On Rails, Databases, Testing, Architecture / Infrastructure / System Design, Cloud, DevOps, Backgroud Jobs, and more...

Twitter:
@daniel_moralesp

2019-02-01

Creating A Windows Virtual Machine in AWS

In this new post, we will create a Windows Machine in AWS. Given the fact that Windows deal with almost everything using the User Interface (UI), the best, easy and fast way to have a Virtual Machine running Windows is using Amazon Lightsail

The intent of these next posts is to create different AWS Virtual Machines, each one of them running the two central operating systems: Linux and Windows. We will not make a macOS VM because it doesn't have a Free tier in AWS is a Unix-like system, so almost everything is similar compared to Linux commands.

Cost of creating different Virtual Machines in AWS 


The primary concern when you're going to install something in AWS is the associated costs. So what we're going to do is choose the "Free Tiers" under each OS. You'll be allowed to use these Free Tiers for 1 year. After that, if you don't want to wait that time, you can shut down at any moment the VMs and avoid any payment. 

Things to do 

* Have an account in AWS: If you have this email: [email protected] is an excellent idea to sign up in AWS with the following email [email protected]. That kind of email (with a + sign) works as an alias of your primary domain. Refer to this article about it: https://www.fastmail.help/hc/en-us/articles/360060591053-Plus-addressing-and-subdomain-addressing 
* Have a Credit Card to set up your account. Don't worry, because if you don't use any other resource, you won't be charged by AWS 
* Shut down everything once you think you won't use these VMs anymore


1- Creating a Windows Virtual Machine in AWS


Once you have an account in AWS and you attached your credit card (I guess you don't need help here because it is straightforward to do these 2 steps), we're ready to start installing our VM.

To do that, we'll be using Amazon Lightsail, a service that helps us to do all of this setup very quickly. So let's go to our account and search for Lightsail.


You'll be redirected here.


So let's get started. First, we choose the location of the instance as Virginia.



Now we choose the Windows instance and then the Windows Server 2019


Then we select the pricing plan. You can see that the first 3 months are for free. This is enough for our testing purposes.

Choose the price tier

I choose the $20USD plan because it has more resources than the other "First 3 months free" plans, so we don't get stuck if we need to install something bigger inside our instance or even navigate the Internet inside the instance we can test it for free.

Now we can create a name for our instance or keep the current one.

Then click on "Create Instance," and we'll see the instance Pending.


After a while, we can see the instance running.

After a couple of minutes, we can see the "Connect Using RDP" button. This is how we can access the cloud instance from our local machine, so once the button is active (remember that it takes a while), let's click that button to see what happens.


That's it, we can now see a Windows machine! This setup is easy, practical and we're ready to install whatever we want inside a Windows machine.

Finally, we have to create a static IP to connect with other RDP clients if necessary.

Click on create static IP
Then
Click on Create button
Confirmation message
Now we have a Static IP where we can connect with other RDP Clients different from the one provided by AWS.

What's an RDP Client?


Remote Desktop Protocol (RDP) is a proprietary protocol developed by Microsoft which provides a user with a graphical interface to connect to another computer over a network connection. The user employs RDP client software for this purpose, while the other computer must run RDP server software.

Usually, any local machine will come with an RDP Client from default. To check your Remote Desktop version, click the Start button and search for Remote Desktop. Then, launch the Remote Desktop program, click the icon at the window's top-left, select About. This will show you your current client version.

Also, you can install 3rd party RDP Clients. You can find a complete article about them here: Best remote desktop software of 2022: Paid and free choices for businesses | TechRadar

I hope you learned a lot from this blog post.

Thanks for reading
Daniel Morales