
To set up an Azure DNS Forwarding Ruleset, you'll need to create a new resource in the Azure portal. This can be done by navigating to the DNS Forwarding Rulesets page and clicking the "Add" button.
Azure DNS Forwarding Rulesets can be used to forward DNS queries from one domain to another, which can be useful for scenarios where you have multiple domains that need to be managed together.
In the Azure portal, you can create a new DNS Forwarding Ruleset by specifying the name and resource group for the new resource. You can also choose to enable or disable the forwarding of DNS queries for the specified domain.
Azure DNS Forwarding Rulesets can be managed using the Azure portal, Azure CLI, or Azure PowerShell.
Broaden your view: Create Tenant Azure
Creating and Managing Resolver
Creating a DNS forwarding ruleset is as simple as running the command `az dns-resolver forwarding-ruleset create`. This will prompt you to provide a name for the DNS forwarding ruleset.

You can then retrieve the properties of your newly created DNS forwarding ruleset by running `az dns-resolver forwarding-ruleset show`. This will give you a detailed view of the ruleset's properties.
If you need to wait for your DNS forwarding ruleset to be created or updated, you can use the `az dns-resolver forwarding-ruleset wait` command. This will put the CLI in a waiting state until the condition you specify is met, such as when the provisioning state is 'Succeeded'.
Suggestion: Azure Private Dns Resolver
Resolver Create
To create a resolver, you need to create a DNS forwarding ruleset. This is done using the command "az dns-resolver forwarding-ruleset create".
The name of the DNS forwarding ruleset is a crucial piece of information. You'll need to provide a unique name for your ruleset.
Creating a DNS forwarding ruleset allows you to define how DNS queries are forwarded. This is a key step in setting up your resolver.
Worth a look: Azure Devops Organization
Resolver Update
Updating a resolver is an essential part of managing one. To update a resolver, you can use the az dns-resolver command.

The az dns-resolver forwarding-ruleset update command is used to update a DNS forwarding ruleset. This is a crucial step in ensuring your resolver is functioning correctly.
The polling interval in seconds is a key setting you'll want to consider when updating your resolver. This setting determines how often your resolver checks for updates.
You can update a DNS forwarding ruleset using the az dns-resolver forwarding-ruleset update command. This command allows you to make changes to your resolver's forwarding rules.
The polling interval in seconds is a critical setting that can impact the performance of your resolver. A shorter polling interval can result in faster updates, but may also increase the load on your resolver.
For more insights, see: Azure Update
Resolver Delete
Resolver Delete is a crucial feature for managing Resolvers effectively.
To delete a Resolver, go to the Resolver list and select the Resolver you want to delete. Click on the three dots next to the Resolver name and choose Delete.
If this caught your attention, see: How to Delete Azure Directory
Resolver List

To list DNS forwarding rulesets, you can use the az dns-resolver forwarding-ruleset list command. This command can list rulesets attached to a virtual network, within a resource group, or across all resource groups of a subscription.
The maximum number of results to return is 100, unless you specify a different number.
To list DNS forwarding rulesets by virtual network, use the az dns-resolver forwarding-ruleset list-by-virtual-network command. This command can also handle pagination, allowing you to retrieve more results than the default limit.
To resume pagination, provide the token value from a previously truncated response in the --next-token argument of a subsequent command.
You can also list forwarding rules in a DNS forwarding ruleset using the az dns-resolver forwarding-rule list command. This command returns up to 100 results by default, unless you specify a different number.
To handle pagination, this command also uses a token to specify where to start retrieving results.
For another approach, see: Azure Virtual Network Dns Servers
Resolver Wait
Resolver Wait is a powerful feature that allows you to pause the CLI and wait for a specific condition to be met.

