Practice Exams:

Microsoft AZ-104: Troubleshoot VNets, Routes, and DNS

Cloud & Architecture

An Azure network connection can fail even when the virtual machines are healthy and the network security groups appear permissive. A wrong destination address, an unintended next hop or an incorrect DNS answer can produce similar symptoms. Troubleshooting is faster when you prove each part of the path separately rather than changing routes, peering and security rules at once. One wrong DNS answer can send a healthy application toward a destination that no route or security rule was designed to reach. Capturing the source, destination, next hop, and name-resolution result before changing settings prevents a misleading symptom from becoming a wider outage.

On this page
  1. Describe the failed flow before changing the network
  2. Verify address spaces and peering state first
  3. Use effective routes to prove the next hop
  4. Test security rules after identifying the route
  5. Diagnose DNS separately from routing
  6. Distinguish private endpoint name resolution from private routing
  7. Work through a fault without changing three variables
  8. Use Network Watcher as evidence, not a magic repair button

Describe the failed flow before changing the network

Begin with a test that another administrator could repeat. Record the source VM and network interface, source address, destination hostname or IP address, transport protocol, destination port and expected path. A useful Microsoft AZ-104 network lab tests address space, effective routes and DNS resolution separately before changing the virtual network configuration.

Also record whether the failure is a timeout, a refused connection, a DNS error or an application response. Those symptoms suggest different boundaries, but they do not prove a root cause by themselves.

Consider a VM at 10.10.1.4 that must reach app.internal.example over TCP 443. The service inventory says the target should be 10.30.1.10, but the client times out. The name could resolve incorrectly, a custom route could point to an unavailable appliance, or an NSG could deny the flow.

For a failed source-to-service connection, collect measurements that separate competing causes before changing configuration. Compare the resolved destination address with the expected private or public endpoint, inspect the effective route from the source subnet, and determine whether a network security rule or service firewall actually denies that flow. After correcting the specific fault, repeat the original test from the same client and confirm both connectivity and the intended security boundary. A successful portal save is not proof of repaired networking; the packet path and resolver behavior must agree with the hypothesis.

Test the target by its expected IP address as well as its hostname where the protocol permits. A successful IP test with a failing name-based test narrows the problem toward resolution or application-level name handling.

A failed IP test keeps routing, filtering, the return path and the destination service in scope. Document the exact observation; do not substitute the phrase “network broken” for a reproducible fault.

Verify address spaces and peering state first

Azure virtual network address ranges and subnet ranges determine which private IPs can be assigned and what Azure regards as local network space. Two VNets intended for peering must have nonoverlapping address spaces. If the ranges overlap, peering configuration fails; this cannot be fixed by opening a port on an NSG.

Check both VNets’ address-space settings and the subnets holding the relevant interfaces. Then inspect both directions of the peering. Azure creates a peering relationship from each VNet, and the connected state must be established as expected. If a peer’s address range changed, verify that remote peering information has been synchronized. A green resource list does not replace checking the actual learned addresses.

Do not assume peering creates general transit. If spoke A peers with a hub and spoke B peers with the same hub, A does not automatically route through the hub to B.

A network virtual appliance, supported routing configuration or separate direct peering may be required. Treat the intended topology as a diagram with routes you can inspect, not as a collection of connected labels.

Use effective routes to prove the next hop

Azure creates system routes, while user-defined routes and advertised gateway routes can change the effective path. Inspect the effective routes on the source VM’s network interface, not just the route-table object: routes from all applicable sources and associations determine what the VM uses. In the portal, open the NIC’s effective routes view.

For the following read-only CLI command, the VM attached to the NIC must be running; Microsoft documents that a stopped VM does not return effective-route output. Confirm the intended subscription, source NIC and appropriate permission before querying:

az network nic show-effective-route-table \
  --resource-group rg-app-test \
  --name nic-app-01 \
  --output table

Replace the sample resource group and NIC names with values from the affected environment. A VM with multiple interfaces can have different route sets on each. Find the route matching the destination address, note the prefix and next-hop type, and compare the result with the intended design. A default route through an appliance may be correct for internet egress but wrong for a private service if its routes or return path were not designed accordingly.

A route into an appliance does not prove the appliance forwards traffic or that the reply returns through a compatible path. Stateful inspection can fail when outbound and return traffic take different paths. When one-way evidence exists, inspect the effective routes at the destination and at any appliance or gateway in the path before adding another arbitrary route.

Test security rules after identifying the route

Network security groups decide whether traffic matching their effective rules is permitted at the relevant interfaces and subnets. They do not repair address-space overlap, a wrong DNS answer or an incorrect next hop. Diagnose filtering only after you understand what endpoints the traffic is trying to connect.

Compare the packet’s source, destination, protocol and port with effective NSG rules. Consider both the source outbound and destination inbound paths. Application security groups can participate in rule matching. A rule that appears to allow a port may still be shadowed by a higher-priority deny rule or may apply to the wrong subnet or NIC.

