Cloud Networking Fundamentals
Tags: cloud, networking, aws
Published: 2021-03-08 14:42:04

<!-- wp:paragraph -->
<p>I spent over a couple of weeks reading about <em>Virtual Private Cloud(VPC), public and private subnets, Internet Gateway, Route tables,  Network access control lists(NACLs), Security Groups, Nat Gateway, Bastion hosts, VPC peering, AWS Transit Gateway, VPN connections, AWS Direct connect,  AWS Route 53 and AWS Cloud Front.</em></p>
<!-- /wp:paragraph -->

<!-- wp:heading {"level":4} -->
<h4>Q. <strong><em>What do you mean by a Virtual Private Cloud(VPC)</em></strong>?</h4>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p>A VPC resides inside of the AWS Cloud and it's essentially your own isolated segment of the AWS Cloud itself.&nbsp;By default when you create your VPC, you only have access to it from your own AWS account. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>It allows you to start deploying resources within your VPC, for example, different compute resources or storage or database and other network infrastructure among others and this allows you to start building and deploying your solutions within the Cloud.&nbsp;</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>It's very simple to create a VPC,</p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>Give it a name, when you create your VPC  </li><li>Define an IP address range that the VPC can use and this is done in the form of a Classless Inter-Domain Routing(CIDR) block. </li></ol>
<!-- /wp:list -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://docs.aws.amazon.com/vpc/latest/userguide/images/internet-gateway-diagram.png" alt=""/><figcaption>Credits: https://docs.aws.amazon.com/vpc/latest/userguide/images/internet-gateway-diagram.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p>The CIDR block address is a range of IP addresses and this CIDR block range can have a subnet mask between a range of IP addresses from a&nbsp; /16 all the way through to a /28. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong><em>For more information about VPC,</em></strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://aws.amazon.com/vpc/?vpc-blogs.sort-by=item.additionalFields.createdDate&amp;vpc-blogs.sort-order=desc" target="_blank">https://aws.amazon.com/vpc/?vpc-blogs.sort-by=item.additionalFields.createdDate&amp;vpc-blogs.sort-order=desc</a></li><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/userguide/what-is-amazon-vpc.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/userguide/what-is-amazon-vpc.html</a></li><li><a href="https://docs.aws.amazon.com/vpc/latest/userguide/how-it-works.html" target="_blank" rel="noreferrer noopener">https://docs.aws.amazon.com/vpc/latest/userguide/how-it-works.html</a></li></ol>
<!-- /wp:list -->

<!-- wp:heading {"level":4} -->
<h4>Q. <em><strong>What do you mean by subnets?</strong></em></h4>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p id="block-95650b09-7f21-4c64-8a40-fde11470ed31">Subnets reside inside your VPC, and they allow you to segment your VPC infrastructure into multiple different networks. You might want to do this to create better management for your resources, or to isolate certain resources from others, or even to create high-availability and resiliency within your infrastructure.</p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://docs.aws.amazon.com/quickstart/latest/cloudera/images/cloudera-private-subnet.png" alt=""/><figcaption>Credits: https://docs.aws.amazon.com/quickstart/latest/cloudera/images/cloudera-private-subnet.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:heading {"level":5} -->
<h5><strong><em>What makes a subnet public and what makes a subnet private? </em></strong></h5>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p><strong>A public subnet is accessible from outside of your VPC</strong>. So essentially from the Internet. They have two IP addresses. </p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>They have their own internal IP address which will be within the range of the subnet, </li><li>We assign them a public IP address as well, because to be accessible from the Internet, the instance itself has to have a public IP address.&nbsp;</li></ol>
<!-- /wp:list -->

<!-- wp:paragraph -->
<p>Any resources created within your private subnet, for example your backend databases, would be considered private and inaccessible by default from the Internet. <strong>There's two changes you need to make to your infrastructure to make a subnet public,</strong> </p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><strong>Add an Internet gateway(IGW)</strong>: It is a managed component by AWS that is attached to your VPC and acts as a gateway between your VPC and the outside world.</li><li><strong>Add a route to the public subnet's route table</strong>: Every subnet when it's created will also be an associated route table. You can have the same route table associated to multiple subnets. You can't associate more than one route table to a single subnet.&nbsp;</li></ol>
<!-- /wp:list -->

