Technology 👤 KP Expert 📅 Sep 17, 2026 👁️ 551 views

OCI DNS Resolver Explained: Default Resolver, Forwarders, and Remote Private Zones


OCI DNS Resolver Explained: Default Resolver, Forwarders, and Remote Private Zones

How OCI's resolver answers queries out of the box, how forwarders extend it to hybrid networks, and how remote private zones make a zone owned by one VCN resolvable from another.
1
Resolver auto-created per VCN
2
IPs consumed per forwarding endpoint
169.254.169.254
Default resolver query IP

The moment you create a VCN in Oracle Cloud Infrastructure, it already has a working DNS resolver — instances can resolve public names, OCI-internal hostnames, and any private zones you've attached, with zero configuration. The complexity shows up the moment a second VCN, or an on-premises network, needs to resolve names that live somewhere else. At that point you're choosing between forwarding queries to another DNS server, or making a zone owned by one VCN directly resolvable from another — and mixing these two mechanisms up is a common source of "it resolves from here but not from there" bugs.

This post walks through the default resolver, forwarders, and remote private zones — what each one actually does, and how to configure them correctly.

The Three Mechanisms, and How They Relate

Before touching the console or CLI, it's worth being precise about what each term covers, because they solve genuinely different problems:

Mechanism
What It Does
Default Resolver
Auto-created per VCN; resolves public DNS, OCI-internal hostnames, and zones in its attached view — no config needed
Forwarder
Endpoint + rule that sends matching queries to an external DNS server (on-prem, another cloud, another resolver's listener)
Remote Private Zone
Not a distinct resource — the outcome of attaching one VCN's view to a second VCN's resolver, or reaching it via listener/forwarder
The relationship in one line: the default resolver handles everything inside its own VCN automatically; forwarders reach outward to DNS servers you don't control; and remote private zones make a zone owned by one VCN visible to another, either by sharing the view directly or by having resolvers query each other over a listener/forwarder pair.
Step 1: What the Default Resolver Already Does

Every instance in a VCN is pre-configured via DHCP to send DNS queries to the reserved address 169.254.169.254 — the VCN's default resolver. You can confirm this from any instance:

check-resolver.sh
dig app.internal.example.com @169.254.169.254

cat /etc/resolv.conf
# nameserver 169.254.169.254

No zone, view, or resolver configuration is required for this to work for public names, Oracle-provided internal DNS, and any private zone already attached to the VCN's default view.

Step 2: Deploy a Forwarder for Hybrid Resolution

To resolve a domain hosted on-premises or by a third-party DNS server, create a forwarding endpoint in the VCN that needs the lookup:

create-forwarder.sh
oci dns resolver-endpoint create \
  --resolver-id "ocid1.dnsresolver.oc1...." \
  --name "fwd-onprem" \
  --endpoint-type VNIC \
  --is-forwarding true \
  --is-listening false \
  --subnet-id "ocid1.subnet.oc1...." \
  --forwarding-address "10.0.2.6"
A forwarding endpoint consumes two IP addresses in its subnet — one used for forwarding, the second reserved and unused. Undersized subnets run out of addresses faster than expected because of this.

Then add a forward rule telling the resolver which domain pattern to send there:

forwarding-rule.sh
oci dns resolver update \
  --resolver-id "ocid1.dnsresolver.oc1...." \
  --rules '[
    {
      "action": "FORWARD",
      "clientAddressConditions": [],
      "qnameCoverConditions": ["corp.example.com"],
      "destinationAddresses": ["10.100.0.10"],
      "forwardingEndpointId": "ocid1.dnsresolverendpoint.oc1...."
    }
  ]'

This means: any query for a name under corp.example.com gets sent to 10.100.0.10 — the on-prem DNS server — instead of being answered locally or sent to the internet. If you also need on-prem clients to resolve OCI-hosted zones, you'll pair this with a listener on the OCI side, covered next as part of remote private zones.

Step 3: Two Ways to Build a Remote Private Zone

Peering or DRG connectivity between two VCNs grants network reachability — it does not grant DNS resolvability. A private zone created in VCN-A's view stays invisible to VCN-B's resolver until you do one of the following.

Option A — Attach the Same View Directly

Simplest for a small number of VCNs — attach VCN-A's view to VCN-B's resolver too:

