INSTANCES LAUNCH PROCESS
Instances Login to Your AWS Account,Select and switch to the required Region and find EC2 under Compute Section.
Select the Launch instance option and it will launch an instance launch wizard
I want to launch an Amazon Linux AMI,so selecting Amazon Linux AMI from the Quick Start menu.
We have Windows and Linux operating systems available here in Quick start option
Along with the Quick Start option,you can also spin up your instances using the AWS Marketplace and the Community AMIs section. Both these options contains list of customized AMIs that have been created by either third-party companies or by developers and can be used for a variety of purposes.
Choose an instance type
In the next step, we have to select the instance type as per our requirements. You can filter instances according to their families.
We can use the general purpose t2.micro instance type, which is comes under the free tier eligibility and configuration is 1 vCPU and 1 GB of RAM.
Configure instance details
Here is Step 3, we have multiple options,
Number of instances
You can specify how many instances the wizard should launch using this field.By default,the value is always set to one single instance.
We can this instance under spot instances request.For now let’s leave this option.
Select the default Virtual Private Cloud(VPC)network that is displayed in the drop down list.We can even go ahead and create a new VPC network for this instance,but we will leave and will see VPC in later chapters.
select the Subnet in which you wish to deploy your new instance.You can either choose to have AWS select and deploy your instance in a particular subnet from an available list or you can select a particular choice of subnet on your own.
We can configure instances and install applications programmatically when an instance is launched.The process of providing code to be run on an instance at launch is called bootstrapping.
On Linux instances this can be shell script,and on Windows instances this can be a batch style script or a Power Shell script.
You can additionally select a particular IAM role to be associated with your instance.
By default,AWS will monitor few basic parameters about your instance for free,but if you wish to have an in-depth in sight into your instance’s performance,then select the Enable Cloud Watch detailed monitoring option.But you’ll get charged for detailed monitoring.
This option allows us to select whether the instance should stop or be terminated when issued a shutdown request.In this case,we have opted for the instance to stop when it is issued a shutdown command.
Enable termination protection
Select this option in case you wish to protect your instance against accidental deletions.It adds additional step for instance termination.If,we enable this option,we need to manually Disable to terminate the instance.
We can choose to run our instances on physical servers fully dedicated fory our use.The use of host tenancy will request to launch instances on to dedicated hosts.
Auto-assign Public IP
Each instance that you launch will be assigned a Public IP.We are going to use this public IP to connect to our Instance over Internet
Step 4: Add Storage
We can add EBS volumes to your instances.To add new volumes,simply click on the Add New Volume button.This will provide you with options to provide the size of the new volume along with its mount points.There is an 8 GB volume already attached to our instance.This is the t2.micro instance’s root volume.
Try to keep the volume size under 30 GB,It’ll comes under free tier eligibility.
We can create volumes and attach to instance even after instance launch also.
Step 5:Add Tags
Tags are normal key-value pairs.We can manage our AWS resources with Tags options. We can create maximum of 50 tags per Instance.
Step 6: Configure Security Group
A security group is a set of firewall rules that control the traffic for our instance.We can add rules to allow specific traffic to reach our instance.
For example,if you want to set up a web server and allow Internet traffic to reach our instance,add rules that allow un restricted access to the HTTP and HTTPS ports.We can create a new security group or select from an existing one.
Select the Create a new security group option and enter the suitable Security group name and Description.
You need to open SSH to Connect Linux machines,RDP for Windows machines.HTTP and HTTPS if web servers
We can give 0.0.0.0/0 to connect this instance from any network and subnet
We can select custom option and give the particular Network’s public IP,then the service will be available for that particular network only
Some Important points about Security Groups
You can create upto 500 security groups for each Amazon VPC.
You can add upto 50 inbound and 50 outbound rules to each security group.If you need to apply more than 100 rules to an instance,you can associate up to five security groups with each network interface.
You can specify allow rules,but not deny rules.This is an important difference between security groups and ACLs.
By default,no inbound traffic is allowed until you add inbound rules to the security group.
By default,new security groups have an outbound rule that allows all outbound traffic.
Security groups are stateful. This means that responses to allowed inbound traffic are allowed to flow outbound regardless of outbound rules and vice versa.
You can change the security groups with which an instance is associated after launch,and the changes will take effect immediately.
Step 7: Review Instance Launch
- Here in step 7, we will get review screen. We will get complete summary of our instance’s configuration details,including the AMI details,instance type selected,instance details,and soon. If all the details are correct,then simply go and click on the Launch option.
- Then we have to associate a key pair to our instance.
- A key pair is basically a combination of a public and a private key,which is used to encrypt and decrypt your instance’s login info. AWS generates the key pair for you which you need to download and save locally to your computer.
→ Once a key pair is created and associated with an instance,we need to use that key pair itself to access the instance.We will not be able to download this key pair again so,save it in a secure location.
→ Select the Create a new key pair option from the drop down list and provide a suitable name for your key pair as well.Click on the Download Key Pair option to download the .PEM file.Once completed,select the Launch Instance option.
- We can view instance’s ID,instance type,IP information,AZ,Security Group,and a whole lot more info.
- We can also obtain instance’s health information using the Status Checks tab and the Monitoring tab.
- We can perform power operations on your instance such as start, stop, reboot, and terminate using the Actions tab located in the preceding instance table.
More Information :https://www.fgrade.com/amazon-web-services/