Why is 'ping' unable to resolve a name when 'nslookup' works fine?DNS resolution Issue nslookup works, but...
What does 'script /dev/null' do?
What happens when a metallic dragon and a chromatic dragon mate?
Need help identifying/translating a plaque in Tangier, Morocco
Can I find out the caloric content of bread by dehydrating it?
How to manage monthly salary
A poker game description that does not feel gimmicky
Could a US political party gain complete control over the government by removing checks & balances?
Can a planet have a different gravitational pull depending on its location in orbit around its sun?
Why was the "bread communication" in the arena of Catching Fire left out in the movie?
Typesetting a double Over Dot on top of a symbol
What is the offset in a seaplane's hull?
If a centaur druid Wild Shapes into a Giant Elk, do their Charge features stack?
How did the USSR manage to innovate in an environment characterized by government censorship and high bureaucracy?
Patience, young "Padovan"
LWC and complex parameters
Why did the Germans forbid the possession of pet pigeons in Rostov-on-Don in 1941?
What causes the sudden spool-up sound from an F-16 when enabling afterburner?
Unbreakable Formation vs. Cry of the Carnarium
I’m planning on buying a laser printer but concerned about the life cycle of toner in the machine
Are white and non-white police officers equally likely to kill black suspects?
Information to fellow intern about hiring?
Is there a familial term for apples and pears?
Lied on resume at previous job
What do the Banks children have against barley water?
Why is 'ping' unable to resolve a name when 'nslookup' works fine?
DNS resolution Issue nslookup works, but web/ping doesn'tDNS issue on windowsWindows 7 DNS not working (nslookup IS working; ping -4 name.com NOT working)Windows 10 DNS issuesWindows Xp DNS Resolution not workingWhy cannot I ping computer name without dot?Cannot resolve websites intermittently (mostly .gov)nslookup on XP resolves to address, but ping can't find hostWhy do I need to add a period after hostname in order to get DNS resolution to work?Windows 8/10 DNS issues browser - ping - nslookupMacBook can't use internet, but nslookup and ping both workDNS resolution Issue nslookup works, but web/ping doesn'tnslookup returns the right IP, ping still goes to the wrong ipPing fails to find host but NSLookup resolves okay on WindowsCannot connect to my win 7 machinewhat does it mean if nslookup and ping fail to resolve a host name but tracert does not?NetBIOS Name resolution fails when behind another routerNslookup works but ping failsWhy do I need to add a period after hostname in order to get DNS resolution to work?When i ping mydomain.com i reply from www.domain.com
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}
On my Windows XP workstation, I can find the machine I want to connect to in DNS with nslookup
:
nslookup wolfman
Server: dns.company.com
Address: 192.168.1.38
Name: wolfman.company.com
Address: 192.168.1.178
But, when I try to connect to that machine, I get an error telling me that the machine can't be found (i.e., can't be looked up in DNS):
C:> ping wolfman
Ping request could not find host wolfman. Please check the name and try again.
I am able to connect if I use the IP address directly:
C:> ping 192.168.1.178
Pinging 192.168.1.178 with 32 bytes of data:
Reply from 192.168.1.178: bytes=32 time=41ms TTL=126
Reply from 192.168.1.178: bytes=32 time=41ms TTL=126
Reply from 192.168.1.178: bytes=32 time=44ms TTL=126
Reply from 192.168.1.178: bytes=32 time=38ms TTL=126
I could work around this by adding an entry to my hosts
file, but I would rather find out why this is happening. The problem is transient, most of the day I can connect to the machine just fine.
How is this possible?
ETA: I left this out for brevity, but it was asked for:
C:> ping wolfman.company.com
Ping request could not find host wolfman.company.com. Please check the name and try again.
ETA: Other applications get the same results. I only tried ping to simplify. telnet can't connect, Cygwin apps print a "unknown host wolfman" message.
Update: Using wireshark, I found that my workstation is not attempting a DNS lookup. It's just reporting the "could not find host" error message.
windows networking dns
|
show 10 more comments
On my Windows XP workstation, I can find the machine I want to connect to in DNS with nslookup
:
nslookup wolfman
Server: dns.company.com
Address: 192.168.1.38
Name: wolfman.company.com
Address: 192.168.1.178
But, when I try to connect to that machine, I get an error telling me that the machine can't be found (i.e., can't be looked up in DNS):
C:> ping wolfman
Ping request could not find host wolfman. Please check the name and try again.
I am able to connect if I use the IP address directly:
C:> ping 192.168.1.178
Pinging 192.168.1.178 with 32 bytes of data:
Reply from 192.168.1.178: bytes=32 time=41ms TTL=126
Reply from 192.168.1.178: bytes=32 time=41ms TTL=126
Reply from 192.168.1.178: bytes=32 time=44ms TTL=126
Reply from 192.168.1.178: bytes=32 time=38ms TTL=126
I could work around this by adding an entry to my hosts
file, but I would rather find out why this is happening. The problem is transient, most of the day I can connect to the machine just fine.
How is this possible?
ETA: I left this out for brevity, but it was asked for:
C:> ping wolfman.company.com
Ping request could not find host wolfman.company.com. Please check the name and try again.
ETA: Other applications get the same results. I only tried ping to simplify. telnet can't connect, Cygwin apps print a "unknown host wolfman" message.
Update: Using wireshark, I found that my workstation is not attempting a DNS lookup. It's just reporting the "could not find host" error message.
windows networking dns
You could add a default DNS suffix for.company.com
.
– billc.cn
Oct 29 '12 at 20:25
@billc.cn I already have that DNS suffix.
– skiphoppy
Oct 30 '12 at 16:35
What I think's happening is that ping isn't looking up the FQDN of the host, unlikenslookup
which uses thesearch domain
parameter of a DHCP offer (or whatever you specify for a static IP configuration). Confirm this by doing what @SLaks has said and pinging the FQDN of the host :)
– jackweirdy
Nov 19 '12 at 17:57
1
Possible duplicate of: superuser.com/questions/220471/…
– Der Hochstapler
Nov 19 '12 at 17:57
What happens when you runping -4 wolfman
?
– Der Hochstapler
Nov 19 '12 at 18:00
|
show 10 more comments
On my Windows XP workstation, I can find the machine I want to connect to in DNS with nslookup
:
nslookup wolfman
Server: dns.company.com
Address: 192.168.1.38
Name: wolfman.company.com
Address: 192.168.1.178
But, when I try to connect to that machine, I get an error telling me that the machine can't be found (i.e., can't be looked up in DNS):
C:> ping wolfman
Ping request could not find host wolfman. Please check the name and try again.
I am able to connect if I use the IP address directly:
C:> ping 192.168.1.178
Pinging 192.168.1.178 with 32 bytes of data:
Reply from 192.168.1.178: bytes=32 time=41ms TTL=126
Reply from 192.168.1.178: bytes=32 time=41ms TTL=126
Reply from 192.168.1.178: bytes=32 time=44ms TTL=126
Reply from 192.168.1.178: bytes=32 time=38ms TTL=126
I could work around this by adding an entry to my hosts
file, but I would rather find out why this is happening. The problem is transient, most of the day I can connect to the machine just fine.
How is this possible?
ETA: I left this out for brevity, but it was asked for:
C:> ping wolfman.company.com
Ping request could not find host wolfman.company.com. Please check the name and try again.
ETA: Other applications get the same results. I only tried ping to simplify. telnet can't connect, Cygwin apps print a "unknown host wolfman" message.
Update: Using wireshark, I found that my workstation is not attempting a DNS lookup. It's just reporting the "could not find host" error message.
windows networking dns
On my Windows XP workstation, I can find the machine I want to connect to in DNS with nslookup
:
nslookup wolfman
Server: dns.company.com
Address: 192.168.1.38
Name: wolfman.company.com
Address: 192.168.1.178
But, when I try to connect to that machine, I get an error telling me that the machine can't be found (i.e., can't be looked up in DNS):
C:> ping wolfman
Ping request could not find host wolfman. Please check the name and try again.
I am able to connect if I use the IP address directly:
C:> ping 192.168.1.178
Pinging 192.168.1.178 with 32 bytes of data:
Reply from 192.168.1.178: bytes=32 time=41ms TTL=126
Reply from 192.168.1.178: bytes=32 time=41ms TTL=126
Reply from 192.168.1.178: bytes=32 time=44ms TTL=126
Reply from 192.168.1.178: bytes=32 time=38ms TTL=126
I could work around this by adding an entry to my hosts
file, but I would rather find out why this is happening. The problem is transient, most of the day I can connect to the machine just fine.
How is this possible?
ETA: I left this out for brevity, but it was asked for:
C:> ping wolfman.company.com
Ping request could not find host wolfman.company.com. Please check the name and try again.
ETA: Other applications get the same results. I only tried ping to simplify. telnet can't connect, Cygwin apps print a "unknown host wolfman" message.
Update: Using wireshark, I found that my workstation is not attempting a DNS lookup. It's just reporting the "could not find host" error message.
windows networking dns
windows networking dns
edited Nov 19 '12 at 19:22
skiphoppy
asked Oct 29 '12 at 19:11
skiphoppyskiphoppy
97841121
97841121
You could add a default DNS suffix for.company.com
.
– billc.cn
Oct 29 '12 at 20:25
@billc.cn I already have that DNS suffix.
– skiphoppy
Oct 30 '12 at 16:35
What I think's happening is that ping isn't looking up the FQDN of the host, unlikenslookup
which uses thesearch domain
parameter of a DHCP offer (or whatever you specify for a static IP configuration). Confirm this by doing what @SLaks has said and pinging the FQDN of the host :)
– jackweirdy
Nov 19 '12 at 17:57
1
Possible duplicate of: superuser.com/questions/220471/…
– Der Hochstapler
Nov 19 '12 at 17:57
What happens when you runping -4 wolfman
?
– Der Hochstapler
Nov 19 '12 at 18:00
|
show 10 more comments
You could add a default DNS suffix for.company.com
.
– billc.cn
Oct 29 '12 at 20:25
@billc.cn I already have that DNS suffix.
– skiphoppy
Oct 30 '12 at 16:35
What I think's happening is that ping isn't looking up the FQDN of the host, unlikenslookup
which uses thesearch domain
parameter of a DHCP offer (or whatever you specify for a static IP configuration). Confirm this by doing what @SLaks has said and pinging the FQDN of the host :)
– jackweirdy
Nov 19 '12 at 17:57
1
Possible duplicate of: superuser.com/questions/220471/…
– Der Hochstapler
Nov 19 '12 at 17:57
What happens when you runping -4 wolfman
?
– Der Hochstapler
Nov 19 '12 at 18:00
You could add a default DNS suffix for
.company.com
.– billc.cn
Oct 29 '12 at 20:25
You could add a default DNS suffix for
.company.com
.– billc.cn
Oct 29 '12 at 20:25
@billc.cn I already have that DNS suffix.
– skiphoppy
Oct 30 '12 at 16:35
@billc.cn I already have that DNS suffix.
– skiphoppy
Oct 30 '12 at 16:35
What I think's happening is that ping isn't looking up the FQDN of the host, unlike
nslookup
which uses the search domain
parameter of a DHCP offer (or whatever you specify for a static IP configuration). Confirm this by doing what @SLaks has said and pinging the FQDN of the host :)– jackweirdy
Nov 19 '12 at 17:57
What I think's happening is that ping isn't looking up the FQDN of the host, unlike
nslookup
which uses the search domain
parameter of a DHCP offer (or whatever you specify for a static IP configuration). Confirm this by doing what @SLaks has said and pinging the FQDN of the host :)– jackweirdy
Nov 19 '12 at 17:57
1
1
Possible duplicate of: superuser.com/questions/220471/…
– Der Hochstapler
Nov 19 '12 at 17:57
Possible duplicate of: superuser.com/questions/220471/…
– Der Hochstapler
Nov 19 '12 at 17:57
What happens when you run
ping -4 wolfman
?– Der Hochstapler
Nov 19 '12 at 18:00
What happens when you run
ping -4 wolfman
?– Der Hochstapler
Nov 19 '12 at 18:00
|
show 10 more comments
21 Answers
21
active
oldest
votes
I believe that nslookup opens a winsock connection on the DNS port and issues a query, whereas ping uses the DNS Client service. You could try and stop this service and see whether this makes a difference.
Some commands that will reinitialize various network states :
Reset WINSOCK entries to installation defaults : netsh winsock reset catalog
Reset TCP/IP stack to installation defaults : netsh int ip reset reset.log
Flush DNS resolver cache : ipconfig /flushdns
Renew DNS client registration and refresh DHCP leases : ipconfig /registerdns
Flush routing table : route /f
(reboot required)
1
I would bet Active Directory is probably active, but I do not know how to test.
– skiphoppy
Nov 20 '12 at 14:51
11
I disabled the DNS Client service, and the problem appeared to go away! Not sure yet if it was a fluke. The problem didn't come back when I restarted the service.
– skiphoppy
Nov 20 '12 at 14:55
5
Sometimes just stopping and restarting the service fixes DNS problems (don't ask me why). The question is how long this will last. Some unlucky people need to repeat it again and again.
– harrymc
Nov 20 '12 at 16:06
1
sfc /scannow in case the dns client service system files are corrupt subtly? I've also seen some people with similar problems caused by a virus.
– Jon Kloske
Nov 26 '12 at 5:27
1
What was missing for me in this answer wasipconfig /registerdns
(I've elaborated in my answer below)
– Mick Halsband
Jun 4 '15 at 8:28
|
show 6 more comments
Try ping with hostname followed by a dot. So instead of ping wolfman
use ping wolfman.
That should get you resolving without having to do workarounds with hosts file, etc.
wow, this worked for me as well. My guess is that something expects a domain name which is not configured
– user1190
Aug 10 '16 at 20:46
OK, this works ... why?
– Daniel B.
Sep 8 '16 at 2:00
1
any suggestions why this is working and how to rather use locally names without trailing dots?
– Ruberoid
Mar 6 '17 at 20:01
Thanks - this worked for me but would also know why this would be working
– Frank Fu
May 1 '17 at 0:09
2
@Ruberoid Please see my answer for how to do this automatically.
– Frederik Aalund
Oct 9 '17 at 11:54
add a comment |
Try ipconfig /displaydns
and look for wolfman. If it's cached as "name does not exist" (possibly because of a previous intermittent failed lookup), you can flush the cache with ipconfig /flushdns
.
nslookup
doesn't use the cache, but rather queries the DNS server directly.
I tried: it's not cached. And clearing the cache doesn't fix the issue, either.
– skiphoppy
Nov 20 '12 at 14:46
Can you post the output ofnslookup -all
? Isnovc
listed?
– craig65535
Nov 20 '12 at 18:22
add a comment |
Try adding .
to the DNS suffixes for that connection. I.e, go to:
- Ethernet Status
- Click Properties
- Internet Protocol Version 4
- Click Properties
- Click Advanced
- Append these DNS suffices (in order)
- Add
.
as a suffix.
The same steps are illustrated in the following screenshot:
This should make ping wolfman
work.
Explanation
nslookup wolfman
(name server lookup: wolfman) sends the hostname (wolfman
) to the DNS (domain name system) to obtain the corresponding IP address. This is the sole purpose of the nslookup
command. This works already, so we have verified that the DNS works and that wolfman
indeed corresponds to an IP address.
In contrast, ping wolfman
needs to do two things:
- Get the IP that the hostname (
wolfman
) corresponds to. - Send packets to the IP and listen for the response
On Windows (even recent versions such as Windows 10), the first step can easily fail. For the sake of backwards compatibility, Windows supports various methods of hostname resolution (hosts file, DNS, NetBIOS/WINS, LMHOST file).
Unfortunately, it seems that Windows' ping
command doesn't always attempt a DNS lookup. I don't know the specific conditions that triggers this behaviour.
Fortunately, we can force Windows to do a DNS lookup by using a FQDN (fully qualified domain name). In practice, we do this by suffixing a .
dot to the hostname: wolfman.
. Try ping wolfman.
and verify that it works.
The final step is to force Windows to append this dot itself. I've already shown how to do this in the beginning of this answer.
Just want to say that this turned out to be the factor that succeeded on a machine I was working on. Stupid though it seems. And not just for ping, but for other applications too. I'm not sure your explanation of what's tried when is quite right (but you acknowledge you're uncertain on that). But a big plus for mentioning that this failure can be easily diagnosed by attempting ping with the domain name with a dot suffix manually added.
– gwideman
Jun 28 '18 at 9:55
This doesn't make sense. You're positing that, "Windows' ping command doesn't always attempt a DNS lookup," but then recommend changing how DNS lookups are performed to solve that? It seems more likely that ping is performing a DNS lookup(s) but is doing them incorrectly, and that's why this fix works.
– Twisty Impersonator
Jan 14 at 13:57
@TwistyImpersonator I understand your confusion. The point is that Windows will attempt several methods of hostname resolution if givenwolfman
and a DNS lookup is (apparently) not a top priority among said methods. Now, if you usewolfman.
instead, Windows will prioritize a DNS lookup over the other methods becausewolfman.
is a FQDN that (obviously) requires a DNS lookup.
– Frederik Aalund
Jan 14 at 14:24
So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work. However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer. That explanation doesn't fit the fact of ping not being able to find the host though.
– Twisty Impersonator
Jan 14 at 16:58
@TwistyImpersonator "So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work": Yes. "However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer": Apparently not. Maybe ping just gives up after trying a couple of methods. Maybe ping gives up after a timeout. Maybe ping never tries a DNS lookup because it thinks the hostname is not DNS-like.
– Frederik Aalund
Jan 14 at 19:41
|
show 1 more comment
nslookup
works different to other commands when resolving names/ip addresses on Windows.
The normal resolution method on Windows is as follows:
- The client checks to see if the name queried is its own.
- The client then searches a local Hosts file, a list of IP address and names stored on the local computer.
- Domain Name System (DNS) servers are queried.
- If the name is still not resolved, NetBIOS name resolution sequence is used as a backup. This order can be changed by configuring the NetBIOS node type of the client.
nslookup
on the other hand is used for testing Domain Name Servers.
3
Are there any settings that can move the NetBIOS query higher up in that list? I have the gut feeling that the NetBIOS lookup is involved somehow, but since the DNS query is definitely working I can't see how it would ever get to that step, if the sequence above is immutable.
– skiphoppy
Nov 20 '12 at 14:49
add a comment |
I've struggled with a similar issue and have tried the solution suggested by @harrymc.
I found what eventually seems to (at least somewhat) work at the microsoft technet forum
(nslookup works but nothing else has DNS on standalone Win7 PC)
Here's the quote:
... try to use the command below to flush and reset a client resolver cache for test.
ipconfig /flushdns
ipconfig /registerdns
Please refer to the link below for more details.
http://jefferyland.wordpress.com/2011/07/28/quick-review-of-flushdns-registerdns-and-dns-queries/
So basically what was missing for me was ipconfig /registerdns
1
original answer by @harrymc now reflects the missing/registerdns
command
– Mick Halsband
Jun 29 '15 at 10:35
I've been playing whack-a-mole with this issue on Win10 for about a year. When my laptop wakes up it can't find any corp servers, but external sites like microsoft.com do work. It seems to happen when changing WiFi networks (home/VPN vs office). flushdns solves the issue sometimes but not always. Today I tried the registerdns and that immediately corrected the problem. Tomorrow I'll try adding . to the end of a name (but ping already fails with FQDN for internal servers). It's very frustrating. And to top it off - if I wait a while the problem will resolve itself.
– ripvlan
Aug 14 '18 at 13:51
add a comment |
Just today we had the same issue, but the solution was different. So I thought, I'd add it for reference as this was the top most search result.
Problem:ping
will not resolve a host name, butnslookup
can. (Observed on 2 different Windows Server 2012 R2 hosts.)
Cause: (For each host) The host has more than one NIC connected and there are multiple default gateways configured.
Solution: (For each host) Remove default gateway from configuration of all NICs but one, so there reamains only one default gateway.
ah this did it for me. Perfect.
– IAmTheSquidward
Jan 26 '16 at 0:39
Short and simple
– Frank Fu
Mar 12 '18 at 11:37
add a comment |
Maybe wolfman.company.com is listed in C:Windowssystem32driversetchosts ?
nslookup bypasses that file and always asks DNS, while ping and other tools first of all look up in "hosts" file, then in DNS.
Good thought! But I checked, and neither of the machines I've seen this issue with are listed in hosts.
– skiphoppy
Nov 20 '12 at 14:47
add a comment |
I had the same problem on a Windows 2012R2 (=8.1) system, and tried all the above suggestions, but none of them would fix it:
- Pinging the fully qualified name worked.
- Pinging the unqualified name did not.
- Both worked on several other systems, that had the same OS and apparently the same configuration.
- All the necessary suffix search strings were there.
(Note that some of the proposed fixes, like the workaround for the multi-label queries, are obviously irrelevant, as the unqualified name has only one part.)
Then I noticed that the target system I was trying to ping did NOT have an IPv6 address. So I tried "ping -4 unqualified_name", and bingo! this worked.
So for some reason, on this system only, ping only tried to resolve unqualified name->IPv6 address, and not unqualified name->IPv4.
For me the fix was to disable IPv6 completely as I don't need it at all. But I'd be really interested to find a more gentle way to tell ping (or presumably the DNS client service) to try resolving both IPv4 and IPv6 addresses.
add a comment |
Adding an entry in the file c:/windows/system32/drivers/etc/hosts
might fix it.
That will fix it, but it will not resolve his issue on that machine, but it will not help him on other machines. Remember Hosts > DNS Resolver > DNS Server > NetBIOS name.
– The Dude
May 29 '15 at 15:10
add a comment |
I was trying to figure out why on one win 7 computer I can use ping server
which works, and the other it can't resolve server
. However both could ping server.lan
which I didn't quite understand.
Turns out I had messed with some settings (DNS suffixes) to not have to use FQDNs while using the work VPN. I had to go add my local .lan
to those suffixes in order to get both computers acting the same.
Go to Control Panel > Network and Internet > Network Connections and right click on your network connection and hit Properties. Click Internet Protocol Version 4 and hit the Properties button. Then the Advanced... button in this new window. Go to the DNS tab, this is where I had added a DNS suffix for my work but also needed one for my normal home connections.
I ran into a similar situation on a server with a static IP address. The first entry in the "Append these DNS suffixes" was blank AND the "DNS suffix for this connection" was blank. Other servers where it worked had the same blank "Append these DNS suffixes" BUT the "DNS suffix for this connection" populated.
– Tim Lewis
Apr 7 '16 at 17:29
add a comment |
I came across this issue as well. The "easiest" way to fix it for me was to simply add a .
to the end of the hostname. However this is rather annoying. Most networks don't require this. I'd rather not have to tell everyone else on the network to do this when they need to access the same resource.
I was looking at the suggestion from Frederik Aalund as a possible solution and noticed that they suggested switching from the default "Append primary and connection specific DNS suffixes" option. This made me think maybe my network was simply slightly missconfigured.
Looking at my DD-WRT settings, the "LAN Domain" was left unset. Setting that to an arbitrary string seems to have fixed this issue for all clients on my network without having special configuration on each machine, the solution I wanted! :)
add a comment |
i have encountered this when we migrated to windows 7 from windows XP, the issue was related to a Windows 7 Multi Label DNS Query issue.
Allow DNS Suffix Appending to Unqualified Multi-Label Name Queries - see:
http://computerstepbystep.com/allow_dns_suffix_appending_to_unqualified_multi_label_name_queries.html
Hope this helps
2
Welcome to Super User! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference.
– Canadian Luke
Mar 21 '14 at 17:40
add a comment |
If on mac os x it might be an DNS Cache problem:
Dump the cache
sudo killall -HUP mDNSResponder
sudo dscacheutil -flushcache
OP asks about Windows XP and question is tagged Windows.
– P-L
Oct 20 '17 at 15:38
Maybe it is helpful to others. I will leave it, the answer was here now for more than 3 years. Why delete now?
– Christian
Oct 24 '17 at 11:12
add a comment |
I'm picking this up because it bothered me the last year and maybe I found a workaround.
For me it seemed some dns-caching-system within the windows client is faulty. Windows 7 and 8.1 are affected by this... cannot say much about Windows XP anymore. ping doesn't resolve the name. it's not the icmp-part which is important but the name resolving part). nslookup is designed to query the nameserver and does exactly that and no windows name-hierarchy-resolving.
Restarting the dnscache service helped everytime. But since I disabled IPv6 on all client-interfaces the problem didn't occured anymore.
Cheers!
Disabling IPv6 may not be a viable solution for everybody (and it sounds anecdotal at best, anyway). Everything else you say seems to have been said already in this thread (e.g., harrymc’s comment “Sometimes just stopping and restarting the service fixes DNS problems”, two years ago).
– G-Man
Nov 3 '14 at 15:31
add a comment |
I might be wrong on this because its based on my long-forgotten NT4 ressource-kit days.
As fare I can recall PING uses Netbios/WINS and DNS (in that order, at least if you don't specify a FQDN).
WINS is gone many year ago but you might still have Netbios enabled on your interface and PING therefore might use netbios that might not give you any result. Especially if traffic is passing a router somewhere.
Just disable Netbios and Ping will use DNS as first priority and append the registered DNS Surffic on the interface to your hostname.
add a comment |
I have just had this problem, and found something quite peculiar, and managed to fix it Lol
Basically, if you have any entries in your hosts file, that are the same as the IP your ping is trying to resolve to, it will fail.
For example, if in your DNS, you have a record for www.example.com - 10.0.0.20, but then you have an entry in your client's hosts file, 10.0.0.20 somethingelse.com, you will not be able to ping www.example.com
Strange huh
add a comment |
In my case what solved this problem was to add the domain of the host I was trying to ping to a group policy option named "DNS Suffix Search List".
The procedure in short is this: Open gpedit.msc
and navigate to Computer Configuration -> Administrative Templates -> Network -> DNS Client > DNS Suffix Search List
, set it to "Enabled" and add the domain name to the list (the list is empty by default).
A more detailed description of these steps can be found here
add a comment |
I had the same problem and turns out another machine had the same IP address, and that was causing it.
Changed IP back to DHCP and everything was working fine.
nslookup worked because it doesn't need to communicate with the other host. ping does need to communicate and obviously breaks.
– ndemou
Feb 13 at 17:02
@ndemou: That explanation doesn't make any sense. Yes, it is ping's job to try to communicate with the other host, but the first step in that process is to get the other host's IP address. If it gets the other host's IP address, it tells you so; if it then cannot communicate with the other host, it ultimately reports "100% loss". But, in the question, ping is failing even to get an address. (Tryping bbbbbbb.com
andping bbbbbb.com
for comparison.)
– Scott
Feb 13 at 17:57
You are right @Scott. I was editing Klaus' answer and while reading his description of the problem I forgot that this questions particular problem with ping is that it doesn't resolve. Can't be sure but I would bet now that Klaus was just not getting replies.
– ndemou
Feb 14 at 7:37
add a comment |
None of the solutions here worked for me. What did work for me was reconnecting to my work's vpn using OpenVPN. Then after disconnecting everything continued to work.
I believe the issue was related to the power going out while my computer was connected with openVPN. The only way I figured this out was by using WireShark. I noticed that the destination IPs for all the queries were going to IPs on my work's internal network.
New contributor
add a comment |
ping uses the ICMP protocol, specifically the 'Echo Request' and 'Echo Reply'.
many networks disable ICMP utilities in order to prevent attacks or basic network scanning. I've found many routers you purchase come with a setting to disable ping and like utilities enabled by default.
you can find more about ICMP here:
http://en.wikipedia.org/wiki/Internet_Control_Message_Protocol
8
Yes, but before using ICMP, the domain has to be resolved to an IP address as usual. So this is not the issue here.
– Michael
Nov 23 '12 at 2:25
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: false,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f495759%2fwhy-is-ping-unable-to-resolve-a-name-when-nslookup-works-fine%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
StackExchange.ready(function () {
$("#show-editor-button input, #show-editor-button button").click(function () {
var showEditor = function() {
$("#show-editor-button").hide();
$("#post-form").removeClass("dno");
StackExchange.editor.finallyInit();
};
var useFancy = $(this).data('confirm-use-fancy');
if(useFancy == 'True') {
var popupTitle = $(this).data('confirm-fancy-title');
var popupBody = $(this).data('confirm-fancy-body');
var popupAccept = $(this).data('confirm-fancy-accept-button');
$(this).loadPopup({
url: '/post/self-answer-popup',
loaded: function(popup) {
var pTitle = $(popup).find('h2');
var pBody = $(popup).find('.popup-body');
var pSubmit = $(popup).find('.popup-submit');
pTitle.text(popupTitle);
pBody.html(popupBody);
pSubmit.val(popupAccept).click(showEditor);
}
})
} else{
var confirmText = $(this).data('confirm-text');
if (confirmText ? confirm(confirmText) : true) {
showEditor();
}
}
});
});
21 Answers
21
active
oldest
votes
21 Answers
21
active
oldest
votes
active
oldest
votes
active
oldest
votes
I believe that nslookup opens a winsock connection on the DNS port and issues a query, whereas ping uses the DNS Client service. You could try and stop this service and see whether this makes a difference.
Some commands that will reinitialize various network states :
Reset WINSOCK entries to installation defaults : netsh winsock reset catalog
Reset TCP/IP stack to installation defaults : netsh int ip reset reset.log
Flush DNS resolver cache : ipconfig /flushdns
Renew DNS client registration and refresh DHCP leases : ipconfig /registerdns
Flush routing table : route /f
(reboot required)
1
I would bet Active Directory is probably active, but I do not know how to test.
– skiphoppy
Nov 20 '12 at 14:51
11
I disabled the DNS Client service, and the problem appeared to go away! Not sure yet if it was a fluke. The problem didn't come back when I restarted the service.
– skiphoppy
Nov 20 '12 at 14:55
5
Sometimes just stopping and restarting the service fixes DNS problems (don't ask me why). The question is how long this will last. Some unlucky people need to repeat it again and again.
– harrymc
Nov 20 '12 at 16:06
1
sfc /scannow in case the dns client service system files are corrupt subtly? I've also seen some people with similar problems caused by a virus.
– Jon Kloske
Nov 26 '12 at 5:27
1
What was missing for me in this answer wasipconfig /registerdns
(I've elaborated in my answer below)
– Mick Halsband
Jun 4 '15 at 8:28
|
show 6 more comments
I believe that nslookup opens a winsock connection on the DNS port and issues a query, whereas ping uses the DNS Client service. You could try and stop this service and see whether this makes a difference.
Some commands that will reinitialize various network states :
Reset WINSOCK entries to installation defaults : netsh winsock reset catalog
Reset TCP/IP stack to installation defaults : netsh int ip reset reset.log
Flush DNS resolver cache : ipconfig /flushdns
Renew DNS client registration and refresh DHCP leases : ipconfig /registerdns
Flush routing table : route /f
(reboot required)
1
I would bet Active Directory is probably active, but I do not know how to test.
– skiphoppy
Nov 20 '12 at 14:51
11
I disabled the DNS Client service, and the problem appeared to go away! Not sure yet if it was a fluke. The problem didn't come back when I restarted the service.
– skiphoppy
Nov 20 '12 at 14:55
5
Sometimes just stopping and restarting the service fixes DNS problems (don't ask me why). The question is how long this will last. Some unlucky people need to repeat it again and again.
– harrymc
Nov 20 '12 at 16:06
1
sfc /scannow in case the dns client service system files are corrupt subtly? I've also seen some people with similar problems caused by a virus.
– Jon Kloske
Nov 26 '12 at 5:27
1
What was missing for me in this answer wasipconfig /registerdns
(I've elaborated in my answer below)
– Mick Halsband
Jun 4 '15 at 8:28
|
show 6 more comments
I believe that nslookup opens a winsock connection on the DNS port and issues a query, whereas ping uses the DNS Client service. You could try and stop this service and see whether this makes a difference.
Some commands that will reinitialize various network states :
Reset WINSOCK entries to installation defaults : netsh winsock reset catalog
Reset TCP/IP stack to installation defaults : netsh int ip reset reset.log
Flush DNS resolver cache : ipconfig /flushdns
Renew DNS client registration and refresh DHCP leases : ipconfig /registerdns
Flush routing table : route /f
(reboot required)
I believe that nslookup opens a winsock connection on the DNS port and issues a query, whereas ping uses the DNS Client service. You could try and stop this service and see whether this makes a difference.
Some commands that will reinitialize various network states :
Reset WINSOCK entries to installation defaults : netsh winsock reset catalog
Reset TCP/IP stack to installation defaults : netsh int ip reset reset.log
Flush DNS resolver cache : ipconfig /flushdns
Renew DNS client registration and refresh DHCP leases : ipconfig /registerdns
Flush routing table : route /f
(reboot required)
edited Jun 4 '15 at 8:33
answered Nov 20 '12 at 8:40
harrymcharrymc
264k14273582
264k14273582
1
I would bet Active Directory is probably active, but I do not know how to test.
– skiphoppy
Nov 20 '12 at 14:51
11
I disabled the DNS Client service, and the problem appeared to go away! Not sure yet if it was a fluke. The problem didn't come back when I restarted the service.
– skiphoppy
Nov 20 '12 at 14:55
5
Sometimes just stopping and restarting the service fixes DNS problems (don't ask me why). The question is how long this will last. Some unlucky people need to repeat it again and again.
– harrymc
Nov 20 '12 at 16:06
1
sfc /scannow in case the dns client service system files are corrupt subtly? I've also seen some people with similar problems caused by a virus.
– Jon Kloske
Nov 26 '12 at 5:27
1
What was missing for me in this answer wasipconfig /registerdns
(I've elaborated in my answer below)
– Mick Halsband
Jun 4 '15 at 8:28
|
show 6 more comments
1
I would bet Active Directory is probably active, but I do not know how to test.
– skiphoppy
Nov 20 '12 at 14:51
11
I disabled the DNS Client service, and the problem appeared to go away! Not sure yet if it was a fluke. The problem didn't come back when I restarted the service.
– skiphoppy
Nov 20 '12 at 14:55
5
Sometimes just stopping and restarting the service fixes DNS problems (don't ask me why). The question is how long this will last. Some unlucky people need to repeat it again and again.
– harrymc
Nov 20 '12 at 16:06
1
sfc /scannow in case the dns client service system files are corrupt subtly? I've also seen some people with similar problems caused by a virus.
– Jon Kloske
Nov 26 '12 at 5:27
1
What was missing for me in this answer wasipconfig /registerdns
(I've elaborated in my answer below)
– Mick Halsband
Jun 4 '15 at 8:28
1
1
I would bet Active Directory is probably active, but I do not know how to test.
– skiphoppy
Nov 20 '12 at 14:51
I would bet Active Directory is probably active, but I do not know how to test.
– skiphoppy
Nov 20 '12 at 14:51
11
11
I disabled the DNS Client service, and the problem appeared to go away! Not sure yet if it was a fluke. The problem didn't come back when I restarted the service.
– skiphoppy
Nov 20 '12 at 14:55
I disabled the DNS Client service, and the problem appeared to go away! Not sure yet if it was a fluke. The problem didn't come back when I restarted the service.
– skiphoppy
Nov 20 '12 at 14:55
5
5
Sometimes just stopping and restarting the service fixes DNS problems (don't ask me why). The question is how long this will last. Some unlucky people need to repeat it again and again.
– harrymc
Nov 20 '12 at 16:06
Sometimes just stopping and restarting the service fixes DNS problems (don't ask me why). The question is how long this will last. Some unlucky people need to repeat it again and again.
– harrymc
Nov 20 '12 at 16:06
1
1
sfc /scannow in case the dns client service system files are corrupt subtly? I've also seen some people with similar problems caused by a virus.
– Jon Kloske
Nov 26 '12 at 5:27
sfc /scannow in case the dns client service system files are corrupt subtly? I've also seen some people with similar problems caused by a virus.
– Jon Kloske
Nov 26 '12 at 5:27
1
1
What was missing for me in this answer was
ipconfig /registerdns
(I've elaborated in my answer below)– Mick Halsband
Jun 4 '15 at 8:28
What was missing for me in this answer was
ipconfig /registerdns
(I've elaborated in my answer below)– Mick Halsband
Jun 4 '15 at 8:28
|
show 6 more comments
Try ping with hostname followed by a dot. So instead of ping wolfman
use ping wolfman.
That should get you resolving without having to do workarounds with hosts file, etc.
wow, this worked for me as well. My guess is that something expects a domain name which is not configured
– user1190
Aug 10 '16 at 20:46
OK, this works ... why?
– Daniel B.
Sep 8 '16 at 2:00
1
any suggestions why this is working and how to rather use locally names without trailing dots?
– Ruberoid
Mar 6 '17 at 20:01
Thanks - this worked for me but would also know why this would be working
– Frank Fu
May 1 '17 at 0:09
2
@Ruberoid Please see my answer for how to do this automatically.
– Frederik Aalund
Oct 9 '17 at 11:54
add a comment |
Try ping with hostname followed by a dot. So instead of ping wolfman
use ping wolfman.
That should get you resolving without having to do workarounds with hosts file, etc.
wow, this worked for me as well. My guess is that something expects a domain name which is not configured
– user1190
Aug 10 '16 at 20:46
OK, this works ... why?
– Daniel B.
Sep 8 '16 at 2:00
1
any suggestions why this is working and how to rather use locally names without trailing dots?
– Ruberoid
Mar 6 '17 at 20:01
Thanks - this worked for me but would also know why this would be working
– Frank Fu
May 1 '17 at 0:09
2
@Ruberoid Please see my answer for how to do this automatically.
– Frederik Aalund
Oct 9 '17 at 11:54
add a comment |
Try ping with hostname followed by a dot. So instead of ping wolfman
use ping wolfman.
That should get you resolving without having to do workarounds with hosts file, etc.
Try ping with hostname followed by a dot. So instead of ping wolfman
use ping wolfman.
That should get you resolving without having to do workarounds with hosts file, etc.
answered May 5 '14 at 1:08
SenthilSenthil
27132
27132
wow, this worked for me as well. My guess is that something expects a domain name which is not configured
– user1190
Aug 10 '16 at 20:46
OK, this works ... why?
– Daniel B.
Sep 8 '16 at 2:00
1
any suggestions why this is working and how to rather use locally names without trailing dots?
– Ruberoid
Mar 6 '17 at 20:01
Thanks - this worked for me but would also know why this would be working
– Frank Fu
May 1 '17 at 0:09
2
@Ruberoid Please see my answer for how to do this automatically.
– Frederik Aalund
Oct 9 '17 at 11:54
add a comment |
wow, this worked for me as well. My guess is that something expects a domain name which is not configured
– user1190
Aug 10 '16 at 20:46
OK, this works ... why?
– Daniel B.
Sep 8 '16 at 2:00
1
any suggestions why this is working and how to rather use locally names without trailing dots?
– Ruberoid
Mar 6 '17 at 20:01
Thanks - this worked for me but would also know why this would be working
– Frank Fu
May 1 '17 at 0:09
2
@Ruberoid Please see my answer for how to do this automatically.
– Frederik Aalund
Oct 9 '17 at 11:54
wow, this worked for me as well. My guess is that something expects a domain name which is not configured
– user1190
Aug 10 '16 at 20:46
wow, this worked for me as well. My guess is that something expects a domain name which is not configured
– user1190
Aug 10 '16 at 20:46
OK, this works ... why?
– Daniel B.
Sep 8 '16 at 2:00
OK, this works ... why?
– Daniel B.
Sep 8 '16 at 2:00
1
1
any suggestions why this is working and how to rather use locally names without trailing dots?
– Ruberoid
Mar 6 '17 at 20:01
any suggestions why this is working and how to rather use locally names without trailing dots?
– Ruberoid
Mar 6 '17 at 20:01
Thanks - this worked for me but would also know why this would be working
– Frank Fu
May 1 '17 at 0:09
Thanks - this worked for me but would also know why this would be working
– Frank Fu
May 1 '17 at 0:09
2
2
@Ruberoid Please see my answer for how to do this automatically.
– Frederik Aalund
Oct 9 '17 at 11:54
@Ruberoid Please see my answer for how to do this automatically.
– Frederik Aalund
Oct 9 '17 at 11:54
add a comment |
Try ipconfig /displaydns
and look for wolfman. If it's cached as "name does not exist" (possibly because of a previous intermittent failed lookup), you can flush the cache with ipconfig /flushdns
.
nslookup
doesn't use the cache, but rather queries the DNS server directly.
I tried: it's not cached. And clearing the cache doesn't fix the issue, either.
– skiphoppy
Nov 20 '12 at 14:46
Can you post the output ofnslookup -all
? Isnovc
listed?
– craig65535
Nov 20 '12 at 18:22
add a comment |
Try ipconfig /displaydns
and look for wolfman. If it's cached as "name does not exist" (possibly because of a previous intermittent failed lookup), you can flush the cache with ipconfig /flushdns
.
nslookup
doesn't use the cache, but rather queries the DNS server directly.
I tried: it's not cached. And clearing the cache doesn't fix the issue, either.
– skiphoppy
Nov 20 '12 at 14:46
Can you post the output ofnslookup -all
? Isnovc
listed?
– craig65535
Nov 20 '12 at 18:22
add a comment |
Try ipconfig /displaydns
and look for wolfman. If it's cached as "name does not exist" (possibly because of a previous intermittent failed lookup), you can flush the cache with ipconfig /flushdns
.
nslookup
doesn't use the cache, but rather queries the DNS server directly.
Try ipconfig /displaydns
and look for wolfman. If it's cached as "name does not exist" (possibly because of a previous intermittent failed lookup), you can flush the cache with ipconfig /flushdns
.
nslookup
doesn't use the cache, but rather queries the DNS server directly.
answered Nov 19 '12 at 21:57
craig65535craig65535
265128
265128
I tried: it's not cached. And clearing the cache doesn't fix the issue, either.
– skiphoppy
Nov 20 '12 at 14:46
Can you post the output ofnslookup -all
? Isnovc
listed?
– craig65535
Nov 20 '12 at 18:22
add a comment |
I tried: it's not cached. And clearing the cache doesn't fix the issue, either.
– skiphoppy
Nov 20 '12 at 14:46
Can you post the output ofnslookup -all
? Isnovc
listed?
– craig65535
Nov 20 '12 at 18:22
I tried: it's not cached. And clearing the cache doesn't fix the issue, either.
– skiphoppy
Nov 20 '12 at 14:46
I tried: it's not cached. And clearing the cache doesn't fix the issue, either.
– skiphoppy
Nov 20 '12 at 14:46
Can you post the output of
nslookup -all
? Is novc
listed?– craig65535
Nov 20 '12 at 18:22
Can you post the output of
nslookup -all
? Is novc
listed?– craig65535
Nov 20 '12 at 18:22
add a comment |
Try adding .
to the DNS suffixes for that connection. I.e, go to:
- Ethernet Status
- Click Properties
- Internet Protocol Version 4
- Click Properties
- Click Advanced
- Append these DNS suffices (in order)
- Add
.
as a suffix.
The same steps are illustrated in the following screenshot:
This should make ping wolfman
work.
Explanation
nslookup wolfman
(name server lookup: wolfman) sends the hostname (wolfman
) to the DNS (domain name system) to obtain the corresponding IP address. This is the sole purpose of the nslookup
command. This works already, so we have verified that the DNS works and that wolfman
indeed corresponds to an IP address.
In contrast, ping wolfman
needs to do two things:
- Get the IP that the hostname (
wolfman
) corresponds to. - Send packets to the IP and listen for the response
On Windows (even recent versions such as Windows 10), the first step can easily fail. For the sake of backwards compatibility, Windows supports various methods of hostname resolution (hosts file, DNS, NetBIOS/WINS, LMHOST file).
Unfortunately, it seems that Windows' ping
command doesn't always attempt a DNS lookup. I don't know the specific conditions that triggers this behaviour.
Fortunately, we can force Windows to do a DNS lookup by using a FQDN (fully qualified domain name). In practice, we do this by suffixing a .
dot to the hostname: wolfman.
. Try ping wolfman.
and verify that it works.
The final step is to force Windows to append this dot itself. I've already shown how to do this in the beginning of this answer.
Just want to say that this turned out to be the factor that succeeded on a machine I was working on. Stupid though it seems. And not just for ping, but for other applications too. I'm not sure your explanation of what's tried when is quite right (but you acknowledge you're uncertain on that). But a big plus for mentioning that this failure can be easily diagnosed by attempting ping with the domain name with a dot suffix manually added.
– gwideman
Jun 28 '18 at 9:55
This doesn't make sense. You're positing that, "Windows' ping command doesn't always attempt a DNS lookup," but then recommend changing how DNS lookups are performed to solve that? It seems more likely that ping is performing a DNS lookup(s) but is doing them incorrectly, and that's why this fix works.
– Twisty Impersonator
Jan 14 at 13:57
@TwistyImpersonator I understand your confusion. The point is that Windows will attempt several methods of hostname resolution if givenwolfman
and a DNS lookup is (apparently) not a top priority among said methods. Now, if you usewolfman.
instead, Windows will prioritize a DNS lookup over the other methods becausewolfman.
is a FQDN that (obviously) requires a DNS lookup.
– Frederik Aalund
Jan 14 at 14:24
So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work. However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer. That explanation doesn't fit the fact of ping not being able to find the host though.
– Twisty Impersonator
Jan 14 at 16:58
@TwistyImpersonator "So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work": Yes. "However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer": Apparently not. Maybe ping just gives up after trying a couple of methods. Maybe ping gives up after a timeout. Maybe ping never tries a DNS lookup because it thinks the hostname is not DNS-like.
– Frederik Aalund
Jan 14 at 19:41
|
show 1 more comment
Try adding .
to the DNS suffixes for that connection. I.e, go to:
- Ethernet Status
- Click Properties
- Internet Protocol Version 4
- Click Properties
- Click Advanced
- Append these DNS suffices (in order)
- Add
.
as a suffix.
The same steps are illustrated in the following screenshot:
This should make ping wolfman
work.
Explanation
nslookup wolfman
(name server lookup: wolfman) sends the hostname (wolfman
) to the DNS (domain name system) to obtain the corresponding IP address. This is the sole purpose of the nslookup
command. This works already, so we have verified that the DNS works and that wolfman
indeed corresponds to an IP address.
In contrast, ping wolfman
needs to do two things:
- Get the IP that the hostname (
wolfman
) corresponds to. - Send packets to the IP and listen for the response
On Windows (even recent versions such as Windows 10), the first step can easily fail. For the sake of backwards compatibility, Windows supports various methods of hostname resolution (hosts file, DNS, NetBIOS/WINS, LMHOST file).
Unfortunately, it seems that Windows' ping
command doesn't always attempt a DNS lookup. I don't know the specific conditions that triggers this behaviour.
Fortunately, we can force Windows to do a DNS lookup by using a FQDN (fully qualified domain name). In practice, we do this by suffixing a .
dot to the hostname: wolfman.
. Try ping wolfman.
and verify that it works.
The final step is to force Windows to append this dot itself. I've already shown how to do this in the beginning of this answer.
Just want to say that this turned out to be the factor that succeeded on a machine I was working on. Stupid though it seems. And not just for ping, but for other applications too. I'm not sure your explanation of what's tried when is quite right (but you acknowledge you're uncertain on that). But a big plus for mentioning that this failure can be easily diagnosed by attempting ping with the domain name with a dot suffix manually added.
– gwideman
Jun 28 '18 at 9:55
This doesn't make sense. You're positing that, "Windows' ping command doesn't always attempt a DNS lookup," but then recommend changing how DNS lookups are performed to solve that? It seems more likely that ping is performing a DNS lookup(s) but is doing them incorrectly, and that's why this fix works.
– Twisty Impersonator
Jan 14 at 13:57
@TwistyImpersonator I understand your confusion. The point is that Windows will attempt several methods of hostname resolution if givenwolfman
and a DNS lookup is (apparently) not a top priority among said methods. Now, if you usewolfman.
instead, Windows will prioritize a DNS lookup over the other methods becausewolfman.
is a FQDN that (obviously) requires a DNS lookup.
– Frederik Aalund
Jan 14 at 14:24
So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work. However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer. That explanation doesn't fit the fact of ping not being able to find the host though.
– Twisty Impersonator
Jan 14 at 16:58
@TwistyImpersonator "So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work": Yes. "However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer": Apparently not. Maybe ping just gives up after trying a couple of methods. Maybe ping gives up after a timeout. Maybe ping never tries a DNS lookup because it thinks the hostname is not DNS-like.
– Frederik Aalund
Jan 14 at 19:41
|
show 1 more comment
Try adding .
to the DNS suffixes for that connection. I.e, go to:
- Ethernet Status
- Click Properties
- Internet Protocol Version 4
- Click Properties
- Click Advanced
- Append these DNS suffices (in order)
- Add
.
as a suffix.
The same steps are illustrated in the following screenshot:
This should make ping wolfman
work.
Explanation
nslookup wolfman
(name server lookup: wolfman) sends the hostname (wolfman
) to the DNS (domain name system) to obtain the corresponding IP address. This is the sole purpose of the nslookup
command. This works already, so we have verified that the DNS works and that wolfman
indeed corresponds to an IP address.
In contrast, ping wolfman
needs to do two things:
- Get the IP that the hostname (
wolfman
) corresponds to. - Send packets to the IP and listen for the response
On Windows (even recent versions such as Windows 10), the first step can easily fail. For the sake of backwards compatibility, Windows supports various methods of hostname resolution (hosts file, DNS, NetBIOS/WINS, LMHOST file).
Unfortunately, it seems that Windows' ping
command doesn't always attempt a DNS lookup. I don't know the specific conditions that triggers this behaviour.
Fortunately, we can force Windows to do a DNS lookup by using a FQDN (fully qualified domain name). In practice, we do this by suffixing a .
dot to the hostname: wolfman.
. Try ping wolfman.
and verify that it works.
The final step is to force Windows to append this dot itself. I've already shown how to do this in the beginning of this answer.
Try adding .
to the DNS suffixes for that connection. I.e, go to:
- Ethernet Status
- Click Properties
- Internet Protocol Version 4
- Click Properties
- Click Advanced
- Append these DNS suffices (in order)
- Add
.
as a suffix.
The same steps are illustrated in the following screenshot:
This should make ping wolfman
work.
Explanation
nslookup wolfman
(name server lookup: wolfman) sends the hostname (wolfman
) to the DNS (domain name system) to obtain the corresponding IP address. This is the sole purpose of the nslookup
command. This works already, so we have verified that the DNS works and that wolfman
indeed corresponds to an IP address.
In contrast, ping wolfman
needs to do two things:
- Get the IP that the hostname (
wolfman
) corresponds to. - Send packets to the IP and listen for the response
On Windows (even recent versions such as Windows 10), the first step can easily fail. For the sake of backwards compatibility, Windows supports various methods of hostname resolution (hosts file, DNS, NetBIOS/WINS, LMHOST file).
Unfortunately, it seems that Windows' ping
command doesn't always attempt a DNS lookup. I don't know the specific conditions that triggers this behaviour.
Fortunately, we can force Windows to do a DNS lookup by using a FQDN (fully qualified domain name). In practice, we do this by suffixing a .
dot to the hostname: wolfman.
. Try ping wolfman.
and verify that it works.
The final step is to force Windows to append this dot itself. I've already shown how to do this in the beginning of this answer.
answered Oct 9 '17 at 11:51
Frederik AalundFrederik Aalund
22123
22123
Just want to say that this turned out to be the factor that succeeded on a machine I was working on. Stupid though it seems. And not just for ping, but for other applications too. I'm not sure your explanation of what's tried when is quite right (but you acknowledge you're uncertain on that). But a big plus for mentioning that this failure can be easily diagnosed by attempting ping with the domain name with a dot suffix manually added.
– gwideman
Jun 28 '18 at 9:55
This doesn't make sense. You're positing that, "Windows' ping command doesn't always attempt a DNS lookup," but then recommend changing how DNS lookups are performed to solve that? It seems more likely that ping is performing a DNS lookup(s) but is doing them incorrectly, and that's why this fix works.
– Twisty Impersonator
Jan 14 at 13:57
@TwistyImpersonator I understand your confusion. The point is that Windows will attempt several methods of hostname resolution if givenwolfman
and a DNS lookup is (apparently) not a top priority among said methods. Now, if you usewolfman.
instead, Windows will prioritize a DNS lookup over the other methods becausewolfman.
is a FQDN that (obviously) requires a DNS lookup.
– Frederik Aalund
Jan 14 at 14:24
So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work. However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer. That explanation doesn't fit the fact of ping not being able to find the host though.
– Twisty Impersonator
Jan 14 at 16:58
@TwistyImpersonator "So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work": Yes. "However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer": Apparently not. Maybe ping just gives up after trying a couple of methods. Maybe ping gives up after a timeout. Maybe ping never tries a DNS lookup because it thinks the hostname is not DNS-like.
– Frederik Aalund
Jan 14 at 19:41
|
show 1 more comment
Just want to say that this turned out to be the factor that succeeded on a machine I was working on. Stupid though it seems. And not just for ping, but for other applications too. I'm not sure your explanation of what's tried when is quite right (but you acknowledge you're uncertain on that). But a big plus for mentioning that this failure can be easily diagnosed by attempting ping with the domain name with a dot suffix manually added.
– gwideman
Jun 28 '18 at 9:55
This doesn't make sense. You're positing that, "Windows' ping command doesn't always attempt a DNS lookup," but then recommend changing how DNS lookups are performed to solve that? It seems more likely that ping is performing a DNS lookup(s) but is doing them incorrectly, and that's why this fix works.
– Twisty Impersonator
Jan 14 at 13:57
@TwistyImpersonator I understand your confusion. The point is that Windows will attempt several methods of hostname resolution if givenwolfman
and a DNS lookup is (apparently) not a top priority among said methods. Now, if you usewolfman.
instead, Windows will prioritize a DNS lookup over the other methods becausewolfman.
is a FQDN that (obviously) requires a DNS lookup.
– Frederik Aalund
Jan 14 at 14:24
So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work. However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer. That explanation doesn't fit the fact of ping not being able to find the host though.
– Twisty Impersonator
Jan 14 at 16:58
@TwistyImpersonator "So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work": Yes. "However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer": Apparently not. Maybe ping just gives up after trying a couple of methods. Maybe ping gives up after a timeout. Maybe ping never tries a DNS lookup because it thinks the hostname is not DNS-like.
– Frederik Aalund
Jan 14 at 19:41
Just want to say that this turned out to be the factor that succeeded on a machine I was working on. Stupid though it seems. And not just for ping, but for other applications too. I'm not sure your explanation of what's tried when is quite right (but you acknowledge you're uncertain on that). But a big plus for mentioning that this failure can be easily diagnosed by attempting ping with the domain name with a dot suffix manually added.
– gwideman
Jun 28 '18 at 9:55
Just want to say that this turned out to be the factor that succeeded on a machine I was working on. Stupid though it seems. And not just for ping, but for other applications too. I'm not sure your explanation of what's tried when is quite right (but you acknowledge you're uncertain on that). But a big plus for mentioning that this failure can be easily diagnosed by attempting ping with the domain name with a dot suffix manually added.
– gwideman
Jun 28 '18 at 9:55
This doesn't make sense. You're positing that, "Windows' ping command doesn't always attempt a DNS lookup," but then recommend changing how DNS lookups are performed to solve that? It seems more likely that ping is performing a DNS lookup(s) but is doing them incorrectly, and that's why this fix works.
– Twisty Impersonator
Jan 14 at 13:57
This doesn't make sense. You're positing that, "Windows' ping command doesn't always attempt a DNS lookup," but then recommend changing how DNS lookups are performed to solve that? It seems more likely that ping is performing a DNS lookup(s) but is doing them incorrectly, and that's why this fix works.
– Twisty Impersonator
Jan 14 at 13:57
@TwistyImpersonator I understand your confusion. The point is that Windows will attempt several methods of hostname resolution if given
wolfman
and a DNS lookup is (apparently) not a top priority among said methods. Now, if you use wolfman.
instead, Windows will prioritize a DNS lookup over the other methods because wolfman.
is a FQDN that (obviously) requires a DNS lookup.– Frederik Aalund
Jan 14 at 14:24
@TwistyImpersonator I understand your confusion. The point is that Windows will attempt several methods of hostname resolution if given
wolfman
and a DNS lookup is (apparently) not a top priority among said methods. Now, if you use wolfman.
instead, Windows will prioritize a DNS lookup over the other methods because wolfman.
is a FQDN that (obviously) requires a DNS lookup.– Frederik Aalund
Jan 14 at 14:24
So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work. However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer. That explanation doesn't fit the fact of ping not being able to find the host though.
– Twisty Impersonator
Jan 14 at 16:58
So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work. However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer. That explanation doesn't fit the fact of ping not being able to find the host though.
– Twisty Impersonator
Jan 14 at 16:58
@TwistyImpersonator "So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work": Yes. "However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer": Apparently not. Maybe ping just gives up after trying a couple of methods. Maybe ping gives up after a timeout. Maybe ping never tries a DNS lookup because it thinks the hostname is not DNS-like.
– Frederik Aalund
Jan 14 at 19:41
@TwistyImpersonator "So I think you're saying if ping got to the point of doing a DNS lookup in the course of its normal lookup workflow, it would work": Yes. "However, ping should end up trying DNS if the other lookup methods don't return an answer, implying the reason ping fails on its own is because another method it's trying before DNS is returning an answer": Apparently not. Maybe ping just gives up after trying a couple of methods. Maybe ping gives up after a timeout. Maybe ping never tries a DNS lookup because it thinks the hostname is not DNS-like.
– Frederik Aalund
Jan 14 at 19:41
|
show 1 more comment
nslookup
works different to other commands when resolving names/ip addresses on Windows.
The normal resolution method on Windows is as follows:
- The client checks to see if the name queried is its own.
- The client then searches a local Hosts file, a list of IP address and names stored on the local computer.
- Domain Name System (DNS) servers are queried.
- If the name is still not resolved, NetBIOS name resolution sequence is used as a backup. This order can be changed by configuring the NetBIOS node type of the client.
nslookup
on the other hand is used for testing Domain Name Servers.
3
Are there any settings that can move the NetBIOS query higher up in that list? I have the gut feeling that the NetBIOS lookup is involved somehow, but since the DNS query is definitely working I can't see how it would ever get to that step, if the sequence above is immutable.
– skiphoppy
Nov 20 '12 at 14:49
add a comment |
nslookup
works different to other commands when resolving names/ip addresses on Windows.
The normal resolution method on Windows is as follows:
- The client checks to see if the name queried is its own.
- The client then searches a local Hosts file, a list of IP address and names stored on the local computer.
- Domain Name System (DNS) servers are queried.
- If the name is still not resolved, NetBIOS name resolution sequence is used as a backup. This order can be changed by configuring the NetBIOS node type of the client.
nslookup
on the other hand is used for testing Domain Name Servers.
3
Are there any settings that can move the NetBIOS query higher up in that list? I have the gut feeling that the NetBIOS lookup is involved somehow, but since the DNS query is definitely working I can't see how it would ever get to that step, if the sequence above is immutable.
– skiphoppy
Nov 20 '12 at 14:49
add a comment |
nslookup
works different to other commands when resolving names/ip addresses on Windows.
The normal resolution method on Windows is as follows:
- The client checks to see if the name queried is its own.
- The client then searches a local Hosts file, a list of IP address and names stored on the local computer.
- Domain Name System (DNS) servers are queried.
- If the name is still not resolved, NetBIOS name resolution sequence is used as a backup. This order can be changed by configuring the NetBIOS node type of the client.
nslookup
on the other hand is used for testing Domain Name Servers.
nslookup
works different to other commands when resolving names/ip addresses on Windows.
The normal resolution method on Windows is as follows:
- The client checks to see if the name queried is its own.
- The client then searches a local Hosts file, a list of IP address and names stored on the local computer.
- Domain Name System (DNS) servers are queried.
- If the name is still not resolved, NetBIOS name resolution sequence is used as a backup. This order can be changed by configuring the NetBIOS node type of the client.
nslookup
on the other hand is used for testing Domain Name Servers.
answered Nov 19 '12 at 21:29
BryanBryan
1,33321635
1,33321635
3
Are there any settings that can move the NetBIOS query higher up in that list? I have the gut feeling that the NetBIOS lookup is involved somehow, but since the DNS query is definitely working I can't see how it would ever get to that step, if the sequence above is immutable.
– skiphoppy
Nov 20 '12 at 14:49
add a comment |
3
Are there any settings that can move the NetBIOS query higher up in that list? I have the gut feeling that the NetBIOS lookup is involved somehow, but since the DNS query is definitely working I can't see how it would ever get to that step, if the sequence above is immutable.
– skiphoppy
Nov 20 '12 at 14:49
3
3
Are there any settings that can move the NetBIOS query higher up in that list? I have the gut feeling that the NetBIOS lookup is involved somehow, but since the DNS query is definitely working I can't see how it would ever get to that step, if the sequence above is immutable.
– skiphoppy
Nov 20 '12 at 14:49
Are there any settings that can move the NetBIOS query higher up in that list? I have the gut feeling that the NetBIOS lookup is involved somehow, but since the DNS query is definitely working I can't see how it would ever get to that step, if the sequence above is immutable.
– skiphoppy
Nov 20 '12 at 14:49
add a comment |
I've struggled with a similar issue and have tried the solution suggested by @harrymc.
I found what eventually seems to (at least somewhat) work at the microsoft technet forum
(nslookup works but nothing else has DNS on standalone Win7 PC)
Here's the quote:
... try to use the command below to flush and reset a client resolver cache for test.
ipconfig /flushdns
ipconfig /registerdns
Please refer to the link below for more details.
http://jefferyland.wordpress.com/2011/07/28/quick-review-of-flushdns-registerdns-and-dns-queries/
So basically what was missing for me was ipconfig /registerdns
1
original answer by @harrymc now reflects the missing/registerdns
command
– Mick Halsband
Jun 29 '15 at 10:35
I've been playing whack-a-mole with this issue on Win10 for about a year. When my laptop wakes up it can't find any corp servers, but external sites like microsoft.com do work. It seems to happen when changing WiFi networks (home/VPN vs office). flushdns solves the issue sometimes but not always. Today I tried the registerdns and that immediately corrected the problem. Tomorrow I'll try adding . to the end of a name (but ping already fails with FQDN for internal servers). It's very frustrating. And to top it off - if I wait a while the problem will resolve itself.
– ripvlan
Aug 14 '18 at 13:51
add a comment |
I've struggled with a similar issue and have tried the solution suggested by @harrymc.
I found what eventually seems to (at least somewhat) work at the microsoft technet forum
(nslookup works but nothing else has DNS on standalone Win7 PC)
Here's the quote:
... try to use the command below to flush and reset a client resolver cache for test.
ipconfig /flushdns
ipconfig /registerdns
Please refer to the link below for more details.
http://jefferyland.wordpress.com/2011/07/28/quick-review-of-flushdns-registerdns-and-dns-queries/
So basically what was missing for me was ipconfig /registerdns
1
original answer by @harrymc now reflects the missing/registerdns
command
– Mick Halsband
Jun 29 '15 at 10:35
I've been playing whack-a-mole with this issue on Win10 for about a year. When my laptop wakes up it can't find any corp servers, but external sites like microsoft.com do work. It seems to happen when changing WiFi networks (home/VPN vs office). flushdns solves the issue sometimes but not always. Today I tried the registerdns and that immediately corrected the problem. Tomorrow I'll try adding . to the end of a name (but ping already fails with FQDN for internal servers). It's very frustrating. And to top it off - if I wait a while the problem will resolve itself.
– ripvlan
Aug 14 '18 at 13:51
add a comment |
I've struggled with a similar issue and have tried the solution suggested by @harrymc.
I found what eventually seems to (at least somewhat) work at the microsoft technet forum
(nslookup works but nothing else has DNS on standalone Win7 PC)
Here's the quote:
... try to use the command below to flush and reset a client resolver cache for test.
ipconfig /flushdns
ipconfig /registerdns
Please refer to the link below for more details.
http://jefferyland.wordpress.com/2011/07/28/quick-review-of-flushdns-registerdns-and-dns-queries/
So basically what was missing for me was ipconfig /registerdns
I've struggled with a similar issue and have tried the solution suggested by @harrymc.
I found what eventually seems to (at least somewhat) work at the microsoft technet forum
(nslookup works but nothing else has DNS on standalone Win7 PC)
Here's the quote:
... try to use the command below to flush and reset a client resolver cache for test.
ipconfig /flushdns
ipconfig /registerdns
Please refer to the link below for more details.
http://jefferyland.wordpress.com/2011/07/28/quick-review-of-flushdns-registerdns-and-dns-queries/
So basically what was missing for me was ipconfig /registerdns
answered Sep 22 '14 at 8:32
Mick HalsbandMick Halsband
41658
41658
1
original answer by @harrymc now reflects the missing/registerdns
command
– Mick Halsband
Jun 29 '15 at 10:35
I've been playing whack-a-mole with this issue on Win10 for about a year. When my laptop wakes up it can't find any corp servers, but external sites like microsoft.com do work. It seems to happen when changing WiFi networks (home/VPN vs office). flushdns solves the issue sometimes but not always. Today I tried the registerdns and that immediately corrected the problem. Tomorrow I'll try adding . to the end of a name (but ping already fails with FQDN for internal servers). It's very frustrating. And to top it off - if I wait a while the problem will resolve itself.
– ripvlan
Aug 14 '18 at 13:51
add a comment |
1
original answer by @harrymc now reflects the missing/registerdns
command
– Mick Halsband
Jun 29 '15 at 10:35
I've been playing whack-a-mole with this issue on Win10 for about a year. When my laptop wakes up it can't find any corp servers, but external sites like microsoft.com do work. It seems to happen when changing WiFi networks (home/VPN vs office). flushdns solves the issue sometimes but not always. Today I tried the registerdns and that immediately corrected the problem. Tomorrow I'll try adding . to the end of a name (but ping already fails with FQDN for internal servers). It's very frustrating. And to top it off - if I wait a while the problem will resolve itself.
– ripvlan
Aug 14 '18 at 13:51
1
1
original answer by @harrymc now reflects the missing
/registerdns
command– Mick Halsband
Jun 29 '15 at 10:35
original answer by @harrymc now reflects the missing
/registerdns
command– Mick Halsband
Jun 29 '15 at 10:35
I've been playing whack-a-mole with this issue on Win10 for about a year. When my laptop wakes up it can't find any corp servers, but external sites like microsoft.com do work. It seems to happen when changing WiFi networks (home/VPN vs office). flushdns solves the issue sometimes but not always. Today I tried the registerdns and that immediately corrected the problem. Tomorrow I'll try adding . to the end of a name (but ping already fails with FQDN for internal servers). It's very frustrating. And to top it off - if I wait a while the problem will resolve itself.
– ripvlan
Aug 14 '18 at 13:51
I've been playing whack-a-mole with this issue on Win10 for about a year. When my laptop wakes up it can't find any corp servers, but external sites like microsoft.com do work. It seems to happen when changing WiFi networks (home/VPN vs office). flushdns solves the issue sometimes but not always. Today I tried the registerdns and that immediately corrected the problem. Tomorrow I'll try adding . to the end of a name (but ping already fails with FQDN for internal servers). It's very frustrating. And to top it off - if I wait a while the problem will resolve itself.
– ripvlan
Aug 14 '18 at 13:51
add a comment |
Just today we had the same issue, but the solution was different. So I thought, I'd add it for reference as this was the top most search result.
Problem:ping
will not resolve a host name, butnslookup
can. (Observed on 2 different Windows Server 2012 R2 hosts.)
Cause: (For each host) The host has more than one NIC connected and there are multiple default gateways configured.
Solution: (For each host) Remove default gateway from configuration of all NICs but one, so there reamains only one default gateway.
ah this did it for me. Perfect.
– IAmTheSquidward
Jan 26 '16 at 0:39
Short and simple
– Frank Fu
Mar 12 '18 at 11:37
add a comment |
Just today we had the same issue, but the solution was different. So I thought, I'd add it for reference as this was the top most search result.
Problem:ping
will not resolve a host name, butnslookup
can. (Observed on 2 different Windows Server 2012 R2 hosts.)
Cause: (For each host) The host has more than one NIC connected and there are multiple default gateways configured.
Solution: (For each host) Remove default gateway from configuration of all NICs but one, so there reamains only one default gateway.
ah this did it for me. Perfect.
– IAmTheSquidward
Jan 26 '16 at 0:39
Short and simple
– Frank Fu
Mar 12 '18 at 11:37
add a comment |
Just today we had the same issue, but the solution was different. So I thought, I'd add it for reference as this was the top most search result.
Problem:ping
will not resolve a host name, butnslookup
can. (Observed on 2 different Windows Server 2012 R2 hosts.)
Cause: (For each host) The host has more than one NIC connected and there are multiple default gateways configured.
Solution: (For each host) Remove default gateway from configuration of all NICs but one, so there reamains only one default gateway.
Just today we had the same issue, but the solution was different. So I thought, I'd add it for reference as this was the top most search result.
Problem:ping
will not resolve a host name, butnslookup
can. (Observed on 2 different Windows Server 2012 R2 hosts.)
Cause: (For each host) The host has more than one NIC connected and there are multiple default gateways configured.
Solution: (For each host) Remove default gateway from configuration of all NICs but one, so there reamains only one default gateway.
answered Apr 28 '15 at 8:41
djlaukdjlauk
6112
6112
ah this did it for me. Perfect.
– IAmTheSquidward
Jan 26 '16 at 0:39
Short and simple
– Frank Fu
Mar 12 '18 at 11:37
add a comment |
ah this did it for me. Perfect.
– IAmTheSquidward
Jan 26 '16 at 0:39
Short and simple
– Frank Fu
Mar 12 '18 at 11:37
ah this did it for me. Perfect.
– IAmTheSquidward
Jan 26 '16 at 0:39
ah this did it for me. Perfect.
– IAmTheSquidward
Jan 26 '16 at 0:39
Short and simple
– Frank Fu
Mar 12 '18 at 11:37
Short and simple
– Frank Fu
Mar 12 '18 at 11:37
add a comment |
Maybe wolfman.company.com is listed in C:Windowssystem32driversetchosts ?
nslookup bypasses that file and always asks DNS, while ping and other tools first of all look up in "hosts" file, then in DNS.
Good thought! But I checked, and neither of the machines I've seen this issue with are listed in hosts.
– skiphoppy
Nov 20 '12 at 14:47
add a comment |
Maybe wolfman.company.com is listed in C:Windowssystem32driversetchosts ?
nslookup bypasses that file and always asks DNS, while ping and other tools first of all look up in "hosts" file, then in DNS.
Good thought! But I checked, and neither of the machines I've seen this issue with are listed in hosts.
– skiphoppy
Nov 20 '12 at 14:47
add a comment |
Maybe wolfman.company.com is listed in C:Windowssystem32driversetchosts ?
nslookup bypasses that file and always asks DNS, while ping and other tools first of all look up in "hosts" file, then in DNS.
Maybe wolfman.company.com is listed in C:Windowssystem32driversetchosts ?
nslookup bypasses that file and always asks DNS, while ping and other tools first of all look up in "hosts" file, then in DNS.
answered Nov 19 '12 at 20:04
Mikhail KupchikMikhail Kupchik
2,3011119
2,3011119
Good thought! But I checked, and neither of the machines I've seen this issue with are listed in hosts.
– skiphoppy
Nov 20 '12 at 14:47
add a comment |
Good thought! But I checked, and neither of the machines I've seen this issue with are listed in hosts.
– skiphoppy
Nov 20 '12 at 14:47
Good thought! But I checked, and neither of the machines I've seen this issue with are listed in hosts.
– skiphoppy
Nov 20 '12 at 14:47
Good thought! But I checked, and neither of the machines I've seen this issue with are listed in hosts.
– skiphoppy
Nov 20 '12 at 14:47
add a comment |
I had the same problem on a Windows 2012R2 (=8.1) system, and tried all the above suggestions, but none of them would fix it:
- Pinging the fully qualified name worked.
- Pinging the unqualified name did not.
- Both worked on several other systems, that had the same OS and apparently the same configuration.
- All the necessary suffix search strings were there.
(Note that some of the proposed fixes, like the workaround for the multi-label queries, are obviously irrelevant, as the unqualified name has only one part.)
Then I noticed that the target system I was trying to ping did NOT have an IPv6 address. So I tried "ping -4 unqualified_name", and bingo! this worked.
So for some reason, on this system only, ping only tried to resolve unqualified name->IPv6 address, and not unqualified name->IPv4.
For me the fix was to disable IPv6 completely as I don't need it at all. But I'd be really interested to find a more gentle way to tell ping (or presumably the DNS client service) to try resolving both IPv4 and IPv6 addresses.
add a comment |
I had the same problem on a Windows 2012R2 (=8.1) system, and tried all the above suggestions, but none of them would fix it:
- Pinging the fully qualified name worked.
- Pinging the unqualified name did not.
- Both worked on several other systems, that had the same OS and apparently the same configuration.
- All the necessary suffix search strings were there.
(Note that some of the proposed fixes, like the workaround for the multi-label queries, are obviously irrelevant, as the unqualified name has only one part.)
Then I noticed that the target system I was trying to ping did NOT have an IPv6 address. So I tried "ping -4 unqualified_name", and bingo! this worked.
So for some reason, on this system only, ping only tried to resolve unqualified name->IPv6 address, and not unqualified name->IPv4.
For me the fix was to disable IPv6 completely as I don't need it at all. But I'd be really interested to find a more gentle way to tell ping (or presumably the DNS client service) to try resolving both IPv4 and IPv6 addresses.
add a comment |
I had the same problem on a Windows 2012R2 (=8.1) system, and tried all the above suggestions, but none of them would fix it:
- Pinging the fully qualified name worked.
- Pinging the unqualified name did not.
- Both worked on several other systems, that had the same OS and apparently the same configuration.
- All the necessary suffix search strings were there.
(Note that some of the proposed fixes, like the workaround for the multi-label queries, are obviously irrelevant, as the unqualified name has only one part.)
Then I noticed that the target system I was trying to ping did NOT have an IPv6 address. So I tried "ping -4 unqualified_name", and bingo! this worked.
So for some reason, on this system only, ping only tried to resolve unqualified name->IPv6 address, and not unqualified name->IPv4.
For me the fix was to disable IPv6 completely as I don't need it at all. But I'd be really interested to find a more gentle way to tell ping (or presumably the DNS client service) to try resolving both IPv4 and IPv6 addresses.
I had the same problem on a Windows 2012R2 (=8.1) system, and tried all the above suggestions, but none of them would fix it:
- Pinging the fully qualified name worked.
- Pinging the unqualified name did not.
- Both worked on several other systems, that had the same OS and apparently the same configuration.
- All the necessary suffix search strings were there.
(Note that some of the proposed fixes, like the workaround for the multi-label queries, are obviously irrelevant, as the unqualified name has only one part.)
Then I noticed that the target system I was trying to ping did NOT have an IPv6 address. So I tried "ping -4 unqualified_name", and bingo! this worked.
So for some reason, on this system only, ping only tried to resolve unqualified name->IPv6 address, and not unqualified name->IPv4.
For me the fix was to disable IPv6 completely as I don't need it at all. But I'd be really interested to find a more gentle way to tell ping (or presumably the DNS client service) to try resolving both IPv4 and IPv6 addresses.
answered Apr 9 '15 at 16:18
Jean-François LarvoireJean-François Larvoire
5112
5112
add a comment |
add a comment |
Adding an entry in the file c:/windows/system32/drivers/etc/hosts
might fix it.
That will fix it, but it will not resolve his issue on that machine, but it will not help him on other machines. Remember Hosts > DNS Resolver > DNS Server > NetBIOS name.
– The Dude
May 29 '15 at 15:10
add a comment |
Adding an entry in the file c:/windows/system32/drivers/etc/hosts
might fix it.
That will fix it, but it will not resolve his issue on that machine, but it will not help him on other machines. Remember Hosts > DNS Resolver > DNS Server > NetBIOS name.
– The Dude
May 29 '15 at 15:10
add a comment |
Adding an entry in the file c:/windows/system32/drivers/etc/hosts
might fix it.
Adding an entry in the file c:/windows/system32/drivers/etc/hosts
might fix it.
edited Nov 23 '12 at 5:59
Synetech
57.5k29186321
57.5k29186321
answered Nov 23 '12 at 5:38
Manoj AgarwalManoj Agarwal
19013
19013
That will fix it, but it will not resolve his issue on that machine, but it will not help him on other machines. Remember Hosts > DNS Resolver > DNS Server > NetBIOS name.
– The Dude
May 29 '15 at 15:10
add a comment |
That will fix it, but it will not resolve his issue on that machine, but it will not help him on other machines. Remember Hosts > DNS Resolver > DNS Server > NetBIOS name.
– The Dude
May 29 '15 at 15:10
That will fix it, but it will not resolve his issue on that machine, but it will not help him on other machines. Remember Hosts > DNS Resolver > DNS Server > NetBIOS name.
– The Dude
May 29 '15 at 15:10
That will fix it, but it will not resolve his issue on that machine, but it will not help him on other machines. Remember Hosts > DNS Resolver > DNS Server > NetBIOS name.
– The Dude
May 29 '15 at 15:10
add a comment |
I was trying to figure out why on one win 7 computer I can use ping server
which works, and the other it can't resolve server
. However both could ping server.lan
which I didn't quite understand.
Turns out I had messed with some settings (DNS suffixes) to not have to use FQDNs while using the work VPN. I had to go add my local .lan
to those suffixes in order to get both computers acting the same.
Go to Control Panel > Network and Internet > Network Connections and right click on your network connection and hit Properties. Click Internet Protocol Version 4 and hit the Properties button. Then the Advanced... button in this new window. Go to the DNS tab, this is where I had added a DNS suffix for my work but also needed one for my normal home connections.
I ran into a similar situation on a server with a static IP address. The first entry in the "Append these DNS suffixes" was blank AND the "DNS suffix for this connection" was blank. Other servers where it worked had the same blank "Append these DNS suffixes" BUT the "DNS suffix for this connection" populated.
– Tim Lewis
Apr 7 '16 at 17:29
add a comment |
I was trying to figure out why on one win 7 computer I can use ping server
which works, and the other it can't resolve server
. However both could ping server.lan
which I didn't quite understand.
Turns out I had messed with some settings (DNS suffixes) to not have to use FQDNs while using the work VPN. I had to go add my local .lan
to those suffixes in order to get both computers acting the same.
Go to Control Panel > Network and Internet > Network Connections and right click on your network connection and hit Properties. Click Internet Protocol Version 4 and hit the Properties button. Then the Advanced... button in this new window. Go to the DNS tab, this is where I had added a DNS suffix for my work but also needed one for my normal home connections.
I ran into a similar situation on a server with a static IP address. The first entry in the "Append these DNS suffixes" was blank AND the "DNS suffix for this connection" was blank. Other servers where it worked had the same blank "Append these DNS suffixes" BUT the "DNS suffix for this connection" populated.
– Tim Lewis
Apr 7 '16 at 17:29
add a comment |
I was trying to figure out why on one win 7 computer I can use ping server
which works, and the other it can't resolve server
. However both could ping server.lan
which I didn't quite understand.
Turns out I had messed with some settings (DNS suffixes) to not have to use FQDNs while using the work VPN. I had to go add my local .lan
to those suffixes in order to get both computers acting the same.
Go to Control Panel > Network and Internet > Network Connections and right click on your network connection and hit Properties. Click Internet Protocol Version 4 and hit the Properties button. Then the Advanced... button in this new window. Go to the DNS tab, this is where I had added a DNS suffix for my work but also needed one for my normal home connections.
I was trying to figure out why on one win 7 computer I can use ping server
which works, and the other it can't resolve server
. However both could ping server.lan
which I didn't quite understand.
Turns out I had messed with some settings (DNS suffixes) to not have to use FQDNs while using the work VPN. I had to go add my local .lan
to those suffixes in order to get both computers acting the same.
Go to Control Panel > Network and Internet > Network Connections and right click on your network connection and hit Properties. Click Internet Protocol Version 4 and hit the Properties button. Then the Advanced... button in this new window. Go to the DNS tab, this is where I had added a DNS suffix for my work but also needed one for my normal home connections.
answered Jan 1 '15 at 16:01
eresonanceeresonance
19315
19315
I ran into a similar situation on a server with a static IP address. The first entry in the "Append these DNS suffixes" was blank AND the "DNS suffix for this connection" was blank. Other servers where it worked had the same blank "Append these DNS suffixes" BUT the "DNS suffix for this connection" populated.
– Tim Lewis
Apr 7 '16 at 17:29
add a comment |
I ran into a similar situation on a server with a static IP address. The first entry in the "Append these DNS suffixes" was blank AND the "DNS suffix for this connection" was blank. Other servers where it worked had the same blank "Append these DNS suffixes" BUT the "DNS suffix for this connection" populated.
– Tim Lewis
Apr 7 '16 at 17:29
I ran into a similar situation on a server with a static IP address. The first entry in the "Append these DNS suffixes" was blank AND the "DNS suffix for this connection" was blank. Other servers where it worked had the same blank "Append these DNS suffixes" BUT the "DNS suffix for this connection" populated.
– Tim Lewis
Apr 7 '16 at 17:29
I ran into a similar situation on a server with a static IP address. The first entry in the "Append these DNS suffixes" was blank AND the "DNS suffix for this connection" was blank. Other servers where it worked had the same blank "Append these DNS suffixes" BUT the "DNS suffix for this connection" populated.
– Tim Lewis
Apr 7 '16 at 17:29
add a comment |
I came across this issue as well. The "easiest" way to fix it for me was to simply add a .
to the end of the hostname. However this is rather annoying. Most networks don't require this. I'd rather not have to tell everyone else on the network to do this when they need to access the same resource.
I was looking at the suggestion from Frederik Aalund as a possible solution and noticed that they suggested switching from the default "Append primary and connection specific DNS suffixes" option. This made me think maybe my network was simply slightly missconfigured.
Looking at my DD-WRT settings, the "LAN Domain" was left unset. Setting that to an arbitrary string seems to have fixed this issue for all clients on my network without having special configuration on each machine, the solution I wanted! :)
add a comment |
I came across this issue as well. The "easiest" way to fix it for me was to simply add a .
to the end of the hostname. However this is rather annoying. Most networks don't require this. I'd rather not have to tell everyone else on the network to do this when they need to access the same resource.
I was looking at the suggestion from Frederik Aalund as a possible solution and noticed that they suggested switching from the default "Append primary and connection specific DNS suffixes" option. This made me think maybe my network was simply slightly missconfigured.
Looking at my DD-WRT settings, the "LAN Domain" was left unset. Setting that to an arbitrary string seems to have fixed this issue for all clients on my network without having special configuration on each machine, the solution I wanted! :)
add a comment |
I came across this issue as well. The "easiest" way to fix it for me was to simply add a .
to the end of the hostname. However this is rather annoying. Most networks don't require this. I'd rather not have to tell everyone else on the network to do this when they need to access the same resource.
I was looking at the suggestion from Frederik Aalund as a possible solution and noticed that they suggested switching from the default "Append primary and connection specific DNS suffixes" option. This made me think maybe my network was simply slightly missconfigured.
Looking at my DD-WRT settings, the "LAN Domain" was left unset. Setting that to an arbitrary string seems to have fixed this issue for all clients on my network without having special configuration on each machine, the solution I wanted! :)
I came across this issue as well. The "easiest" way to fix it for me was to simply add a .
to the end of the hostname. However this is rather annoying. Most networks don't require this. I'd rather not have to tell everyone else on the network to do this when they need to access the same resource.
I was looking at the suggestion from Frederik Aalund as a possible solution and noticed that they suggested switching from the default "Append primary and connection specific DNS suffixes" option. This made me think maybe my network was simply slightly missconfigured.
Looking at my DD-WRT settings, the "LAN Domain" was left unset. Setting that to an arbitrary string seems to have fixed this issue for all clients on my network without having special configuration on each machine, the solution I wanted! :)
answered Jun 12 '18 at 22:14
Cameron TacklindCameron Tacklind
1563
1563
add a comment |
add a comment |
i have encountered this when we migrated to windows 7 from windows XP, the issue was related to a Windows 7 Multi Label DNS Query issue.
Allow DNS Suffix Appending to Unqualified Multi-Label Name Queries - see:
http://computerstepbystep.com/allow_dns_suffix_appending_to_unqualified_multi_label_name_queries.html
Hope this helps
2
Welcome to Super User! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference.
– Canadian Luke
Mar 21 '14 at 17:40
add a comment |
i have encountered this when we migrated to windows 7 from windows XP, the issue was related to a Windows 7 Multi Label DNS Query issue.
Allow DNS Suffix Appending to Unqualified Multi-Label Name Queries - see:
http://computerstepbystep.com/allow_dns_suffix_appending_to_unqualified_multi_label_name_queries.html
Hope this helps
2
Welcome to Super User! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference.
– Canadian Luke
Mar 21 '14 at 17:40
add a comment |
i have encountered this when we migrated to windows 7 from windows XP, the issue was related to a Windows 7 Multi Label DNS Query issue.
Allow DNS Suffix Appending to Unqualified Multi-Label Name Queries - see:
http://computerstepbystep.com/allow_dns_suffix_appending_to_unqualified_multi_label_name_queries.html
Hope this helps
i have encountered this when we migrated to windows 7 from windows XP, the issue was related to a Windows 7 Multi Label DNS Query issue.
Allow DNS Suffix Appending to Unqualified Multi-Label Name Queries - see:
http://computerstepbystep.com/allow_dns_suffix_appending_to_unqualified_multi_label_name_queries.html
Hope this helps
edited Mar 21 '14 at 18:13
Dave M
12.8k92838
12.8k92838
answered Mar 21 '14 at 17:23
Sony NSSony NS
112
112
2
Welcome to Super User! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference.
– Canadian Luke
Mar 21 '14 at 17:40
add a comment |
2
Welcome to Super User! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference.
– Canadian Luke
Mar 21 '14 at 17:40
2
2
Welcome to Super User! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference.
– Canadian Luke
Mar 21 '14 at 17:40
Welcome to Super User! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference.
– Canadian Luke
Mar 21 '14 at 17:40
add a comment |
If on mac os x it might be an DNS Cache problem:
Dump the cache
sudo killall -HUP mDNSResponder
sudo dscacheutil -flushcache
OP asks about Windows XP and question is tagged Windows.
– P-L
Oct 20 '17 at 15:38
Maybe it is helpful to others. I will leave it, the answer was here now for more than 3 years. Why delete now?
– Christian
Oct 24 '17 at 11:12
add a comment |
If on mac os x it might be an DNS Cache problem:
Dump the cache
sudo killall -HUP mDNSResponder
sudo dscacheutil -flushcache
OP asks about Windows XP and question is tagged Windows.
– P-L
Oct 20 '17 at 15:38
Maybe it is helpful to others. I will leave it, the answer was here now for more than 3 years. Why delete now?
– Christian
Oct 24 '17 at 11:12
add a comment |
If on mac os x it might be an DNS Cache problem:
Dump the cache
sudo killall -HUP mDNSResponder
sudo dscacheutil -flushcache
If on mac os x it might be an DNS Cache problem:
Dump the cache
sudo killall -HUP mDNSResponder
sudo dscacheutil -flushcache
answered Aug 8 '14 at 7:53
ChristianChristian
16017
16017
OP asks about Windows XP and question is tagged Windows.
– P-L
Oct 20 '17 at 15:38
Maybe it is helpful to others. I will leave it, the answer was here now for more than 3 years. Why delete now?
– Christian
Oct 24 '17 at 11:12
add a comment |
OP asks about Windows XP and question is tagged Windows.
– P-L
Oct 20 '17 at 15:38
Maybe it is helpful to others. I will leave it, the answer was here now for more than 3 years. Why delete now?
– Christian
Oct 24 '17 at 11:12
OP asks about Windows XP and question is tagged Windows.
– P-L
Oct 20 '17 at 15:38
OP asks about Windows XP and question is tagged Windows.
– P-L
Oct 20 '17 at 15:38
Maybe it is helpful to others. I will leave it, the answer was here now for more than 3 years. Why delete now?
– Christian
Oct 24 '17 at 11:12
Maybe it is helpful to others. I will leave it, the answer was here now for more than 3 years. Why delete now?
– Christian
Oct 24 '17 at 11:12
add a comment |
I'm picking this up because it bothered me the last year and maybe I found a workaround.
For me it seemed some dns-caching-system within the windows client is faulty. Windows 7 and 8.1 are affected by this... cannot say much about Windows XP anymore. ping doesn't resolve the name. it's not the icmp-part which is important but the name resolving part). nslookup is designed to query the nameserver and does exactly that and no windows name-hierarchy-resolving.
Restarting the dnscache service helped everytime. But since I disabled IPv6 on all client-interfaces the problem didn't occured anymore.
Cheers!
Disabling IPv6 may not be a viable solution for everybody (and it sounds anecdotal at best, anyway). Everything else you say seems to have been said already in this thread (e.g., harrymc’s comment “Sometimes just stopping and restarting the service fixes DNS problems”, two years ago).
– G-Man
Nov 3 '14 at 15:31
add a comment |
I'm picking this up because it bothered me the last year and maybe I found a workaround.
For me it seemed some dns-caching-system within the windows client is faulty. Windows 7 and 8.1 are affected by this... cannot say much about Windows XP anymore. ping doesn't resolve the name. it's not the icmp-part which is important but the name resolving part). nslookup is designed to query the nameserver and does exactly that and no windows name-hierarchy-resolving.
Restarting the dnscache service helped everytime. But since I disabled IPv6 on all client-interfaces the problem didn't occured anymore.
Cheers!
Disabling IPv6 may not be a viable solution for everybody (and it sounds anecdotal at best, anyway). Everything else you say seems to have been said already in this thread (e.g., harrymc’s comment “Sometimes just stopping and restarting the service fixes DNS problems”, two years ago).
– G-Man
Nov 3 '14 at 15:31
add a comment |
I'm picking this up because it bothered me the last year and maybe I found a workaround.
For me it seemed some dns-caching-system within the windows client is faulty. Windows 7 and 8.1 are affected by this... cannot say much about Windows XP anymore. ping doesn't resolve the name. it's not the icmp-part which is important but the name resolving part). nslookup is designed to query the nameserver and does exactly that and no windows name-hierarchy-resolving.
Restarting the dnscache service helped everytime. But since I disabled IPv6 on all client-interfaces the problem didn't occured anymore.
Cheers!
I'm picking this up because it bothered me the last year and maybe I found a workaround.
For me it seemed some dns-caching-system within the windows client is faulty. Windows 7 and 8.1 are affected by this... cannot say much about Windows XP anymore. ping doesn't resolve the name. it's not the icmp-part which is important but the name resolving part). nslookup is designed to query the nameserver and does exactly that and no windows name-hierarchy-resolving.
Restarting the dnscache service helped everytime. But since I disabled IPv6 on all client-interfaces the problem didn't occured anymore.
Cheers!
answered Nov 3 '14 at 14:58
grimgrim
111
111
Disabling IPv6 may not be a viable solution for everybody (and it sounds anecdotal at best, anyway). Everything else you say seems to have been said already in this thread (e.g., harrymc’s comment “Sometimes just stopping and restarting the service fixes DNS problems”, two years ago).
– G-Man
Nov 3 '14 at 15:31
add a comment |
Disabling IPv6 may not be a viable solution for everybody (and it sounds anecdotal at best, anyway). Everything else you say seems to have been said already in this thread (e.g., harrymc’s comment “Sometimes just stopping and restarting the service fixes DNS problems”, two years ago).
– G-Man
Nov 3 '14 at 15:31
Disabling IPv6 may not be a viable solution for everybody (and it sounds anecdotal at best, anyway). Everything else you say seems to have been said already in this thread (e.g., harrymc’s comment “Sometimes just stopping and restarting the service fixes DNS problems”, two years ago).
– G-Man
Nov 3 '14 at 15:31
Disabling IPv6 may not be a viable solution for everybody (and it sounds anecdotal at best, anyway). Everything else you say seems to have been said already in this thread (e.g., harrymc’s comment “Sometimes just stopping and restarting the service fixes DNS problems”, two years ago).
– G-Man
Nov 3 '14 at 15:31
add a comment |
I might be wrong on this because its based on my long-forgotten NT4 ressource-kit days.
As fare I can recall PING uses Netbios/WINS and DNS (in that order, at least if you don't specify a FQDN).
WINS is gone many year ago but you might still have Netbios enabled on your interface and PING therefore might use netbios that might not give you any result. Especially if traffic is passing a router somewhere.
Just disable Netbios and Ping will use DNS as first priority and append the registered DNS Surffic on the interface to your hostname.
add a comment |
I might be wrong on this because its based on my long-forgotten NT4 ressource-kit days.
As fare I can recall PING uses Netbios/WINS and DNS (in that order, at least if you don't specify a FQDN).
WINS is gone many year ago but you might still have Netbios enabled on your interface and PING therefore might use netbios that might not give you any result. Especially if traffic is passing a router somewhere.
Just disable Netbios and Ping will use DNS as first priority and append the registered DNS Surffic on the interface to your hostname.
add a comment |
I might be wrong on this because its based on my long-forgotten NT4 ressource-kit days.
As fare I can recall PING uses Netbios/WINS and DNS (in that order, at least if you don't specify a FQDN).
WINS is gone many year ago but you might still have Netbios enabled on your interface and PING therefore might use netbios that might not give you any result. Especially if traffic is passing a router somewhere.
Just disable Netbios and Ping will use DNS as first priority and append the registered DNS Surffic on the interface to your hostname.
I might be wrong on this because its based on my long-forgotten NT4 ressource-kit days.
As fare I can recall PING uses Netbios/WINS and DNS (in that order, at least if you don't specify a FQDN).
WINS is gone many year ago but you might still have Netbios enabled on your interface and PING therefore might use netbios that might not give you any result. Especially if traffic is passing a router somewhere.
Just disable Netbios and Ping will use DNS as first priority and append the registered DNS Surffic on the interface to your hostname.
answered Jul 5 '18 at 20:41
MrCalvinMrCalvin
17015
17015
add a comment |
add a comment |
I have just had this problem, and found something quite peculiar, and managed to fix it Lol
Basically, if you have any entries in your hosts file, that are the same as the IP your ping is trying to resolve to, it will fail.
For example, if in your DNS, you have a record for www.example.com - 10.0.0.20, but then you have an entry in your client's hosts file, 10.0.0.20 somethingelse.com, you will not be able to ping www.example.com
Strange huh
add a comment |
I have just had this problem, and found something quite peculiar, and managed to fix it Lol
Basically, if you have any entries in your hosts file, that are the same as the IP your ping is trying to resolve to, it will fail.
For example, if in your DNS, you have a record for www.example.com - 10.0.0.20, but then you have an entry in your client's hosts file, 10.0.0.20 somethingelse.com, you will not be able to ping www.example.com
Strange huh
add a comment |
I have just had this problem, and found something quite peculiar, and managed to fix it Lol
Basically, if you have any entries in your hosts file, that are the same as the IP your ping is trying to resolve to, it will fail.
For example, if in your DNS, you have a record for www.example.com - 10.0.0.20, but then you have an entry in your client's hosts file, 10.0.0.20 somethingelse.com, you will not be able to ping www.example.com
Strange huh
I have just had this problem, and found something quite peculiar, and managed to fix it Lol
Basically, if you have any entries in your hosts file, that are the same as the IP your ping is trying to resolve to, it will fail.
For example, if in your DNS, you have a record for www.example.com - 10.0.0.20, but then you have an entry in your client's hosts file, 10.0.0.20 somethingelse.com, you will not be able to ping www.example.com
Strange huh
answered Jan 14 '15 at 21:25
Just Lucky ReallyJust Lucky Really
796414
796414
add a comment |
add a comment |
In my case what solved this problem was to add the domain of the host I was trying to ping to a group policy option named "DNS Suffix Search List".
The procedure in short is this: Open gpedit.msc
and navigate to Computer Configuration -> Administrative Templates -> Network -> DNS Client > DNS Suffix Search List
, set it to "Enabled" and add the domain name to the list (the list is empty by default).
A more detailed description of these steps can be found here
add a comment |
In my case what solved this problem was to add the domain of the host I was trying to ping to a group policy option named "DNS Suffix Search List".
The procedure in short is this: Open gpedit.msc
and navigate to Computer Configuration -> Administrative Templates -> Network -> DNS Client > DNS Suffix Search List
, set it to "Enabled" and add the domain name to the list (the list is empty by default).
A more detailed description of these steps can be found here
add a comment |
In my case what solved this problem was to add the domain of the host I was trying to ping to a group policy option named "DNS Suffix Search List".
The procedure in short is this: Open gpedit.msc
and navigate to Computer Configuration -> Administrative Templates -> Network -> DNS Client > DNS Suffix Search List
, set it to "Enabled" and add the domain name to the list (the list is empty by default).
A more detailed description of these steps can be found here
In my case what solved this problem was to add the domain of the host I was trying to ping to a group policy option named "DNS Suffix Search List".
The procedure in short is this: Open gpedit.msc
and navigate to Computer Configuration -> Administrative Templates -> Network -> DNS Client > DNS Suffix Search List
, set it to "Enabled" and add the domain name to the list (the list is empty by default).
A more detailed description of these steps can be found here
answered Feb 13 at 16:57
ndemoundemou
349211
349211
add a comment |
add a comment |
I had the same problem and turns out another machine had the same IP address, and that was causing it.
Changed IP back to DHCP and everything was working fine.
nslookup worked because it doesn't need to communicate with the other host. ping does need to communicate and obviously breaks.
– ndemou
Feb 13 at 17:02
@ndemou: That explanation doesn't make any sense. Yes, it is ping's job to try to communicate with the other host, but the first step in that process is to get the other host's IP address. If it gets the other host's IP address, it tells you so; if it then cannot communicate with the other host, it ultimately reports "100% loss". But, in the question, ping is failing even to get an address. (Tryping bbbbbbb.com
andping bbbbbb.com
for comparison.)
– Scott
Feb 13 at 17:57
You are right @Scott. I was editing Klaus' answer and while reading his description of the problem I forgot that this questions particular problem with ping is that it doesn't resolve. Can't be sure but I would bet now that Klaus was just not getting replies.
– ndemou
Feb 14 at 7:37
add a comment |
I had the same problem and turns out another machine had the same IP address, and that was causing it.
Changed IP back to DHCP and everything was working fine.
nslookup worked because it doesn't need to communicate with the other host. ping does need to communicate and obviously breaks.
– ndemou
Feb 13 at 17:02
@ndemou: That explanation doesn't make any sense. Yes, it is ping's job to try to communicate with the other host, but the first step in that process is to get the other host's IP address. If it gets the other host's IP address, it tells you so; if it then cannot communicate with the other host, it ultimately reports "100% loss". But, in the question, ping is failing even to get an address. (Tryping bbbbbbb.com
andping bbbbbb.com
for comparison.)
– Scott
Feb 13 at 17:57
You are right @Scott. I was editing Klaus' answer and while reading his description of the problem I forgot that this questions particular problem with ping is that it doesn't resolve. Can't be sure but I would bet now that Klaus was just not getting replies.
– ndemou
Feb 14 at 7:37
add a comment |
I had the same problem and turns out another machine had the same IP address, and that was causing it.
Changed IP back to DHCP and everything was working fine.
I had the same problem and turns out another machine had the same IP address, and that was causing it.
Changed IP back to DHCP and everything was working fine.
edited Feb 13 at 17:58
ndemou
349211
349211
answered Apr 9 '15 at 9:43
KlausKlaus
213
213
nslookup worked because it doesn't need to communicate with the other host. ping does need to communicate and obviously breaks.
– ndemou
Feb 13 at 17:02
@ndemou: That explanation doesn't make any sense. Yes, it is ping's job to try to communicate with the other host, but the first step in that process is to get the other host's IP address. If it gets the other host's IP address, it tells you so; if it then cannot communicate with the other host, it ultimately reports "100% loss". But, in the question, ping is failing even to get an address. (Tryping bbbbbbb.com
andping bbbbbb.com
for comparison.)
– Scott
Feb 13 at 17:57
You are right @Scott. I was editing Klaus' answer and while reading his description of the problem I forgot that this questions particular problem with ping is that it doesn't resolve. Can't be sure but I would bet now that Klaus was just not getting replies.
– ndemou
Feb 14 at 7:37
add a comment |
nslookup worked because it doesn't need to communicate with the other host. ping does need to communicate and obviously breaks.
– ndemou
Feb 13 at 17:02
@ndemou: That explanation doesn't make any sense. Yes, it is ping's job to try to communicate with the other host, but the first step in that process is to get the other host's IP address. If it gets the other host's IP address, it tells you so; if it then cannot communicate with the other host, it ultimately reports "100% loss". But, in the question, ping is failing even to get an address. (Tryping bbbbbbb.com
andping bbbbbb.com
for comparison.)
– Scott
Feb 13 at 17:57
You are right @Scott. I was editing Klaus' answer and while reading his description of the problem I forgot that this questions particular problem with ping is that it doesn't resolve. Can't be sure but I would bet now that Klaus was just not getting replies.
– ndemou
Feb 14 at 7:37
nslookup worked because it doesn't need to communicate with the other host. ping does need to communicate and obviously breaks.
– ndemou
Feb 13 at 17:02
nslookup worked because it doesn't need to communicate with the other host. ping does need to communicate and obviously breaks.
– ndemou
Feb 13 at 17:02
@ndemou: That explanation doesn't make any sense. Yes, it is ping's job to try to communicate with the other host, but the first step in that process is to get the other host's IP address. If it gets the other host's IP address, it tells you so; if it then cannot communicate with the other host, it ultimately reports "100% loss". But, in the question, ping is failing even to get an address. (Try
ping bbbbbbb.com
and ping bbbbbb.com
for comparison.)– Scott
Feb 13 at 17:57
@ndemou: That explanation doesn't make any sense. Yes, it is ping's job to try to communicate with the other host, but the first step in that process is to get the other host's IP address. If it gets the other host's IP address, it tells you so; if it then cannot communicate with the other host, it ultimately reports "100% loss". But, in the question, ping is failing even to get an address. (Try
ping bbbbbbb.com
and ping bbbbbb.com
for comparison.)– Scott
Feb 13 at 17:57
You are right @Scott. I was editing Klaus' answer and while reading his description of the problem I forgot that this questions particular problem with ping is that it doesn't resolve. Can't be sure but I would bet now that Klaus was just not getting replies.
– ndemou
Feb 14 at 7:37
You are right @Scott. I was editing Klaus' answer and while reading his description of the problem I forgot that this questions particular problem with ping is that it doesn't resolve. Can't be sure but I would bet now that Klaus was just not getting replies.
– ndemou
Feb 14 at 7:37
add a comment |
None of the solutions here worked for me. What did work for me was reconnecting to my work's vpn using OpenVPN. Then after disconnecting everything continued to work.
I believe the issue was related to the power going out while my computer was connected with openVPN. The only way I figured this out was by using WireShark. I noticed that the destination IPs for all the queries were going to IPs on my work's internal network.
New contributor
add a comment |
None of the solutions here worked for me. What did work for me was reconnecting to my work's vpn using OpenVPN. Then after disconnecting everything continued to work.
I believe the issue was related to the power going out while my computer was connected with openVPN. The only way I figured this out was by using WireShark. I noticed that the destination IPs for all the queries were going to IPs on my work's internal network.
New contributor
add a comment |
None of the solutions here worked for me. What did work for me was reconnecting to my work's vpn using OpenVPN. Then after disconnecting everything continued to work.
I believe the issue was related to the power going out while my computer was connected with openVPN. The only way I figured this out was by using WireShark. I noticed that the destination IPs for all the queries were going to IPs on my work's internal network.
New contributor
None of the solutions here worked for me. What did work for me was reconnecting to my work's vpn using OpenVPN. Then after disconnecting everything continued to work.
I believe the issue was related to the power going out while my computer was connected with openVPN. The only way I figured this out was by using WireShark. I noticed that the destination IPs for all the queries were going to IPs on my work's internal network.
New contributor
New contributor
answered 2 days ago
BelaBela
101
101
New contributor
New contributor
add a comment |
add a comment |
ping uses the ICMP protocol, specifically the 'Echo Request' and 'Echo Reply'.
many networks disable ICMP utilities in order to prevent attacks or basic network scanning. I've found many routers you purchase come with a setting to disable ping and like utilities enabled by default.
you can find more about ICMP here:
http://en.wikipedia.org/wiki/Internet_Control_Message_Protocol
8
Yes, but before using ICMP, the domain has to be resolved to an IP address as usual. So this is not the issue here.
– Michael
Nov 23 '12 at 2:25
add a comment |
ping uses the ICMP protocol, specifically the 'Echo Request' and 'Echo Reply'.
many networks disable ICMP utilities in order to prevent attacks or basic network scanning. I've found many routers you purchase come with a setting to disable ping and like utilities enabled by default.
you can find more about ICMP here:
http://en.wikipedia.org/wiki/Internet_Control_Message_Protocol
8
Yes, but before using ICMP, the domain has to be resolved to an IP address as usual. So this is not the issue here.
– Michael
Nov 23 '12 at 2:25
add a comment |
ping uses the ICMP protocol, specifically the 'Echo Request' and 'Echo Reply'.
many networks disable ICMP utilities in order to prevent attacks or basic network scanning. I've found many routers you purchase come with a setting to disable ping and like utilities enabled by default.
you can find more about ICMP here:
http://en.wikipedia.org/wiki/Internet_Control_Message_Protocol
ping uses the ICMP protocol, specifically the 'Echo Request' and 'Echo Reply'.
many networks disable ICMP utilities in order to prevent attacks or basic network scanning. I've found many routers you purchase come with a setting to disable ping and like utilities enabled by default.
you can find more about ICMP here:
http://en.wikipedia.org/wiki/Internet_Control_Message_Protocol
answered Nov 22 '12 at 12:34
JohnnieJohnnie
26216
26216
8
Yes, but before using ICMP, the domain has to be resolved to an IP address as usual. So this is not the issue here.
– Michael
Nov 23 '12 at 2:25
add a comment |
8
Yes, but before using ICMP, the domain has to be resolved to an IP address as usual. So this is not the issue here.
– Michael
Nov 23 '12 at 2:25
8
8
Yes, but before using ICMP, the domain has to be resolved to an IP address as usual. So this is not the issue here.
– Michael
Nov 23 '12 at 2:25
Yes, but before using ICMP, the domain has to be resolved to an IP address as usual. So this is not the issue here.
– Michael
Nov 23 '12 at 2:25
add a comment |
Thanks for contributing an answer to Super User!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f495759%2fwhy-is-ping-unable-to-resolve-a-name-when-nslookup-works-fine%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
You could add a default DNS suffix for
.company.com
.– billc.cn
Oct 29 '12 at 20:25
@billc.cn I already have that DNS suffix.
– skiphoppy
Oct 30 '12 at 16:35
What I think's happening is that ping isn't looking up the FQDN of the host, unlike
nslookup
which uses thesearch domain
parameter of a DHCP offer (or whatever you specify for a static IP configuration). Confirm this by doing what @SLaks has said and pinging the FQDN of the host :)– jackweirdy
Nov 19 '12 at 17:57
1
Possible duplicate of: superuser.com/questions/220471/…
– Der Hochstapler
Nov 19 '12 at 17:57
What happens when you run
ping -4 wolfman
?– Der Hochstapler
Nov 19 '12 at 18:00