AZ-104 practice by domain

AZ-104 Virtual Networking Practice Questions

Ten practice questions from the CramHQ AZ-104 bank for Implement and Manage Virtual Networking, with answers and explanations. No signup needed.

Question 1 of 10Implement and Manage Virtual Networking

CramHQ is adding an Azure region for dispatch routing. The workload will be placed in its own spoke and must communicate privately through the existing hub virtual network to corporate datacenters. The app team proposes reusing part of the hub's private address plan to keep firewall rules familiar. Which recommendation best prevents a deployment that later cannot be connected while still allowing normal workload subnet design?

  1. A. Create the spoke virtual network with the proposed CIDR block, then use Azure Virtual Network Manager to deploy hub-and-spoke connectivity.
  2. B. Create the spoke virtual network with the proposed CIDR block, then use Azure VPN Gateway NAT for the hub and datacenter paths.
  3. C. Create the spoke virtual network with a CIDR block unused by the hub and datacenters, then create the required workload subnets inside that block.
  4. D. Create the spoke virtual network with the proposed CIDR block, then attach route tables with more-specific user-defined routes toward the hub and datacenters.
Show answer and explanation

Answer: C

This resolves the routability conflict at the address-plan level. Peering and hybrid routing can advertise distinct prefixes, and subnets can then be carved without inheriting an ambiguous destination.

If you picked A

Why it is tempting: Azure Virtual Network Manager is associated with deploying network connectivity at scale, so it can look like the right tool for a hub-spoke expansion.

Why it is wrong: Connectivity orchestration does not remove the requirement for non-overlapping address spaces between connected networks.

If you picked B

Why it is tempting: NAT is commonly associated with handling overlapping private ranges in some cross-premises designs.

Why it is wrong: Plan the spoke VNet with prefixes that do not overlap the hub or on-premises ranges when it must participate in normal hub-spoke private connectivity.

If you picked D

Why it is tempting: Route tables control next hops, so they can look like a way to force traffic toward the hub or datacenters.

Why it is wrong: User-defined routes influence traffic after valid connectivity and unambiguous prefixes exist; they do not legitimize overlapping connected address spaces.

Question 2 of 10Implement and Manage Virtual Networking

CramHQ hosts engineering apps in two peered spoke virtual networks. A shared Azure SQL Database is exposed through a private endpoint in a third spoke, and the endpoint's A record already exists in the recommended zone. The apps use Azure-provided DNS and must keep using the normal database FQDN; VM host records must not be added to that zone. What should you configure?

  1. A. Use Azure Private DNS zone privatelink.database.windows.net; add a virtual network link to one application virtual network with auto registration disabled and rely on peering for the other.
  2. B. Use Azure Private DNS zone privatelink.database.windows.net; add virtual network links to both application virtual networks with auto registration enabled.
  3. C. Use Azure Private DNS zone privatelink.database.windows.net; add virtual network links to both application virtual networks with auto registration disabled.
  4. D. Use Azure Private DNS zone privatelink.database.windows.net; add a virtual network link only to the private endpoint virtual network with auto registration disabled.
Show answer and explanation

Answer: C

This associates the existing endpoint record with each network where clients query Azure-provided DNS, while avoiding automatic VM host records in the service-specific zone.

If you picked A

Why it is tempting: The peered networks can have network connectivity, so it can look like one linked application VNet is enough for both apps.

Why it is wrong: Each client VNet that uses Azure-provided DNS must be linked to the private DNS zone, unless a separate DNS forwarding design is provided.

If you picked B

Why it is tempting: Linking both application VNets fixes the resolution reach requirement, so the enabled registration setting can seem harmless.

Why it is wrong: Use resolution-only private DNS zone links when clients only need to query an existing service endpoint record and VM host records must not be added.

If you picked D

Why it is tempting: The endpoint network feels like the natural place to attach the private DNS zone because the private IP and A record belong to that endpoint.

Why it is wrong: Private DNS zone links must serve the resolving client VNets, not merely the VNet that contains the private endpoint network interface.

Question 3 of 10Implement and Manage Virtual Networking

CramHQ is moving the public name claims.cramhq.com to records managed in an Azure DNS zone named cramhq.com. The A record was created in Azure, but internet clients still resolve the old provider's address. The domain remains registered with a third-party registrar. Which recommendation should ensure public resolvers use the Azure-hosted records?

  1. A. At the old DNS provider, create a CNAME record for claims.cramhq.com that points to the Azure DNS zone name cramhq.com.
  2. B. In the Azure DNS zone, change the SOA record contact and refresh values so recursive resolvers reload the cramhq.com zone.
  3. C. In the Azure DNS zone, add an NS record set at @ that lists the Azure DNS name servers assigned to the zone.
  4. D. In the registrar's DNS settings, replace the domain's name servers with all Azure DNS name servers assigned to the cramhq.com zone.
