Thursday, 19 September 2024

VPC AWS labs step by stepwith screenshot

 

1. Create a VPC

  • Navigate to VPC Console: In the AWS Management Console, search for "VPC" and select the service.
  • Create VPC: Click "Create VPC".
  • Configure VPC:
    • Name: Provide a meaningful name.
    • CIDR block: Choose a suitable CIDR block for your VPC.
  • Create VPC:
    Click "Create VPC".
  • Image of AWS VPC Console showing the creation of a VPC

2. Create Subnets

  • Select VPC: Choose the newly created VPC.
  • Create Subnet: Click "Create subnet".
  • Configure Subnet:
    • Name: Provide a meaningful name.
    • Availability zone: Choose the desired availability zone.
    • CIDR block: Choose a suitable CIDR block for the subnet.
  • Create Subnet: Click "Create subnet".
  • Image of AWS VPC Console showing the creation of a subnet

3. Create an Internet Gateway

  • Select VPC: Choose the VPC containing your subnets.
  • Create Internet Gateway: Click "Create internet gateway".
  • Attach Internet Gateway: Attach the internet gateway to the VPC.
  • Image of AWS VPC Console showing the creation and attachment of an internet gateway

4. Create a Route Table

  • Select VPC: Choose the VPC containing your subnets.
  • Create Route Table: Click "Create route table".
  • Associate Route Table: Associate the route table with your subnets.
  • Image of AWS VPC Console showing the creation and association of a route table

5. Create a Route

  • Select Route Table: Choose the route table associated with your subnets.
  • Create Route: Click "Create route".
  • Configure Route:
    • Destination: Specify the destination CIDR block (e.g., 0.0.0.0/0 for all traffic).
    • Target: Choose the internet gateway as the target.
  • Create Route: Click "Create route".
  • Image of AWS VPC Console showing the creation of a route

6. Launch an EC2 Instance

  • Navigate to EC2 Console: In the AWS Management Console, search for "EC2" and select the service.
  • Launch Instance: Click "Launch instance".
  • Choose Instance Type: Choose an appropriate instance type.
  • Configure Instance Details: Configure instance details (e.g., key pair, security group).
  • Configure Networking: Choose the VPC and subnet created earlier.
  • Launch Instance: Click "Launch".
  • Image of AWS EC2 Console showing the launch of an instance

7. Access the Instance

  • Connect to Instance: Use the provided SSH key to connect to the instance.
  • Image of terminal showing the connection to an EC2 instance

8. Additional Considerations

  • CIDR Blocks: Choose suitable CIDR blocks to avoid overlapping.
  • Subnet Types: Create public and private subnets based on your requirements.
  • Security Groups: Configure security groups to control network access.
  • NAT Gateways: Use NAT gateways to allow instances in private subnets to access the internet.

No comments:

Post a Comment