<!-- wp:image {"align":"center","sizeSlug":"large"} -->
<div class="wp-block-image"><figure class="aligncenter size-large"><img src="https://docs.aws.amazon.com/vpc/latest/peering/images/update-route-table-peering.png" alt=""/><figcaption>Credits: https://docs.aws.amazon.com/vpc/latest/peering/images/update-route-table-peering.png</figcaption></figure></div>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>By default, when your subnet's created, it will have a default route in it, and this is a local route. </strong>Every route table has this local route. It can't be deleted, and it simply allows all subnets within your VPC to communicate with each other.</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>When working with TCP/IP addresses within your subnet, first four addresses in any subnet are reserved and you cannot use for host addresses and also the very last address is reserved</strong>. So that's why use only 251 IP addresses available to you that you can use to assign to your host resources from 256 IP addresses.</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>It's not best practice to deploy all of your resources within the same availability zone, within a single region, simply because it doesn't offer high-availability and resilience.  </strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>For more information about Subnets,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Subnets.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Subnets.html</a></li><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/userguide/working-with-vpcs.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/userguide/working-with-vpcs.html</a></li><li><a href="https://docs.aws.amazon.com/vpc/latest/userguide/default-vpc.html" target="_blank" rel="noreferrer noopener">https://docs.aws.amazon.com/vpc/latest/userguide/default-vpc.html</a></li></ol>
<!-- /wp:list -->

<!-- wp:heading {"level":4} -->
<h4><strong>Q. <em>What do you mean by VPC Peering?</em></strong></h4>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p>We can allow VPC peering to allow VPCs to communicate with each other. Now the peering connection that links the two VPCs is actually run and hosted on the AWS infrastructure. &nbsp;</p>
<!-- /wp:paragraph -->

<!-- wp:image {"align":"center","sizeSlug":"large"} -->
<div class="wp-block-image"><figure class="aligncenter size-large"><img src="https://docs.aws.amazon.com/vpc/latest/peering/images/one-to-two-vpcs-instances-diagram.png" alt=""/><figcaption>Credits: https://docs.aws.amazon.com/vpc/latest/peering/images/one-to-two-vpcs-instances-diagram.png</figcaption></figure></div>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>Now it's important to mention that this peering connection is a one-to-one connection only. </strong>&nbsp;</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>When you create VPC peering connections, each VPC cannot have an IP address overlap between them. You can have VPC peering configured between the same region or between different regions. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong><em>Is there a better alternative than one to one connection?</em></strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong><em>AWS Transit Gateway simplifies your whole network connectivity. It allows all of your VPCs to easily communicate with one another and also communicate with your remote locations as well.</em> </strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>All the routing is managed centrally within that hub and when any new remote locations or VPCs are created.&nbsp;</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Now because the Transit Gateway goes through this central hub, it allows you to centralize all your monitoring as well for your network traffic and connectivity all through the one dashboard which is great. </p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://d2908q01vomqb2.cloudfront.net/5b384ce32d8cdef02bc3a139d4cac0a22bb029e8/2020/02/02/Single-Tunnel.png" alt=""/><figcaption>Credits: https://d2908q01vomqb2.cloudfront.net/5b384ce32d8cdef02bc3a139d4cac0a22bb029e8/2020/02/02/Single-Tunnel.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>For more information about VPC peering and AWS Transit Gateway,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/peering/what-is-vpc-peering.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/peering/what-is-vpc-peering.html</a></li><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/userguide/vpc-peering.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/userguide/vpc-peering.html</a></li><li><a href="https://aws.amazon.com/transit-gateway/?whats-new-cards.sort-by=item.additionalFields.postDateTime&amp;whats-new-cards.sort-order=desc" target="_blank" rel="noreferrer noopener">https://aws.amazon.com/transit-gateway/?whats-new-cards.sort-by=item.additionalFields.postDateTime&amp;whats-new-cards.sort-order=desc</a></li><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/tgw/what-is-transit-gateway.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/tgw/what-is-transit-gateway.html</a></li></ol>
<!-- /wp:list -->