Show answer and explanation

Answer: D

Azure DNS can host the records, but public resolvers reach them only when the registrar publishes the Azure-assigned name servers for the registered domain.

If you picked A

Why it is tempting: A CNAME can redirect one host name to another, so it can look like a record-level fix for a moved service name.

Why it is wrong: Use records such as CNAMEs for name aliases only after resolvers are querying the authoritative zone that contains them.

If you picked B

Why it is tempting: SOA refresh and contact values are visible in the zone, so they can look related to how resolvers reload DNS data.

Why it is wrong: SOA settings do not move public authority; parent-side delegation must point the registered domain to the intended authoritative name servers.

If you picked C

Why it is tempting: Adding Azure name servers at the zone apex resembles delegation and uses the right type of record.

Why it is wrong: For a registered public domain, update the registrar's name-server settings to delegate the domain to Azure DNS.

Show all 10 practice questions
Question 4 of 10Implement and Manage Virtual Networking

CramHQ runs incident-processing VMs in a spoke VNet. A peered ingestion tier and an on-premises SOC connected through ExpressRoute must reach the workers through one stable address, while no endpoint for the workers can be reachable from the internet. The workers expose TCP 443 and are in one region. Which load-balancing configuration should you recommend?

  1. A. Deploy a Standard Azure Load Balancer with a private frontend IP in the ingestion VNet, add worker NICs to the backend pool, and use a TCP 443 rule with a health probe.
  2. B. Deploy a Standard Azure Load Balancer with a public frontend IP, add worker NICs to the backend pool, and use network security group rules to allow only known source ranges.
  3. C. Deploy a Standard Azure Load Balancer with a private frontend IP in the spoke VNet, add worker NICs to the backend pool, and use a TCP 443 rule with a health probe.
  4. D. Deploy a Standard Azure Load Balancer with a private frontend IP in the spoke VNet, add worker NICs to the backend pool, and create inbound NAT rules for TCP 443.
Show answer and explanation

Answer: C

A private frontend IP is reachable from the virtual network, peered networks, and connected on-premises networks without creating an internet endpoint. The TCP rule and probe distribute only to healthy worker instances.

If you picked A

Why it is tempting: The frontend is private, and peered VNets can communicate privately, so the option looks aligned with the no-internet requirement.

Why it is wrong: Keep the load balancer frontend and the NIC-based backend pool members aligned within the VNet scope supported by the load-balancing rule.

If you picked B

Why it is tempting: NSG rules can limit who is allowed through, so the configuration can appear private from an access-control perspective.

Why it is wrong: A public frontend IP creates an internet-facing load balancer endpoint; use a private frontend IP when the endpoint must be reachable only through private networking.

If you picked D

Why it is tempting: The frontend is private and in the worker VNet, so the exposure and location cues look correct.

Why it is wrong: Use a load-balancing rule with a health probe when one listener must distribute traffic across backend instances.

Question 5 of 10Implement and Manage Virtual Networking

CramHQ publishes a case intake API from two Azure VMs in the same virtual network. During maintenance, either VM can be rebuilt without changing the client-facing endpoint, and firewall records must not identify individual VM addresses. Administrators also need inbound access controlled by existing network security rules on the workload subnets. Which recommendation best meets the requirement?

  1. A. Create a Standard public IPv4 address, associate it with an Azure NAT Gateway on the subnet, and keep the VMs behind an internal load balancer.
  2. B. Create a Standard public IPv4 address, associate it with an Azure Standard Load Balancer frontend, and place both VMs in the backend pool.
  3. C. Create a Standard public IPv4 address on a network virtual appliance NIC, route Internet-bound subnet traffic to the appliance, and publish that address.
  4. D. Create one Standard public IPv4 address for each VM network interface, publish both addresses in Azure DNS, and keep matching NSG rules.
Show answer and explanation

Answer: B

A Standard public IP address can be associated with a Standard Load Balancer frontend. Clients use one stable frontend while the VMs remain backend members, and subnet or NIC NSG rules control allowed inbound traffic.

If you picked A

Why it is tempting: NAT Gateway uses Standard public IP addresses, so it can look like a way to give a subnet a public endpoint.

Why it is wrong: Use NAT Gateway for outbound source translation from a subnet; use a public load balancer frontend when clients need to initiate inbound connections to backend VMs.

If you picked C

Why it is tempting: Network virtual appliances and route tables are often used to control traffic paths, so they can appear relevant when firewall or routing language is present.

Why it is wrong: A route table next hop should match the traffic path you need to control; it does not automatically turn an appliance NIC public IP into a shared load-balanced API endpoint.

If you picked D

Why it is tempting: Public IPs on VM NICs can support inbound access, and DNS can publish multiple records for a service name.

