Connecting VPCs in AWS: Cost-Effective Resource Access Solution

Connecting VPCs for Resource Access: A Cost-Effective Approach

Prev Question Next Question

Question

A company has a set of resources hosted in a VPC.

They have acquired another company, and they have their own set of resources hosted in AWS.

The requirement now is to ensure that resources in the VPC of the parent company can access the resources in the VPC of the child company.

What is the best way to accomplish this with minimum costing involved?

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D.

Answer - D.

VPC Peering allows you to connect VPCs together.

The VPCs themselves can be in different regions and different AWS accounts.

Option A is incorrect since this would bear a high cost.

Options B and C are incorrect since you should use VPC peering.

For more information on VPC Peering, please refer to the below URL:

https://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/vpc-peering.html

To allow resources in one VPC to communicate with resources in another VPC, there are different options available in AWS. Let's examine each of the options given and determine which one would be the best fit for this scenario:

A. Use a Direct Connect connection with a private VIF Direct Connect provides dedicated, private network connectivity between AWS and an on-premises data center or co-location environment. While Direct Connect can be used to connect two VPCs, it is typically not the best option in this scenario as it is expensive and complex to set up.

B. Establish a NAT gateway to establish communication across VPCs A NAT gateway is used to provide outbound internet access to resources in a private subnet. While it is possible to use a NAT gateway to allow resources in one VPC to communicate with resources in another VPC, this option can be complex and costly as it requires the creation of multiple NAT gateways.

C. Use a VPN connection to peer both VPCs A VPN connection can be used to connect two VPCs together, allowing them to communicate with each other as if they were on the same network. VPN connections are a cost-effective solution, but they can be complex to set up and manage.

D. Use VPC Peering to peer both VPCs VPC peering is a feature that allows resources in one VPC to communicate directly with resources in another VPC using private IP addresses. It is a cost-effective solution that is easy to set up and manage.

Based on the requirements of the scenario and the available options, the best solution is to use VPC peering to connect the VPCs of the two companies. This option is cost-effective, easy to set up, and provides a secure and direct connection between the two VPCs, allowing resources to communicate with each other as if they were on the same network.