<!-- wp:heading {"level":4} -->
<h4>Q. <strong><em>What do you mean by network access control lists(NACLs)</em></strong>?</h4>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p>They are essentially virtual network-level firewalls that are associated to each and every subnet, and they help to control both ingress and egress traffic moving in and out of your VPC and between your subnets. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Whenever you create a new subnet, it will also associate a network access control list. <strong>Now by default, NACL will allow all traffic, both inbound and outbound, so it's not very secure</strong>.&nbsp;</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>The rule numbers allow you to specify what order the rules will appear inside the NACL, and as soon as traffic hits one of these rule where it matches all of the type, protocol, port range, ... it will carry out the action at the end, whether that is allow or deny.&nbsp;</p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://docs.aws.amazon.com/zh_cn/AmazonVPC/latest/UserGuide/images/nacl-example-diagram.png" alt=""/><figcaption>Credits: https://docs.aws.amazon.com/zh_cn/AmazonVPC/latest/UserGuide/images/nacl-example-diagram.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>NACLs are stateless</strong> this means that any response traffic generated from a request will have to be explicitly allowed and configured in either the inbound or the outbound ruleset, depending on where the response is coming from. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>For more information about NACLs,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/userguide/vpc-network-acls.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/userguide/vpc-network-acls.html</a></li><li><a href="https://docs.aws.amazon.com/vpc/latest/tgw/tgw-nacls.html" target="_blank" rel="noreferrer noopener">https://docs.aws.amazon.com/vpc/latest/tgw/tgw-nacls.html</a></li><li><a href="https://medium.com/kernel-space/when-to-use-security-groups-and-nacl-in-aws-e6a320ca0734" target="_blank" rel="noreferrer noopener">https://medium.com/kernel-space/when-to-use-security-groups-and-nacl-in-aws-e6a320ca0734</a></li></ol>
<!-- /wp:list -->

<!-- wp:heading {"level":4} -->
<h4><strong><em>Q. What do you mean by Security groups?</em></strong></h4>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p>They are similar to NACLs where they filter traffic both inbound and outbound but whereas NACLs worked at the subnet level, security groups work at the instance level.&nbsp;</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>There's no rule number with the security group, so with security groups, if there's a rule in there, then it's considered allowed, if there's no rule, then all traffic is dropped by default,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>Security groups are stateful which means you don't have to configure specific rules to allow return traffic from requests like you have to do with NACLs.</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>The NACLs are used for the subnet and network layer.</li><li>The security groups are used at the instance layer. </li></ol>
<!-- /wp:list -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="http://programmerprodigycode.files.wordpress.com/2021/03/e557b-awssgandnacls.jpg" alt=""/><figcaption>Credits: http://programmerprodigycode.files.wordpress.com/2021/03/e557b-awssgandnacls.jpg</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>For more information about Security Groups,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/userguide/VPC_SecurityGroups.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/userguide/VPC_SecurityGroups.html</a></li><li><a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/default-custom-security-groups.html" target="_blank" rel="noreferrer noopener">https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/default-custom-security-groups.html</a></li></ol>
<!-- /wp:list -->