attach-view-vcnb.sh
oci dns resolver update \
  --resolver-id "ocid1.dnsresolver.oc1.vcnb...." \
  --attached-views '[{"viewId":"ocid1.dnsview.oc1.vcna...."}]'

No zone data is duplicated — VCN-B's resolver now checks the same view VCN-A already uses. This works well for a handful of VCNs but doesn't scale cleanly: every new VCN needs every relevant view attached by hand.

Option B — Listener on the Owning VCN, Forwarder on the Consumer

Instead of sharing the view, let the two resolvers talk to each other over the network. On VCN-A (the zone owner), deploy a listener:

create-listener.sh
oci dns resolver-endpoint create \
  --resolver-id "ocid1.dnsresolver.oc1.vcna...." \
  --name "lsn-vcn-a" \
  --endpoint-type VNIC \
  --is-forwarding false \
  --is-listening true \
  --subnet-id "ocid1.subnet.oc1.vcna...." \
  --listening-address "10.0.1.6"
A listening endpoint consumes one IP from the subnet. That IP is what VCN-B's forwarder will target.

Then on VCN-B, deploy a forwarder and rule pointing at that listener IP, using the same forwarder pattern from Step 2 — just with the destination address set to VCN-A's listener instead of an on-prem DNS server.

The Hub Pattern: Scaling Beyond Two VCNs

For more than a couple of VCNs, attaching every view to every resolver directly becomes unmanageable. The pattern that scales is designating one VCN as a DNS hub:

  • The hub VCN's resolver has every relevant private view attached — giving it visibility into every private zone in the region.
  • The hub runs both a listener (so spokes and on-premises networks can query it) and a forwarder (so it can reach external DNS for anything it doesn't own).
  • Every spoke VCN runs only a forwarder, with a rule pointing at the hub's listener.

This collapses what would otherwise be N×N view attachments into a single hub resolver holding all the views, with spokes doing one forwarding hop. It also gives you a single place to manage forwarding rules for on-premises domains, instead of repeating that configuration on every VCN.

Common Pitfalls
Pitfall
Why It Matters
Assuming peering grants resolution
Network reachability and DNS resolvability are independent — a view still has to be attached or reached via listener/forwarder
Undersized forwarder subnet
A forwarding endpoint consumes two IPs, so a tightly sized subnet can run out faster than expected
Treating remote private zones as a resource type
There's no "remote zone" object to create — it's an outcome of view attachment or listener/forwarder configuration
Missing port 53 security rules
Configuration can be entirely correct and still fail if UDP/TCP 53 is blocked between listener and forwarder
Forward rule pattern too broad or narrow
A mismatched qname condition either fails to catch intended queries or unintentionally intercepts unrelated ones
Where This Fits

DNS design in Oracle OCI follows the same hub-and-spoke thinking that governs routing and security architecture at scale: a small environment can get away with the default resolver plus a couple of direct view attachments, but anything expecting to grow — multiple business units, hybrid on-premises connectivity, multi-VCN landing zones — benefits from planning the forwarder/listener/hub topology early, rather than retrofitting it once a tangle of point-to-point view attachments has already accumulated.

Recap: what to take away

  • Every VCN gets a default resolver automatically — public DNS, OCI-internal hostnames, and attached-view zones resolve with zero configuration.
  • Forwarders (endpoint + rule) send matching queries outward to a DNS server you don't control — on-prem, another cloud, or another resolver's listener.
  • A remote private zone isn't a resource type — it's achieved by attaching a shared view directly, or by pairing a listener on the owning VCN with a forwarder on the consuming VCN.
  • A hub VCN with all views attached, running both a listener and a forwarder, collapses N×N view sprawl into a single forwarding hop for spokes.
OCI NETWORKING SERIES Published by KP Expert →
Recently Enrolled

Student enrolled in this course.

View course
Explore Courses

Latest from @kp__expert

Follow on Instagram
Loading Instagram posts...

AI Course Assistant

Share your details and goals to get the best course recommendations.

Recommended Courses

Select a course name to view full details.

Course Details
Enrollment & Contact
  • Review selected course and confirm your enrollment request.
  • Click checkout to move into the full payment process.
  • After payment submission, your enrollment is processed by our team.
Admissions Contact
Email: info@kpexpert.com
Phone: +91 92708 37105
Your submitted details
Name, email and phone will appear here.
Your request has been submitted successfully. Our team will contact you shortly.