0

I have a website (cimahouse.co). Every time I wanted to reach my site, I got a different IP address. Sometimes domain cimahouse.co opens normally, and sometimes it should write it with www.

I tried to PING it with cmd, and I got two different results. The first time I got this reply.

Pinging cimahouse.co [188.114.97.7] with 32 bytes of data:
Request timed out.

The second time I got this:

Pinging www.cimahouse.co [188.114.96.12] with 32 bytes of data:
Reply from 188.114.96.12: bytes=32 time=49ms TTL=56

Why do I see two different IP addresses? How can I make all requests come from the working IP address? (188.114.96.12)

Note: that I'm using Cloudflare

My DNS servers from Cloudflare are:

rayden.ns.cloudflare.com
172.64.35.163

shubhi.ns.cloudflare.com
108.162.194.63
4
  • 4
    Why is the IP important? What problem are you attempting to solve?
    – vidarlo
    Dec 7, 2022 at 10:47
  • 1
    I’m voting to close this question because it doesn’t meet the level of technical expertise required, suggest migration to SuperUser or webmasters?
    – Josh
    Dec 7, 2022 at 22:38
  • 1
    ping is not the right tool to perform DNS lookups. Use nslookup, host etc. That said, what is the problem you are facing and why you are pinging it at all? Dec 8, 2022 at 16:05
  • @Josh: Yes, concurred. It should never have been answered here. "Server Fault is a question and answer site for managing information technology systems in a business environment". But I can't vote. Dec 8, 2022 at 19:04

2 Answers 2

10

You are getting different IP addresses because you are using Cloudflare. The whole point of Cloudflare is directing traffic through different nodes to distribute and cache traffic.

Pinging the Cloudflare hosts is not going to tell you anything about the state of your actual server, you need to ping it directly if you want to check if it is online.

Of course, getting an ICMP response will tell you absolutely nothing about the state of your httpd service. To do a real check you should use other tools, like curl, wget, and traceroute.

1
  • i know that , but why if i use www i get different ip i try this for another site ( mycimaaa.click ) and all types of ping gives me same ip
    – Ahmed Atef
    Dec 7, 2022 at 10:37
2
  1. Are you troubleshooting any particular issue with the website?

    This should define your methodology and the tools used in the first place. If you want to check if the content is served from the IP address, you may try to use something like this:

     curl https://cimahouse.co -i  --resolve cimahouse.co:443:188.114.96.12 -L
    

    If your version of curl does not support the resolution to a particular IP address, you can also spoof it by editing the hosts file.

  2. Your testing needs to be consistent. Depending on how your hostnames are configured on Cloudflare, requesting different hostnames may yield different results.

    Namely, requesting www.cimahouse.co redirects to cimahouse.co. They may be part of the same Cloudflare configuration, but the behaviour is slightly different, so they should not be used interchangeably.

  3. The other hostname, mycimaaa.click, also resolves to two IP addresses:

    ;; ANSWER SECTION:
    mycimaaa.click. 300 IN A 172.67.161.115
    mycimaaa.click. 300 IN A 104.21.82.184
    

    It's just the ping tool that for some reason picks up only one of them which is not wrong in any way.

  4. As pointed out by Gerald Schneider, the whole idea of using Cloudflare (or any other CDN) is using multiple edge servers in different locations (closest to the end user).

    The IP addresses served will be changing depending on the health of the edge servers and your location (or actually your public IP which may change if you are using VPN, proxy, changing network to mobile etc). It will definitely be changing in time. So, unless you really know what you are looking for, comparing the IP addresses, particularly those succeeding and failing with ICMP, may not give you any meaningful insights.

Not the answer you're looking for? Browse other questions tagged .