<!-- wp:heading {"level":4} -->
<h4>Q. <strong>What do you mean by Nat Gateway</strong>?</h4>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p>We have the responsibility of maintaining the operating systems of our EC2 instances, then we need to be able to download updates. However, this subnet is private. So it has no access to the Internet gateway, and therefore the Internet, so how can we download those updates? </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>A NAT gateway sits within the public subnet. Because it sits within the public subnet, it has to have a public IP address in the form of an Elastic IP address(EIP), and this is assigned to the instance itself. Now because it sits within the public subnet, it has a route out to the Internet gateway, and to the Internet. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Now once we have our NAT gateway set up and configured, we need to update the route table of our private subnet. </p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://explainexampleimages.s3.ap-south-1.amazonaws.com/nat-gateway-vs-internet-gateway/NAT-Gateway-setup.png" alt=""/><figcaption>Credits: https://explainexampleimages.s3.ap-south-1.amazonaws.com/nat-gateway-vs-internet-gateway/NAT-Gateway-setup.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p>This NAT gateway will then take the request, go via the Internet gateway, and download the appropriate software that's required, and send it back to the EC2 instance requesting it. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>A NAT gateway, is that it will not accept any inbound communication initiated from the Internet. It will only accept outbound communications originating from within your VPC. So it will deny all inbound traffic that's been initiated from the Internet.&nbsp;</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>The NAT gateway itself is managed by AWS.  It's very easy to do, you simply create the NAT gateway, specify what subnet it should reside in, and associate an Elastic IP address, and AWS will manage all other configuration. <strong>So if you have multiple public subnets in different Availability Zones, you will need to set up another NAT gateway within that subnet as well. AWS will not automatically deploy a NAT gateway within each of your public subnets.&nbsp;</strong></p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://packetswitch.co.uk/content/images/2020/06/Ghost-3-x-NAT-Gateway.png" alt=""/><figcaption>Credits: https://packetswitch.co.uk/content/images/2020/06/Ghost-3-x-NAT-Gateway.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>For more information about NAT Gateway,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html</a></li><li><a href="https://aws.amazon.com/premiumsupport/knowledge-center/nat-gateway-vpc-private-subnet/" target="_blank" rel="noreferrer noopener">https://aws.amazon.com/premiumsupport/knowledge-center/nat-gateway-vpc-private-subnet/</a></li></ol>
<!-- /wp:list -->

<!-- wp:heading {"level":4} -->
<h4>Q. <strong><em>What do you mean by Bastion Hosts?</em></strong></h4>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p>Consider a scenario where you might have EC2 instances sitting in a private subnet, but you want to be able to gain access to those instances from somewhere else on the internet. But because they're sitting in the private subnet, how can you do that? </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>The bastion host sits within the public subnet and this is just another EC2 instance. This instance has to follow best practices and needs to be very secure. </strong></p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://blog.ippon.tech/content/images/2020/11/Topology.png" alt=""/><figcaption>Credits: https://blog.ippon.tech/content/images/2020/11/Topology.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p>Using this as a jump server and connect from the bastion host through to our instances in private subnet using SSH.</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>The connection process is, </strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>The engineer will be able to connect to our bastion host using the private key. </li><li>So the engineer will SSH on port 22 to our bastion host, so it'll connect via the internet. The connection will then come through the internet gateway.  </li><li>The security group says, allow connection if it's an SSH connection from this IP address of our engineer. </li><li>The engineer has access to our bastion host. But now, our engineer needs to jump across to our private instances. We're going to need a private key to do that.&nbsp;</li></ol>
<!-- /wp:list -->

<!-- wp:paragraph -->
<p><strong>We don't install private keys within the public subnet or on the bastion host because if this bastion host ever got compromised, then the malicious user will be able to use any private keys to connect to our private subnet instances.&nbsp;</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>SSH agent forwarding</strong>: allows us you to do is to store the private keys for the instances within the private subnet on your local client, so that when you connect through to the bastion host, you can then SSH, but using the private key to the EC2 instances that is stored on your client.</p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="http://justsomestuff.co.uk/theblog/wp-content/uploads/2017/01/VPC-bastion-host.png" alt=""/><figcaption>Credits: http://justsomestuff.co.uk/theblog/wp-content/uploads/2017/01/VPC-bastion-host.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>For more information about bastion hosts,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/quickstart/latest/linux-bastion/overview.html" target="_blank">https://docs.aws.amazon.com/quickstart/latest/linux-bastion/overview.html</a></li><li><a href="https://docs.aws.amazon.com/quickstart/latest/linux-bastion/architecture.html" target="_blank" rel="noreferrer noopener">https://docs.aws.amazon.com/quickstart/latest/linux-bastion/architecture.html</a></li></ol>
<!-- /wp:list -->

<!-- wp:heading {"level":3} -->
<h3>Q. <strong><em>How to connect to on-premises networks</em></strong>?</h3>
<!-- /wp:heading -->

<!-- wp:paragraph -->
<p><strong><em>A.VPN connection: </em></strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Virtual Private Network is essentially a secure way of connecting two remote networks across the internet</p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>We want to enable communications between our resources in our private subnet in our VPC in AWS and to resources that are held on premise within our data center. &nbsp;</p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>On your VPC side, you need to create something called a virtual gateway and  attach it directly to your VPC. This is managed by AWS. </li><li>In our data center, we also need another endpoint and this will be our customer gateway. </li></ol>
<!-- /wp:list -->

