Dynamic DNS (DDNS) fails to obtain public IP
-
@johnpoz Ok, so I deleted the /tmp/.cache files and /tmp/.lock files.
I then rebuilt the DDNS config, tried it, negative.
I exported a backup of the DDNS to XML and here is what I get:This XML file does not appear to have any style information associated with it. The document tree is shown below.
I presume the CDATA is encrypted because it doesn't match my token.Hope this makes some sense to someone.
Tas -
@70tas that username sure isn't right for using a api token.. You need to use your Zone ID you get from cloudflare.
That wouldn't even be right for a global token, which would be your email address.
Go to your zone, ie 70tas.us dns settings - scroll down on the right and you should see your zone ID
-
@70tas To note it here as well, I used the script posted in the other thread only for debugging purposes. While you can use it with a cron job, it is not necessary. The DDNS GUI works fine for cloudflare. The important thing is to use the Zone ID for the user name, not the email address. In the past, the email address must have worked because that is what I had in there before. It worked for years but now no longer.
-
@revengineer we sure global doesn't work? My main pfsense running 24.11 is using global and it still works. Just double checked.
Clearly they are moving away from it - it is legacy. I have one, but not sure if they let you create one if you didn't already have one?
Global API key is the previous authorization scheme for interacting with the Cloudflare API. When possible, use API tokens instead of Global API key.
But you can view it if you have one. So he could try using that - but from what he posted, unless he edited for posting - what he has in username isn't valid for either a global key or api token.
-
@revengineer Unfortunately, there is something wrong in my configuration, which causes it not to be able to find my real IP. I'm not going to spend a lot of time on it, since I can use the script via Cron. I just need to modify it so it doesn't update needlesly.
Thanks for all the help
I appreciate it -
@70tas Doesn't matter if it did or we don't even know - maybe it can, but since you have the wrong settings it never going to work.
-
@johnpoz I think we are talking about two different things, and I may not have been clear. For the username, it states for cloudflare: "Enter email for Global API Key or (optionally) Zone ID for API token." I could not get this to accept my email address, and I had to use the Zone ID. If the email address works for you, then I wonder whether my problem is that I changed my cloudflare email address to a different one than I used when I opened the account and established the global api key.
In any case it sounds like @70tas has other issues but has found a solution.
-
@revengineer said in Dynamic DNS (DDNS) fails to obtain public IP:
and I had to use the Zone ID
what was posted from his xml is not a zone id. So how do we know what problem he is actually having - because what he posted is never going to work be it using global key or a api token.
-
@johnpoz I'm sorry John, how do you assume I have the wrong settings. If I had the wrong settings, then the script wouldn't work either, yes?
-
@johnpoz Exactly. You have hit the proverbial nail on the head. I just can't figure out where it is coming from. It doesn't make much sense does it. But like you said earlier, I don't need to spend more time on it. I've modified the script, or rather Google Gemini provided the script for me. ;)
Hey thanks for all of the help sir. I really appreciate it. If there is any way I can help in future, please let me know.
Tas -
@70tas said in Dynamic DNS (DDNS) fails to obtain public IP:
how do you assume I have the wrong settings.
Don't have to assume anything - your xml you posted has the wrong username.. you have your domain name in there - its not your email or you zone id for that domain.. So with how pfsense updates it no it would never work.
-
@johnpoz Ok, well thank you anyway John
Tas