What should the SysOps administrator do to give the EC2 instance the ability to connect to the database?
Enter the DB instance connection string into the VPC1 route table.
Configure VPC peering between the two VPCs.
Add the same IPv4 CIDR range for both VPCs.
Connect to the DB instance by using the DB instance’s public IP address.
Explanations:
The DB instance connection string cannot be entered into the VPC1 route table, as route tables do not handle connection strings. Instead, they define the routing of traffic between subnets and VPCs.
Configuring VPC peering between VPC1 and VPC2 allows the EC2 instance in VPC1 to communicate with the RDS instance in VPC2 directly, as VPC peering establishes a private connection between the two VPCs, enabling traffic to flow between them.
Adding the same IPv4 CIDR range for both VPCs is not allowed, as CIDR blocks must be unique to avoid IP address conflicts. Additionally, this action would not establish connectivity between the two VPCs.
Connecting to the DB instance using its public IP address is not viable since the RDS instance is deployed in a private subnet. Private subnets do not have public IP addresses, and access is restricted to within the VPC or through a VPN/Direct Connect.