<!-- wp:paragraph -->
<p>Now once your virtual private gateway is attached to your VPC and configured and also your customer gateway's installed, then what we do is initiate a tunnel between the two endpoints. This VPN tunnel can only be initiated from your customer gateway. It can't be initiated from your virtual gateway. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>We have our VPN tunnel up and running created between our virtual private gateway and our customer gateway, we need to change the route table associated to this private subnet. You can also enable route propagation within your route table as well. </p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://docs.amazonaws.cn/en_us/vpc/latest/userguide/images/case-4.png" alt=""/><figcaption>Credits: https://docs.amazonaws.cn/en_us/vpc/latest/userguide/images/case-4.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>For more information on AWS VPN,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://aws.amazon.com/vpn/" target="_blank">https://aws.amazon.com/vpn/</a></li><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/vpc/latest/userguide/vpn-connections.html" target="_blank">https://docs.aws.amazon.com/vpc/latest/userguide/vpn-connections.html</a></li><li><a href="https://docs.aws.amazon.com/vpn/latest/s2svpn/VPNTunnels.html" target="_blank" rel="noreferrer noopener">https://docs.aws.amazon.com/vpn/latest/s2svpn/VPNTunnels.html</a></li></ol>
<!-- /wp:list -->

<!-- wp:paragraph -->
<p><strong>B.Direct Connect:</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Now whereas your VPN connection used the internet to get to your VPC, a Direct Connect connection doesn't traverse the internet. Instead it uses private infrastructure and connects directly to your VPC. So, there's no public network that the traffic traverses.</p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>Within our data center, we'll have a router. </li><li>Now with a Direct Connect location, there's a middle entity before you get to AWS infrastructure, now this is usually an AWS partner or an AWS customer that holds Direct Connect infrastructure and there's two parts to this.&nbsp;</li><li>There will also be a router in the AWS side as well.</li></ol>
<!-- /wp:list -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://d1.awsstatic.com/aws-answers/answers-images/active-dc-multiple-config.76bf559f32eb4ad69a32ce0fa43401390865c372.png" alt=""/><figcaption>Credits: https://d1.awsstatic.com/aws-answers/answers-images/active-dc-multiple-config.76bf559f32eb4ad69a32ce0fa43401390865c372.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p>AWS Direct Connect, it enables you to create a connection between your data center and an AWS region, not just a VPC, it's actually connected to a defined region. <strong>The reason it's connected to a region and not a VPC is that a Direct Connect connection allows you to access public as as private resources.</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>For more information about AWS Direct Connect,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://aws.amazon.com/directconnect/" target="_blank">https://aws.amazon.com/directconnect/</a></li><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/directconnect/latest/UserGuide/Welcome.html" target="_blank">https://docs.aws.amazon.com/directconnect/latest/UserGuide/Welcome.html</a></li><li><a href="https://docs.aws.amazon.com/directconnect/latest/UserGuide/direct-connect-gateways-intro.html" target="_blank" rel="noreferrer noopener">https://docs.aws.amazon.com/directconnect/latest/UserGuide/direct-connect-gateways-intro.html</a></li></ol>
<!-- /wp:list -->

<!-- wp:heading {"textAlign":"center","level":3} -->
<h3 class="has-text-align-center">Other AWS services you should know about</h3>
<!-- /wp:heading -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://d2908q01vomqb2.cloudfront.net/22d200f8670dbdb3e253a90eee5098477c95c23d/2017/11/15/SMarck-finaldiagram1.png" alt=""/><figcaption>Credits: https://d2908q01vomqb2.cloudfront.net/22d200f8670dbdb3e253a90eee5098477c95c23d/2017/11/15/SMarck-finaldiagram1.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong><em>A.Route 53:</em></strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Route 53 is Amazon's highly available and scalable domain name system that provides secure and reliable routing of requests, both for services within AWS and infrastructure that is outside of AWS. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Route 53 is able to provide this service through its global network of authoritative DNS servers that reduce latency and can be managed via the management console or API.</p>
<!-- /wp:paragraph -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/images/how-route-53-routes-traffic.png" alt=""/><figcaption>Credits: https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/images/how-route-53-routes-traffic.png</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><strong>To understand Route 53, let me explain some of the components and elements used within the service, </strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>A hosted zone is a container that holds information about how you want to route traffic for a domain. </li><li>Different domains</li><li>Resource record types</li><li>Routing Policies. When you create a resource record set, you must choose a routing policy that will be applied to it, and this then determines how Route 53 will respond to these queries. </li></ol>
<!-- /wp:list -->

