google-cloud-platformdnsopenshiftgoogle-cloud-dns

Issue with Google Cloud Platform(GCP) DNS zones and openshift


I have followed the instructions at https://docs.openshift.com/container-platform/4.11/installing/installing_gcp/installing-gcp-account.html#installation-gcp-dns_installing-gcp-account for setting up an openshift trial. All steps I managed to get working excpet for DNS steps mentioned. I created a zone my-new-zone for my subdomain in GCP clusters.mysite.com and pointed DNS NS's to google (ns-cloud-d[1-4].googledomains.com) and I am able to interact with my openshift just fine. However, in so doing, all of my other DNS entries for mysite.com no longer function. I tried creating a second zone my-zone in GCP for mysite.com and added those preexisting entries there, but they came up with different GCP DNS NS servers (ns-cloud-a[1-4].googledomains.com).

How can I fix this so that I can access the openshift and also access my original sites?

Note: I can destroy and recreate the openshift cluster as needed at this point, but I need to know the correct steps for getting the DNS right.


Additional clarifications:

Note 1. I thought I had included above but apparently left out this detail: [mysite].com DNS entries were maintained at Dotster.com. When I got to step 6 in the linked instructions, I had to call Dotster.com because I could not understand how to proceed. I was told I could not use separate NS servers for the subdomain and they asked if I wanted to point the NS servers for my domain to the GCP servers indicated. I agreed and they repointed the NS servers. At that point I tried to add my DNS entries to GCP to restore access to my primary sites, and am not understanding how to do so. GCP will not allow me to change the zone name from clusters.[mysite].com to [mysite].com. It looked like all I needed to do was add another zone for [mysite].com, so I did so, not expecting the second zone would use totally different nameservers.

PROBLEM: DNS does not work for primary domain after setting up OpenShift on GCP. My website is down, my email is down, all of my sites are down.

Objective/Goal: Restore DNS service for primary domain entries AND have OpenShift working correctly.

Errors:

$ nslookup www.[mysite].com 8.8.8.8
Server:     8.8.8.8
Address:    8.8.8.8#53

** server can't find www.[mysite].com: SERVFAIL

As for why I created a subdomain, I already had my domain set up at dotster.com. I was following step 2 which says "2. Create a public hosted zone for your domain or subdomain in your GCP project. See Creating public zones in the GCP documentation. Use an appropriate root domain, such as openshiftcorp.com, or subdomain, such as clusters.openshiftcorp.com." And then I called dotster.com when I got to step 6 as I did not know how to proceed at that point. Please see note 1 above.


Solution

  • I suggest to create zone in your root domain, once created, add "A record" using your root domain then add "cname record" for subdomain. Once done, get the nameserver and place it in your domain registrar. Make sure to add other necessary record to the zone that you created in order for other service to work like email. Propagation will take at least 24 to 48 hours depends on DNS server.