Managed OpenStack
Latest
Frequently Asked Questions
Solution
How To
Internal Only
Templates
Powered By

Title
Message
Create new category
What is the title of your new category?
Edit page index title
What is the title of the page index?
Edit category
What is the new title of your category?
Edit link
What is the new title and URL of your link?
Replace a Designate Node
Copy Markdown
Open in ChatGPT
Open in Claude
Problem
- One or more hosts authorized with the Designate role need to be decommissioned, shutdown, or otherwise replaced.
- If this has already occurred, one or more zones and their respective recordsets may be showing in either PENDING or ERROR state, depending on how long it's been.
Environment
- Platform9 Managed OpenStack - All Versions
- Designate
Procedure
- Identify the IP address of your BIND server, and also of the Designate host(s) which are to remain or otherwise replace the old hosts.
- Create a file update-masters.awk on the BIND server and populate it with the following content, modifying the bolded variables as per the legend below.
xxxxxxxxxxBEGIN {SERVER_IP = "<BIND_IP>"KEY = ""MASTERS = "<DESIGNATE_NODE_1_IP> port 5354; <DESIGNATE_NODE_2_IP> port 5354;"RNDC_ADD_CMD = "rndc -s %s addzone %s '%s'\n"RNDC_DEL_CMD = "rndc -s %s delzone %s\n"} /^zone/ {# Remove quotes from zone namegsub("\"", "", $2)zone_name = $2 # Iterate over remaining fields. Concatenate into 'zone_data'.zone_data = ""for(i=3; i<=NF; i++){zone_data=zone_data" "$i}sub("^ ", "", zone_data) # Find configured DNS serversmatch(zone_data, /( ?([0-9]+.){4}( port [0-9]+);){1,}/, master_servers)sub("^ ", "", master_servers[0]) # If configured masters do not match desired mastersif (master_servers[0] != MASTERS){sub(master_servers[0], MASTERS, zone_data) # Print command to delete zonesprintf RNDC_DEL_CMD, SERVER_IP, zone_name # Print command to add zonesprintf RNDC_ADD_CMD, SERVER_IP, zone_name, zone_data}} END {}- SERVER_IP = IP on which the BIND server is listening.
- MASTERS = IP(s) of the aforementioned Designate host(s) which will remain to be online and become the active masters.
- Execute the awk script and pipe the stdout to update_zones.sh.
xxxxxxxxxx# awk -f update-masters.awk /var/cache/bind/*.nzf ] update_zones.sh- Set the proper permissions and execute the resulting update_zones.sh script.
xxxxxxxxxx# chmod +x && ./update_zones.shNote: Afterward, it may take approximately 5-10 minutes for the DNS zones to update and reflect an ACTIVE status once again. If this does not occur, attempt to create a new DNS record or otherwise create an instance on a provider network or tenant network with a floating IP, either of which would automatically provision a DNS record (based on your Designate configuration). Once a new record is added, the zone and respective recordsets should show ACTIVE.
VariableType to search · ESC to discard
GlossaryType to search · ESC to discard
InsertType to search · ESC to discard
No matches
Last updated on
Was this page helpful?
Discard Changes
Do you want to discard your current changes and overwrite with the template?
Archive Synced Block
Message
Create new Template
What is this template's title?
Delete Template
Message