Network Watcher’s IP flow verify can help identify whether an effective NSG rule allows or denies a specified flow. Treat that observation as a filtering test, not as proof that the application is listening or that DNS, routes and remote firewalls are correct. Security rules should be modified only after the rule that caused the failure is known; then confirm that the change did not broaden unrelated access.

Diagnose DNS separately from routing

DNS translates a name into one or more addresses; it does not establish connectivity to the returned address. If the client resolves app.internal.example to an obsolete IP, perfect routing to the actual service IP cannot save the original request. Capture the full name queried, the resolver used, the record type, the answer and the time the answer was observed.

For Azure-provided name resolution, check whether the private DNS zone is linked to the correct virtual network. A zone existing in the subscription is not enough. VNet links determine which networks can resolve records from that zone; an additional peered VNet may need its own link or a deliberate DNS-forwarding design.

If a VNet uses custom DNS, inspect conditional forwarders and resolver reachability. A custom server can return the wrong address, fail to forward a private-zone query or keep an outdated response cached.

For hybrid lookups, on-premises resolvers cannot simply use the Azure-internal 168.63.129.16 address as if it were globally reachable. Azure DNS Private Resolver or another supported forwarding design is needed when the request crosses boundaries.

Distinguish private endpoint name resolution from private routing

A private endpoint associates a PaaS service with a private address in a VNet. Its DNS configuration is part of the service path. The public service name may need to resolve through an appropriate private DNS zone to the private endpoint address. Creating the endpoint without the correct zone relationship can leave clients trying to reach the service through the public route.

Test the answer from the actual caller rather than from an administrator laptop in another network. Verify which private zone is queried, whether the VNet has a resolution link and which custom DNS forwarders participate. A test from one network can pass while another client sees the public endpoint because the two clients use different resolvers.

Do not make network security more permissive merely to compensate for a name-resolution error. Fix the name-to-address path first, then verify the selected route, firewall rules, target service and authentication. A successful TCP connection does not prove that the application accepts the client’s identity or TLS host name.

Work through a fault without changing three variables

Return to the hypothetical VM at 10.10.1.4. Its resolver returns the expected 10.30.1.10. The NIC’s effective route for 10.30.0.0/16 sends traffic through the intended stateful appliance at 10.20.0.4. Both relevant NSG checks permit TCP 443. The application still times out, so neither DNS nor the checked NSG rules explain the failure.

Suppose the service-side packet capture confirms that the SYN arrives and the server sends a SYN-ACK, but the source never receives it. On the service subnet, an effective route for 10.10.0.0/16 points to 10.20.0.9, an old appliance no longer forwarding traffic. That stale return-path UDR is the specific fault: the reply is sent toward a dead next hop rather than the inspected path.

Save the before-and-after return-route entries, both flow directions, the original failure and the successful expected retest in one incident worksheet. If the source still times out, the hypothesis has not been confirmed; revisit appliance filtering, destination listeners and return routing instead of reporting success prematurely.

Run the test again from the same source and port after the change. Preserve the before-and-after route observations and the selected packet-test result. A useful incident record answers what failed, how you isolated it, what changed and why that change fixed this particular path. An “everything now works” message without evidence does not help when the failure returns.

Use Network Watcher as evidence, not a magic repair button

Network Watcher tools answer different questions. Next hop and effective routes show route selection, IP flow verify examines an NSG’s verdict, and connection troubleshoot tests reachability in supported scenarios. None replaces a destination-side service check or proof that return packets reach the caller.

Keep one reusable record for every failed flow: source NIC and address, target hostname and expected IP, resolved address, prefix and next hop in each direction, effective NSG verdicts, destination listener, original error, exact change and post-change result. This checklist makes the next investigation faster because another engineer can replay the evidence without guessing which layer was changed.

In the worked example, the distinguishing observation is the stale destination return route. No broader NSG allow rule, new peering or DNS edit is justified by that evidence. The least disruptive solution is the single approved return-route correction followed by a verified handshake.

Continue learning

Related guides

Private EndpointsTrace name resolution, private access and authorization boundaries.Azure DNS FailuresDiagnose resolution mistakes before changing routing or filters.Azure RBAC Roles and ScopeCheck whether permissions—not network paths—cause a denied operation.Azure Networking ArchitectureUnderstand deeper networking design beyond initial administration.

Related Posts

• Microsoft AZ-104: What Azure Administrators Actually Do

• Unlocking Cloud Potential: A Beginner’s Journey into Microsoft Azure Certifications

• Unveiling Microsoft Azure: The Future of Intelligent Cloud Solutions

• Microsoft AZ-104 vs. AZ-900: Which Should You Take?

• Exploring the AZ-900 Certification – Your Gateway to Cloud Computing Mastery

• Cloud-Native App Architecture Using Microsoft Azure Cosmos DB

• Cloud Guardian: Unlocking Your Potential with Microsoft’s AZ-500

• Microsoft AZ-104: Managed Identities in Azure

• Microsoft AZ-104: Azure DNS Troubleshooting

• Microsoft AZ-104: Entra Roles and Access