<!-- wp:paragraph -->
<p><strong>For more information about AWS Route 53,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li><a rel="noreferrer noopener" href="https://aws.amazon.com/route53/" target="_blank">https://aws.amazon.com/route53/</a></li><li><a rel="noreferrer noopener" href="https://aws.amazon.com/route53/features/" target="_blank">https://aws.amazon.com/route53/features/</a></li><li><a rel="noreferrer noopener" href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/Welcome.html" target="_blank">https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/Welcome.html</a></li></ol>
<!-- /wp:list -->

<!-- wp:paragraph -->
<p><strong><em>B. AWS Cloud front:</em></strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Amazon CloudFront is AWS's fault-tolerant and globally scalable content delivery network service. It provides seamless integration with other Amazon Web Services services to provide an easy way to distribute content.</p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>Amazon CloudFront speeds up distribution of your static and dynamic content through its worldwide network of edge locations. </li><li>AWS CloudFront doesn't provide durability of your data. Instead, it distributes the source data which resides on durable storage, such as Amazon S3.</li></ol>
<!-- /wp:list -->

<!-- wp:paragraph -->
<p>AWS edge locations are sites deployed in major cities and highly populated areas across the globe. While edge locations are not used to deploy your main infrastructure, such as EC2 instances or EBS storage, they are used by AWS services such as AWS CloudFront to cache data and reduce latency for end user access. </p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p><strong>Once your distribution is configured and enabled,</strong></p>
<!-- /wp:paragraph -->

<!-- wp:list {"ordered":true} -->
<ol><li>When content from your website is accessed, the end-user will be directed to their closest edge location in terms of latency</li><li>if the content is cached by CloudFront at that edge location. If the content is there, the user will access the content from the edge location instead of the origin, therefore reducing latency. </li><li>If the content is not there, or the cache has expired for that content at the edge location, then CloudFront will request the content from the source origin again. </li><li>This content will then be used to maintain a fresh cache for any future request until it again expires.</li></ol>
<!-- /wp:list -->

<!-- wp:image {"sizeSlug":"large"} -->
<figure class="wp-block-image size-large"><img src="https://d0.awsstatic.com/product-marketing/Cloudfront-cdn-diagram-v2.PNG" alt=""/><figcaption>Credits:https://d0.awsstatic.com/product-marketing/Cloudfront-cdn-diagram-v2.PNG</figcaption></figure>
<!-- /wp:image -->

<!-- wp:paragraph -->
<p><em><strong>For more information on basics of computer networking, </strong></em><a rel="noreferrer noopener" href="https://programmerprodigy.code.blog/2021/01/19/how-does-modern-computer-networking-work/" target="_blank"><strong>https://programmerprodigy.code.blog/2021/01/19/how-does-modern-computer-networking-work/</strong></a></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>I will be spending next couple of weeks focusing on AWS Management techniques. Let me know where i could improve at?</p>
<!-- /wp:paragraph -->

<!-- wp:jetpack/contact-form {"subject":"New feedback received from your website","to":"kakabisht07@gmail.com"} -->
<!-- wp:jetpack/field-email {"required":true} /-->

<!-- wp:jetpack/field-textarea {"label":"How could i improve?"} /-->

<!-- wp:jetpack/button {"element":"button","text":"Send Feedback","textColor":"black","backgroundColor":"light-gray","className":"is-style-outline"} /-->
<!-- /wp:jetpack/contact-form -->

<!-- wp:paragraph -->
<p></p>
<!-- /wp:paragraph -->