Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1554
  • Last Modified:

Cannot ping by hostname

Hi

I am running Windows 2008 Server with AD DNS (2008 as well).

I have a machine, machine1.domain.com which was working fine. I could ping via IP and hostname.

Suddenly, I can't ping by hostname, only IP.

Will running ipconfig/registerdns on my machine fix this, or is it an entry that needs to be done on the DNS server side?

Also, does Dynamic DNS updating fit into this (which we have enabled)?
0
smith1974
Asked:
smith1974
  • 6
  • 5
  • 5
  • +1
2 Solutions
 
CuteadderCommented:
try running this first...

ipconfig /flushdns

then ping again...
0
 
AlanConsultantCommented:
Can you ping by hostname from another machine (not the hostname machine itself)?

If so, then the issue is likely on your machine, if not, then the issue is likely with your DNS server, and we can diagnose methodically.

Thanks,

Alan.
0
 
Krzysztof PytkoActive Directory EngineerCommented:
Please run on that DC in command-line

dcdiag /test:dns >c:\dcdiag.txt

and post reults here (attach this file). Maybe somethin wrong with your DNS server?

On that "faulty" client try also:

arp -d *
ipconfig /flushdns
ipconfig /registerdns

and check ping once again.

Regards,
Krzysztof
0
Creating Active Directory Users from a Text File

If your organization has a need to mass-create AD user accounts, watch this video to see how its done without the need for scripting or other unnecessary complexities.

 
smith1974Author Commented:
Hi

To confirm, we couldn't ping machine1.domain.com from any other machine. I did run /flushdns and /registerdns on machine1 too as well as reload the DNS entry in AD.

So I'm not sure which of the two actions fixed it? :(

Basically, if multiiple machines could not ping machine1.domain.com (or machine1) by hostname, would running /registerdns on machine1 actually have resolved the issue? I would have thought this was related to the actual DNS system.

What does /registerdns actually do? Register a new record with the DNS server?
0
 
CuteadderCommented:
registerdns makes sure the dns server knows what ip address the local computer is on...
flushdns flushes the dns on the local computer and makes sure the local computer asks the server for the address...

but as long as its fixed...
0
 
AlanConsultantCommented:
I can't see how registerdns would have fixed it on anything other than that local machine, so the issue must have been in the DNS / AD Server.

Glad its all okay now.

Alan.
0
 
smith1974Author Commented:
Yep, it's fixed, but I'm interested to know what the fix was :)

Does /registerdns command on the local machine re-register the entry with the DNS server? If so, could this have fixed it in case the entry on the DNS server was corrupt/someone accidentally deleted it?

Or does /registerdns mean that the client (i.e. machine1) just pulls down the latest info from the DNS server for its local cache?

I've tried to read on the Internet what /registerdns actually does but there doesn't seem to be much info.

Thanks all!
0
 
CuteadderCommented:
if the computer you are trying to ping is on a dhcp ip address, the chance is that the computer you were pinging from cached the ip address of the other computer at the same time the computer you were pinging changed ip address...

which meant when you pinged the computer you were actually pinging the old ip address...

to the same extent, computers do time from time lose there register with the dns server....
0
 
smith1974Author Commented:
Thanks cuteadder, but when I was having the problem and trying to ping machine1.domain.com, it wasn't coming back with an invalid address - it was saying that there was no host named machine1.domain.com at all!
0
 
CuteadderCommented:
Then register fixed the problem...
0
 
smith1974Author Commented:
So does /registerdns command on the local machine re-register the entry with the DNS server? This would explain how other clients could suddenly ping it again by hostname?

0
 
CuteadderCommented:
yup...
0
 
AlanConsultantCommented:
Hi Smith1974,

My understanding is that /registerdns does the following two things:

1) Refreshes all the DHCP address leases on the machine - basically asks the DHCP server to renew its leases on the IP addresses it is using

2) Registers all related DNS names configured and used by the machine - bascially says I am using these names, so please record that they are mine (and, I would guess, warn if some other machine is using the same name - just guessing on that one, but it would be easy to test if you want to be sure).

HTH,

Alan.
0
 
AlanConsultantCommented:
Hi Smith1974,

Upon reflection, you are right - flushdns *could* have fixed that problem I think (assuming you ran flushdns on the machine that cuold not be pinged as opposed to the machine that could not get a response to its ping).

Doesn't mean it *was* the solutions - whatever you did on the server might have done it too of course.

Perhaps next time (if there is one) you see this issue, try doing just the flushdns, see if that works, and if not, do the server side things again and check.

HTH,

Alan.
0
 
smith1974Author Commented:
Hi Alan

Do you mean flusdns or registerdns? I thought flushdns just deletes the local DNS cache - nothing to do with the server...whereas registerdns means that machine1 re-registered itself with the DNS server.

Which also leads to the question - do we ever need to manually create DNS records in DNS in that case? Can we just run /registerdns from the client?
0
 
smith1974Author Commented:
...and how would that DNS record for machine1 have been lost in the first place? Is this not uncommon?
0
 
AlanConsultantCommented:
Hi Smith1974,

I did mean registerdns - typo on my part - sorry!

Creating records in DNS gives to central control, and stops the 'anarchy' of each local machine havnig whatever name the admin(s) on that machine might want to give it.  You can do it via /registerdns though, and if you are the sole admin, then it wouldn't be out of control of course!

I have no idea how your DNS server could have lost that particular record at that time.  Is it possible that someone 'flushed' out all the DNS records on there?  Are you the only admin?

Alan.
0

Featured Post

Evaluating UTMs? Here's what you need to know!

Evaluating a UTM appliance and vendor can prove to be an overwhelming exercise.  How can you make sure that you're getting the security that your organization needs without breaking the bank? Check out our UTM Buyer's Guide for more information on what you should be looking for!

  • 6
  • 5
  • 5
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now