External DNS in GCP Cloud

GCP VPC networks have an internal DNS service but do not support configuring an external DNS for an instance. Enterprise customers typically use various DNS servers within the organization and therefore require a mechanism to configure DNS server settings for migrated machines.

Velostrata provides a way to set and control the DNS settings of migrated machines in a persistent manner. You can configure the DNS settings in the GCP project (and region) as GCP Project Metadata. This will then apply to all instance migrated to GCP by Velostrata.

When empty DNS metadata is provided, for example, default-dns-servers = “”, the DNS configuration will be overwritten with values from DHCP.

To configure the external DNS in GCP:

  1. In the Google Cloud Platform Console, go to the Metadata page for your project.
  2. Under Metadata, click Edit.
  1. Modify the project-wide keys.
  • {region_name}_dns-domain-name: mydomain.com - represents the connection-specific DNS suffix in Windows clients.
  • {region_name}_dns-servers: {comma separated list of IPs} - represents the list of DNS servers.
  • {region_name}_dns-domain-suffixes: mydomain.com, myseconddomain.com - represents the list of DNS suffixes to add to Windows and Linux machines.

The system also supports the following key:values for a default configuration to machines without explicit region configuration:

  • default_dns-domain-name: mydomain.com
  • default_dns-servers: {comma separated list of IPs}
  • default_dns-domain-suffixes: mydomain.com, myseconddomain.com

 Note: A region setting takes priority over a default setting.

  1. When you are done, click Save at the bottom of the page.

The settings are applied as followed:

For Windows clients, the key:values are applied to all NICs as follows:

  • dns-domain-name: Replaces the “DNS suffix for this connection” setting per NIC.
  • dns-servers: Replaces the list of DNS servers per NIC.
  • dns-domain-suffixes: Replaces the list of DNS suffixes per NIC.

For Linux clients, the key:values are applied to all NICs as follows:

  • dns-servers: Prepends the list of DNS servers in the resolv.conf file.
  • dns-domain-suffixes: Prepends the list of DNS suffixes in the resolv.conf file.