Here’s the AWS version of creating a lab Windows server – with the same priorities as on Azure: secure access and no surprise bills. Use the AWS Free Tier or a lab account.
Key choices
| Choice | Lab value | Note |
|---|---|---|
| Region | e.g. Asia Pacific (Mumbai) | Top-right in the console |
| AMI | Microsoft Windows Server 2022 Base | Official Amazon-provided image |
| Instance type | t3.medium (or a free-tier eligible type for very small tests) |
Windows needs ~4 GB RAM to be comfortable |
| Key pair | New RSA key pair (.pem) |
Used to decrypt the Windows admin password |
| Security group | RDP from My IP only – or no inbound rules with Systems Manager | Never 0.0.0.0/0 |
Launch from the console
- EC2 → Launch instance.
- Name:
lab-win01. AMI: Windows Server 2022 Base. - Instance type, then Create new key pair (RSA,
.pem). Store the file safely – it unlocks the admin password. - Network settings → Edit: default VPC is fine for a lab. Security group: allow RDP with source My IP.
- Storage: the default 30 GB gp3 is enough.
- Launch instance. Wait until Status check: 2/2 checks passed.
Get the admin password
Select the instance → Connect → RDP client → Get password → upload your .pem key → Decrypt password. Download the RDP file and connect as Administrator.
Change the password after first login, or create your own admin account.
Better: Systems Manager instead of open RDP
AWS Systems Manager lets you manage instances without any inbound port:
- Create an IAM role for EC2 with the managed policy AmazonSSMManagedInstanceCore, and attach it to the instance (Actions → Security → Modify IAM role).
- Windows AMIs include the SSM Agent. After a few minutes the instance appears in Systems Manager → Fleet Manager.
- Use Fleet Manager → Remote Desktop for a browser RDP session, or Session Manager / Run Command for PowerShell – then remove the RDP rule from the security group entirely.
Run Command is also how you run the same PowerShell on many instances – useful once you have more than one.
With the AWS CLI / PowerShell
# AWS Tools for PowerShell: Install-Module AWS.Tools.EC2 -Scope CurrentUser
# Find the latest Windows Server 2022 base AMI via the public SSM parameter
$ami = (Get-SSMParameterValue -Name '/aws/service/ami-windows-latest/Windows_Server-2022-English-Full-Base').Parameters[0].Value
$res = New-EC2Instance -ImageId $ami -InstanceType t3.medium -KeyName lab-key `
-SecurityGroupId sg-0123456789abcdef0 -MinCount 1 -MaxCount 1
$id = $res.Instances[0].InstanceId
New-EC2Tag -Resource $id -Tag @{ Key = 'Name'; Value = 'lab-win01' }
(Get-SSMParameterValue comes from the AWS.Tools.SimpleSystemsManagement module. The security group ID above is a placeholder – use your own.)
Clean up
- Stop – no compute charges, but EBS volumes are still billed.
- Terminate – deletes the instance (and its root volume by default). Do this when the lab is done.
- Also delete unused Elastic IPs, snapshots and volumes – they’re easy to forget.
Set an AWS Budget alert (e.g. ₹500 or $10 a month) so you’re warned before a lab becomes expensive.
What’s next
Next: Cloud networking – VNets, VPCs and security groups.
Practise this topic
Test yourself with free questions on this topic – instant answers and explanations.
Start practice questionsAWSEC2Windows ServerCloudBeginner