You can wait until a resource is created with a provisioningState of 'Succeeded', which is a common scenario when setting up a resolver.
Alternatively, you can use a custom JMESPath query to wait for a specific condition, such as provisioningState!='InProgress' or instanceView.statuses[?code=='PowerState/running'].
Waiting for a resource to be updated with a provisioningState of 'Succeeded' is also possible.
The CLI will remain in a waiting state until the condition is met, allowing you to focus on other tasks while you wait.
Viewing Resolver Information
You can view the properties of a DNS forwarding ruleset by using the command "az dns-resolver forwarding-ruleset show". This command retrieves the DNS forwarding ruleset.
To view the properties of a specific forwarding rule within a DNS forwarding ruleset, use the command "az dns-resolver forwarding-rule show". This command retrieves the forwarding rule in a DNS forwarding ruleset.
You can use these commands to get a better understanding of your DNS forwarding ruleset and its components.
Configuring and Managing Forwarding Rulesets

To configure and manage forwarding rulesets, you can add or remove specific rules as desired. For example, you can add a rule to resolve an Azure Private DNS zone linked to your virtual network, such as azure.contoso.com.
A wildcard rule can be used to forward unmatched DNS queries to a protective DNS service. However, be careful when using a wildcard rule, as it may cause DNS resolution issues.
You should test your forwarding rules to ensure they don't cause any DNS resolution issues. This is especially important if you're using a wildcard rule.
If you include a wildcard rule in your ruleset, make sure the target DNS service can resolve public DNS names. Some Azure services have dependencies on public name resolution.
Here are some examples of rules that can be used for specific scenarios:
- A rule to resolve an Azure Private DNS zone linked to your virtual network.
- A rule to resolve an on-premises zone.
- A wildcard rule to forward unmatched DNS queries to a protective DNS service.
When linking a forwarding ruleset to a VNet, you're enabling DNS forwarding capabilities in that VNet. This can be used to enable resolution of private zones that are linked to the inbound endpoint's VNet.
Required Parameters and Procedures

To create an Azure DNS forwarding ruleset, you'll need to specify the name of the resource group and the location where you want to deploy it.
The name of the resource group is a required parameter, and it must be unique within Azure.
You can choose from over 60 Azure regions to deploy your resource group.
To create a forwarding rule, you'll need to specify the name of the DNS zone and the type of forwarding rule you want to create.
The name of the DNS zone is also a required parameter, and it must match the name of an existing DNS zone in your Azure DNS zone.
Azure DNS forwarding rulesets support both IPv4 and IPv6 addresses.
A unique perspective: Azure Create New App Service
Managing Forwarding Rulesets
You can list DNS forwarding rulesets attached to a virtual network, within a resource group, or across all resource groups of a subscription using the az dns-resolver forwarding-ruleset list command.
To list DNS forwarding rulesets by virtual network, resource group, or subscription, use the az dns-resolver forwarding-ruleset list command without specifying any additional arguments.
Explore further: Azure Virtual

The maximum number of results returned by the az dns-resolver forwarding-ruleset list command is 100, unless you specify a different value.
To list DNS forwarding rulesets by virtual network, use the az dns-resolver forwarding-ruleset list-by-virtual-network command.
The total number of items returned by the az dns-resolver forwarding-ruleset list-by-virtual-network command can be limited using the --max-results argument.
To resume pagination, provide the token value from a previously truncated response in the --next-token argument of a subsequent command.
If the total number of items available is more than the value specified, a token is provided in the command's output to resume pagination.
You can update a DNS forwarding ruleset using the az dns-resolver forwarding-ruleset update command.
The polling interval in seconds for the az dns-resolver forwarding-ruleset update command can be specified using the --polling-interval argument.
Sources
- https://learn.microsoft.com/en-us/azure/dns/private-resolver-endpoints-rulesets
- https://learn.microsoft.com/en-us/cli/azure/dns-resolver/forwarding-ruleset
- https://learn.microsoft.com/en-us/azure/dns/private-resolver-hybrid-dns
- https://github.com/MicrosoftDocs/azure-docs/blob/main/articles/dns/dns-private-resolver-get-started-portal.md
- https://learn.microsoft.com/en-us/cli/azure/dns-resolver/forwarding-rule
Featured Images: pexels.com