Why it is wrong: When the requirement forbids identifying individual VM addresses, put the public IP on a shared frontend rather than on each VM NIC.

Question 6 of 10Implement and Manage Virtual Networking

CramHQ deployed an alert relay VM in a spoke virtual network. After simultaneous route table and network security changes, outbound connections from the VM to an allied collector time out. The team must first determine whether the exact source, destination, protocol, and port would be blocked at the VM boundary before reviewing path selection or packet contents. Which recommendation is best?

  1. A. Use Azure Network Watcher connection troubleshoot from the relay VM to the collector endpoint and port.
  2. B. Use Azure Network Watcher IP flow verify on the VM NIC with the collector IP, protocol, direction, and port.
  3. C. Use Azure Network Watcher next hop on the VM NIC with the collector IP as the destination.
  4. D. Use Azure Network Watcher packet capture on the relay VM NIC with a filter for the collector endpoint and port.
Show answer and explanation

Answer: B

IP flow verify evaluates whether traffic with the specified details is allowed or denied for a VM network interface by applicable security rules, matching the team's first decision point.

If you picked A

Why it is tempting: Connection troubleshoot includes endpoint and port details, so it can look like the closest fit for a failed connection.

Why it is wrong: Use IP flow verify when the first question is whether a specified flow tuple is allowed or denied at a VM network interface.

If you picked C

Why it is tempting: Route table changes happened at the same time, so next hop looks relevant to the outage.

Why it is wrong: Use next hop when the diagnostic question is which route Azure selects toward a destination; use IP flow verify for a VM NIC allow-or-deny decision.

If you picked D

Why it is tempting: A packet capture filter can target the same endpoint and port, which makes it feel precise.

Why it is wrong: Use packet capture to collect traffic evidence; use IP flow verify to evaluate the configured allow-or-deny result for a VM NIC flow.

Question 7 of 10Implement and Manage Virtual Networking

CramHQ moved an analytics VM into a subnet that uses an Azure Firewall in a hub for outbound inspection. The VM can resolve names, but connections to an approved market-data API now time out. Its subnet NSG already has an allow rule for the API TCP port. You need to inspect the applied route entries on the VM network interface and confirm which route selects the next hop for the API prefix. What should you review?

  1. A. Run IP flow verify in Network Watcher for the API address and port, and use the matching rule result as the next-hop validation.
  2. B. Review Effective routes on the VM network interface in Network Watcher and verify the selected next hop for the API prefix.
  3. C. Run Next hop in Network Watcher from the VM to the API address, and use it instead of reviewing the interface's applied route entries.
  4. D. Review Effective security rules on the VM network interface in Network Watcher and verify that an outbound allow rule matches the API port.
Show answer and explanation

Answer: B

Effective routes shows the routes applied to a network interface, including system routes, user-defined routes, and propagated routes. It is the right view to confirm whether the destination prefix uses the intended next hop.

If you picked A

Why it is tempting: The API address and port are in the stem, so IP flow verify looks relevant to the timeout.

Why it is wrong: IP flow verify answers whether security rules allow or deny a flow; Effective routes answers which route entry and next hop apply to the destination prefix.

If you picked C

Why it is tempting: Next hop is a routing diagnostic and can report the next hop for the API address.

Why it is wrong: Use Next hop to test the next-hop result for a destination; use Effective routes when the requirement is to inspect the applied route entries that explain the selection.

If you picked D

Why it is tempting: The timeout and TCP port make an outbound security rule check feel relevant.

Why it is wrong: Effective security rules show the NSG rules applied to the NIC or subnet; they do not show which route or next hop traffic will use.

Question 8 of 10Implement and Manage Virtual Networking

CramHQ publishes HTTPS inference requests through an Azure Standard Load Balancer to a backend pool of gateway VMs. New client sessions must be spread only across healthy gateways. Operators also need break-glass SSH to a chosen gateway through the same public frontend IP by using predictable, unique external ports. A recent change made HTTPS reach a single VM instead of the healthy pool. Which recommendation best corrects the configuration?

  1. A. Use an Azure Load Balancer load balancing rule for TCP 443 with a health probe, and use separate inbound NAT rules with unique frontend ports for SSH.
  2. B. Use Azure Load Balancer inbound NAT rules for TCP 443 and SSH, assigning each gateway unique frontend ports and keeping the existing health probe.
  3. C. Use an Azure Load Balancer inbound NAT rule for TCP 443 with the gateway backend pool, retain the health probe, and use inbound NAT rules for SSH.
  4. D. Use an Azure Load Balancer load balancing rule for TCP 443, and use another load balancing rule for TCP 22 with session persistence set to Client IP.
Show answer and explanation

Answer: A

A load balancing rule uses the backend pool and probe state when selecting healthy gateways for new HTTPS flows. Inbound NAT rules provide deterministic per-gateway port forwarding for SSH without replacing the shared HTTPS path.

