I’ve come to learn that Amazon EC2 is the Beyonce’ of the AWS services. Its the most famous of the services offered, adaptable, multi-purpose and works hard for the money. Its pretty essential to all the other services and mastering it is the first step in becoming an AWS boss. Grab some tea, throw on a ambient sound mix and lets get started.
- First thing you need to do is log into log into the AWS service console. You can do it through a lab environment, or create an AWS account. If you’re a Prime junkie like me and already have an Amazon account, you can log in with this as well.
- Your going to click on EC2 button and then click LAUNCH INSTANCE on the EC2 dashboard.
- Next choose an AMI (Amazon Machine Image). Select the Amazon Linux AMI and then choose an instance type. Let’s go with the General Purpose one.
- No need to configure, add storage or configure the security group for now, so just go ahead and hit launch.
- You will now need to create a key pair for your instance. Name and download your key-pair. I suggest dragging the newly saved key-pair to your desktop and leaving it there for now. You’ve just created your instance! now comes the potentially tricky part.
- Take a sip of that tea and turn up the ocean waves! Check your security network setting to make sure your firewall is not on. Use 10.0.0.1 to change the setting on your router. ***Turn your firewall back on when you’re done***
- Now, (deep breath) open up that Mac Terminal. You can use Finder for this, if you’re like me and had no clue where it was.
- You’re going to need to change the file permissions by typing chmod 600 //path/to/your/keys/keypair.pem if this doesn’t work try chmod 400 instead.
- Now that you’ve switched permissions, the command to connect your instance is ssh -i /path/to/your/keys/keypair.pem@ec2-user@public IP of your instance. It’ll look something like ssh -i /Users/Home//Desktop/testkeys.pem@email@example.com
- You should now be connected to your instance! If you are get up and do a little dance.
If you aren’t watch this tutorial and try again.