I've written a PowerShell script to create all the A/CNAME/MX records etc. for all my domain names.
It runs against my Azure subscription without an error.
I can go into the config section of my Azure Websites and map those domain names to my websites and it resolves the domains names correctly.
I've set the NamesServers at the registrar to the correct name servers that I'm getting back from
$zone = Get-AzureRmDnsZone –Name activistmanager.info –ResourceGroupName DNSRecords
Get-AzureRmDnsRecordSet –Name “@” –RecordType NS –Zone $zone
I can see that the domain names servers have the correct NameServers
But it doesn't work
Even using NSLOOKUP (after switching the server to the Azure DNS Servers)
I run
ls x.com
and it returns
Can't list the domain x.com:Non Existent domain
The DNS server refused to transfer the zone X.com to your computer
If This is incorrect, check the zone transfer security settings for X.com on the DNS
These zones we were resolving throughout the day as I was transferring them one by one to Azure but at some point they stopped working. What am I missing?
#---------------------------------------------------------------------------------------------
#freedomnstuff.org
#New-AzureRmDnsZone -Name freedomnstuff.org -ResourceGroupName DNSRecords
# A
$rs = New-AzureRmDnsRecordSet -Name "*" -RecordType A -ZoneName "freedomnstuff.org" -ResourceGroupName "DNSRecords" -Ttl 60 -Overwrite -Force
Add-AzureRmDnsRecordConfig -RecordSet $rs -Ipv4Address 168.62.48.183
Set-AzureRmDnsRecordSet -RecordSet $rs -Overwrite
# CNAME
$rs = New-AzureRmDnsRecordSet -Name "awverify" -RecordType "CNAME" -ZoneName "freedomnstuff.org" -ResourceGroupName "DNSRecords" -Ttl 60 -Overwrite -Force
Add-AzureRmDnsRecordConfig -RecordSet $rs -Cname "awverify.freedomnstuff.azurewebsites.net"
Set-AzureRmDnsRecordSet -RecordSet $rs -Overwrite
$rs = New-AzureRmDnsRecordSet -Name "awverify.www" -RecordType "CNAME" -ZoneName "freedomnstuff.org" -ResourceGroupName "DNSRecords" -Ttl 60 -Overwrite -Force
Add-AzureRmDnsRecordConfig -RecordSet $rs -Cname "awverify.freedomnstuff.azurewebsites.net"
Set-AzureRmDnsRecordSet -RecordSet $rs -Overwrite
$rs = New-AzureRmDnsRecordSet -Name "www" -RecordType "CNAME" -ZoneName "freedomnstuff.org" -ResourceGroupName "DNSRecords" -Ttl 60 -Overwrite -Force
Add-AzureRmDnsRecordConfig -RecordSet $rs -Cname "freedomnstuff.org"
Set-AzureRmDnsRecordSet -RecordSet $rs -Overwrite