(Legacy networks) Create DNS forwarding rules
Your private cloud's DNS forwarding rules determines how Google Cloud VMware Engine forwards DNS requests from management appliances to the DNS servers of your on-premises services.
You can configure multiple conditional DNS forwarding rules each with one or more DNS servers associated with the domains.
Here are some example processes that require conditional DNS forwarding rules:
- Forwarding syslog messages from your private cloud vCenter to your syslog collection server by server name.
- Using an on-premises Active Directory deployment as an identity source for your private cloud.
- Using VMware Site Recovery Manager (SRM) for disaster recovery.
- Using Zerto Virtual Replication for disaster recovery.
Before you begin
The steps in this document assume that you have done the following:
- Establish a connection between your private cloud and on-premises networks
- Make your on-premises DNS server accessible to your private cloud network
Create DNS forwarding rules
To create DNS forwarding rules in your project, use one of the following methods.
Console
To create a DNS forwarding rule for a private cloud by using the Google Cloud console, complete the following steps:
In the Google Cloud console, go to the Private clouds page.
Select the private cloud to create a rule for.
On the private clouds summary page, click DNS.
Click Add rule.
Specify the domain you want to forward for and specify one or more IPv4 addresses that can resolve the domain, provided as a comma-separated list.
gcloud
To create a DNS forwarding rule for a private cloud, use the
gcloud vmware private-clouds dns-forwarding update
command. You can specify multiple rules by using multiple --rule
flags for each request.
gcloud vmware private-clouds dns-forwarding update \ --project=PROJECT_ID \ --location=ZONE \ --private-cloud=PRIVATE_CLOUD_NAME \ --rule=domain=DOMAIN,name-servers=DNS_SERVER_IP1,DNS_SERVER_IP2,.... \ --rule=domain=DOMAIN,name-servers=DNS_SERVER_IP1,DNS_SERVER_IP2,....
Replace the following:
PROJECT_ID
: the ID for your project where the private cloud is locatedZONE
: the zone for the private cloudPRIVATE_CLOUD_NAME
: the name of the private cloudDOMAIN
: the domain to be forwardedDNS_SERVER_IP1,DNS_SERVER_IP2,....
: a comma-separated list of IPv4 addresses for the authoritative DNS server
API
Create a POST
request. You can add one or more rules to each request.
curl -X POST -H "Authorization: Bearer TOKEN " -H "Content-Type: application/json; charset=utf-8" https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_NAME/dnsForwarding -d '{"forwardingRules": [ { "domain": "DOMAIN", "nameServers": [ "DNS_SERVER_IP1", "DNS_SERVER_IP2" ] }, { "domain": "DOMAIN", "nameServers": [ "DNS_SERVER_IP1", "DNS_SERVER_IP2" ] } ]}
Replace the following:
PROJECT_ID
: the ID for your project where the private cloud is locatedZONE
: the zone for the private cloudPRIVATE_CLOUD_NAME
: the name of the private cloudDOMAIN
: the domain to be forwardedDNS_SERVER_IP1,DNS_SERVER_IP2,....
: a comma-separated list of IPv4 addresses for the authoritative DNS server
Describe DNS forwarding rules
To describe DNS forwarding rules in your project, use one of the following methods.
Console
To describe a DNS forwarding rule for a private cloud by using the Google Cloud console, complete the following steps:
In the Google Cloud console, go to the Private clouds page.
Select the private cloud to create a rule for.
On the private clouds summary page, click DNS.
gcloud
To create a DNS forwarding rule for a private cloud, use the
gcloud vmware private-clouds dns-forwarding describe
command:
gcloud vmware private-clouds dns-forwarding describe \ --project=PROJECT_ID \ --location=ZONE \ --private-cloud=PRIVATE_CLOUD_NAME
Replace the following:
PROJECT_ID
: the ID for your project where the private cloud is locatedZONE
: the zone for the private cloudPRIVATE_CLOUD_NAME
: the name of the private cloud
API
Create a POST
request.
POST https://vmwareengine.googleapis.com/v1/projects/PROJECT_ID/locations/ZONE/privateClouds/PRIVATE_CLOUD_ID/dnsForwarding
Replace the following:
PROJECT_ID
: the ID for your project where the private cloud is locatedZONE
: the zone for the private cloudPRIVATE_CLOUD_NAME
: the name of the private cloud