0

I have a domain name’s DNS configured with cloudflare that sets the A record to my public IP address (I’ve set DDNS so I can SSH onto my raspberry pi if my dynamic IP ever changes). However, for some reason I cannot seem to ssh onto my pi using my domain name.

This way works (both with my public or private IP on port 4321):

ssh nick@2.127.***.*** -i ./.ssh/rpi_key -p 4321

However, for some reason this doesn’t work:

ssh nick@mycustomdomain.co.uk -i ./.ssh/rpi_key -p 4321

Why does this happen, and how can I get SSH to work using my domain name rather than IP? Cloudflare clearly points the IP to 2.127.. so I assume this should be completely identical.

cloudflare dns records

Also, after browsing some other posts, they suggest running this command: dig +short "mycustomdomain.co.uk" @8.8.8.8, which returns the following:

104.21.**.***
172.67.***.**

I’d assume it should return the IP associated with that domain name (my public IP, 2.127..), but instead it returns different IPs and 2 of them. Am I incorrect here? I can only assume otherwise they return the NS IPs of Cloudflare.

What am I not getting here? Thanks for any help

2
  • 1
    looks like a DNS propagation issue - i.e. your Dynamic IP address isn't propagating throughout the DNS system in a timely manner May 20 at 2:02
  • But why is the dig command returning 2 different IPs? If it's a propagation issue then would I need to just wait a bit longer for the problem to fix itself? May 20 at 9:27
1

For anyone else having this it turns out that the problem was Cloudflare's DNS settings set to being proxied; changing to DNS only works

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.