OCI Architect Professional study materials
OCI Architect Professional study resources

Hub-and-spoke VCN with an acquired overlapping CIDR and FastConnect

OCI Architect Professional · Put your knowledge to work in context.

All case studies

Hub-and-spoke VCN with an acquired overlapping CIDR and FastConnect

Contoso runs a production VCN 10.0.0.0/16 in Frankfurt with web 10.0.1.0/24, app 10.0.2.0/24, and database 10.0.3.0/24 subnets. A hub VCN 10.10.0.0/16 holds shared services and attaches to on-premises 192.168.0.0/16 through a DRG and FastConnect. Contoso acquires Fabrikam, whose 200 workloads sit in a VCN with CIDR 10.0.0.0/16 in the same region; re-IP is politically blocked for six months. Fabrikam needs to reach shared DNS and a logging endpoint in the hub, reach on-premises, and use the hub's NAT gateway for internet egress. It must not reach Contoso production subnets. After an LPG was attached between Fabrikam and the hub, Fabrikam can reach the hub but not on-premises; corp.internal resolves in Contoso but not Fabrikam; and private-subnet Object Storage calls from Fabrikam fail after a route to NAT was added. No workload may have a public IP.

1. Can LPG/DRG peering solve the overlapping CIDR problem? Recommend a connectivity design that meets the requirements without re-IPing Fabrikam.

Read the worked answer

No. OCI VCN peering, whether through an LPG, an RPC, or DRG attachments, requires non-overlapping CIDRs. Longest-prefix routing cannot distinguish two different 10.0.0.0/16 networks, and a DRG route table cannot hold two active routes to the same prefix pointing at different attachments. The overlap is not just between Fabrikam and Contoso production; it also affects the return path from on-premises, which would need to know which 10.0.0.0/16 is which. The robust options are to re-IP Fabrikam, which is the long-term answer, or to insert a third-party firewall/NAT appliance in a transit VCN that translates Fabrikam addresses to a unique range before advertising them to the hub and on-premises. OCI's NAT gateway is for outbound internet access, not for address translation between VCNs. If you use NAT, the hub and on-premises route only the translated range, and security policy is enforced on the appliance. Until that is built, do not attach both overlapping VCNs to the same DRG and expect isolation; the route ambiguity will cause intermittent reachability and hard-to-debug failures.

2. Why does Fabrikam fail to reach on-premises even though the LPG is up, and what route and security changes are required after the overlap is resolved?

Read the worked answer

An LPG is a point-to-point link; it is not transitive. Fabrikam can reach the hub because the LPG and route table exist, but the hub must then route 192.168.0.0/16 to the DRG, and the DRG route table must route that prefix to the FastConnect attachment. The on-premises firewall must also have a return route for Fabrikam's range. Check all four places: Fabrikam's VCN route table needs 192.168.0.0/16 to the LPG; the hub's route table needs 192.168.0.0/16 to the DRG and the Fabrikam range to the LPG; the DRG route table needs the hub attachment and the on-premises attachment; and security lists or NSGs must allow the specific ports in both directions. If the overlap is resolved by NAT, replace those prefixes with the translated range. Also verify that no more-specific route is sending traffic to an Internet Gateway or NAT gateway. LPG peering alone never provides transit to a DRG, so the missing hub route is the most likely cause.

3. Fix DNS and Object Storage private access. Which OCI constructs would you use, and what would you verify?

Read the worked answer

For DNS, a private zone is not automatically visible to every VCN. If corp.internal is a private zone associated only with the Contoso VCN, attach it to the Fabrikam VCN as well, or use a DNS resolver endpoint and forwarding rules so Fabrikam queries the hub resolver. Verify the VCN's DHCP options and resolver configuration, and test from a Fabrikam instance with dig against the VCN resolver. For Object Storage, do not send service traffic to NAT. Create a service gateway in the Fabrikam VCN, add a route rule for the regional Oracle Services Network CIDR, such as all-fra-services-in-oracle-services-network, pointing to the service gateway, and allow egress to that service CIDR in the security list or NSG. NAT gateway is only for internet destinations; OCI services use the service gateway. Verify with a curl or SDK call from a private subnet and confirm in VCN flow logs that the destination is the service CIDR, not the public Object Storage endpoint.