If you picked B

Why it is tempting: Unique frontend ports are correct for per-VM SSH, so applying that same pattern to TCP 443 can look consistent.

Why it is wrong: Inbound NAT rules forward to designated backend instances; a shared HTTPS service needs a load-balancing rule to distribute flows across healthy backends.

If you picked C

Why it is tempting: The option mentions the backend pool and health probe, which are real load balancer concepts tied to healthy service traffic.

Why it is wrong: The traffic construct matters first: use a load-balancing rule for pooled service distribution, and reserve inbound NAT rules for direct instance forwarding.

If you picked D

Why it is tempting: Using a load-balancing rule for TCP 443 is correct, and Client IP persistence sounds like a way to keep traffic tied to one backend.

Why it is wrong: Session persistence only influences repeated load-balanced flow selection; chosen per-VM SSH access through unique external ports requires inbound NAT rules.

Question 9 of 10Implement and Manage Virtual Networking

CramHQ has a shared-services virtual network and three workload virtual networks in different subscriptions, including one in another Azure region. The workload VMs have only private IP addresses. Admins must use browser-based RDP/SSH from Azure, and the team wants the fewest managed jump points. Which recommendation should you make?

  1. A. Deploy Azure Bastion Basic in the shared-services virtual network and configure virtual network peering, including global peering where required, to each workload virtual network.
  2. B. Deploy Azure Bastion Basic in the shared-services virtual network and rely on hub gateway transit to reach workload virtual networks without direct peering.
  3. C. Deploy Azure Bastion Basic separately in each subscription and configure local virtual network peering only within that subscription.
  4. D. Deploy Azure Bastion Standard in an Azure Virtual WAN hub and route traffic from the hub to each workload virtual network.
Show answer and explanation

Answer: A

This uses a supported dedicated deployment and extends reach through virtual network peering, including global peering. VMs in directly peered networks can be reached by private IP without VM public IPs.

If you picked B

Why it is tempting: Gateway transit sounds like it should extend hub connectivity to spoke networks without more peering work.

Why it is wrong: Gateway transit shares VPN or ExpressRoute gateway connectivity; it does not replace the direct peering boundary required for this centralized Bastion design.

If you picked C

Why it is tempting: Different subscriptions often imply separate ownership and can make separate management resources seem required.

Why it is wrong: Azure Bastion placement is based on supported VNet reachability, not on needing one deployment per subscription when cross-subscription peering can be used.

If you picked D

Why it is tempting: A Virtual WAN hub is designed for centralized connectivity, so it can appear to be the best place for a shared jump point.

Why it is wrong: Azure Bastion must be deployed in a supported virtual network placement; deploying it in an Azure Virtual WAN hub is not supported.

Question 10 of 10Implement and Manage Virtual Networking

CramHQ's grid analytics subnet hosts collectors and shared operations tools. A new telemetry storage account must be reachable from collectors, and auditors require an approval record on that account for this connection rather than accepting membership in the collectors' network segment as the control. The operations tools still need normal Azure access paths. Which recommendation best meets the requirement?

  1. A. Create an Azure Private Endpoint for the storage account blob subresource and configure the privatelink.blob.core.windows.net private DNS zone for the collectors.
  2. B. Enable a Microsoft.Storage virtual network service endpoint on the collectors subnet and add a storage account virtual network rule for that subnet.
  3. C. Assign Azure NAT Gateway to the collectors subnet and add the gateway public IP address as a storage account IP network rule.
  4. D. Enable a Microsoft.Storage virtual network service endpoint on the collectors subnet and attach a service endpoint policy allowing only the telemetry storage account.
Show answer and explanation

Answer: A

Azure Private Endpoint creates a private endpoint connection on the storage account subresource. Private DNS lets collectors resolve the account to that connection, giving the storage owner a resource-level approval boundary.

If you picked B

Why it is tempting: A storage service endpoint plus a storage account virtual network rule is a valid way to allow traffic from a subnet to Storage.

Why it is wrong: Service endpoint access is anchored to the subnet and storage firewall rule; it does not create a private endpoint connection approval on the storage account.

If you picked C

Why it is tempting: A NAT Gateway public IP can make outbound access easier to recognize and allow in firewall rules.

Why it is wrong: A shared public egress IP rule is not a private endpoint and does not provide a storage-account-owned approval record for a specific private connection.

If you picked D

Why it is tempting: A service endpoint policy can allow only selected storage accounts, so it sounds resource-specific.

Why it is wrong: Service endpoint policies restrict which storage resources a subnet can reach over service endpoints, but the enforcement remains subnet-scoped.

CramHQ links wrong answers to the mistake behind them. The free diagnostic finds yours, then your Pass Plan works on them.