-
-
Notifications
You must be signed in to change notification settings - Fork 632
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TTL for NS-records is "stuck" #74
Comments
|
Culprit seems to be related to |
This sets the same TTL to all records in the RRset. Probably not what we want. |
I've patched it, and it seems to work so far. However, there needs to be more logic in https://doc.powerdns.com/md/httpapi/api_spec/#url-apiv1serversserver95idzoneszone95id E.g. if we have one NS-record with TTL 3600 and another NS-record with TTL 86400, they should be put into two RRset's. NS-records are probably not the best example (usually you want them to have the same TTL), but this applies for A- and AAAA-records as well. |
How is the API supposed to handle different TTL's? According to https://doc.powerdns.com/md/httpapi/api_spec/#url-apiv1serversserver95idzoneszone95id;
So, since changetype is REPLACE, all records with same name/type are deleted, and then re-created. Since TTL now is set per RRset, this means records not matching the TTL, would be deleted. For good. |
TIL; TTL's for same name and type has to be the same. Having two NS-records with different TTL is not supposed to happen, so having one of them deleted I guess is "fair". Should add more error-handling of this, though (e.g. trying to "Apply" when two records of same name and type has different TTL --> give warning). |
Okay, after a bit of testing, PR #95 should do the trick. It fixes so that it doesn't use the same TTL for the entire RRset (only the same name and type), which fixes the "stuck" issue I had. It also address the issue when you try setting different TTL-values for the same name+type. If you have the following two entries;
...and you try changing one of them to |
#76 is no longer relevant imho, and I closed it. |
@ngoduykhanh -- food for you (-: |
@jallakim : I tried but it didn't work. I have a comment at your PR :) |
@ngoduykhanh - Ah, yes, my bad. Tested with the wrong branch. Should work now (-: |
Fixed in PR #95. |
Hi,
Trying to change the NS-records for my domains. They are defaulted to 3600 (1 hour). Trying to change these to 86400 (24 hours). I set the value (for all the NS-records), hit "Save", then "Apply". Update successful. Refresh domain/page, old values are displayed (and is also what resides in the DB).
PowerDNS 4.0.0rc2 + PostgreSQL DB backend.
The text was updated successfully, but these errors were encountered: