1 2 Previous Next 20 Replies Latest reply on Dec 8, 2019 3:03 PM by asktomsk

    Slow DNS lookup

    srynoname Enthusiast

       

      Hello,

       

       

      in all my virtual machines (workstation 7, vmware tools installed, guest systems: xp, 7, server 03, server 08) a DNS lookup takes around 4 seconds! How can I speed this up / fix this? Thanks!

       

       

        • 1. Re: Slow DNS lookup
          AWo Guru

          Which network do you use (bridged, NAT) and how long does that lookup take on the host (assumed the same DNS server and URL is used).

           


          AWo

          \[:o]===\[o:]

          =Would you like to have this posting as a ringtone on your cell phone?=

          =Send "Posting" to 911 for only $999999,99!=

          • 2. Re: Slow DNS lookup
            srynoname Enthusiast

            thanks for your reply, I'm using the default NAT. DNS lookup on the host happens "immediately". This is why I have no idea where to start looking for errors ):

            • 3. Re: Slow DNS lookup
              louyo Master

              PMJI:

               

              Somewhat internet address sensitive, but NAT seems to make a difference... Win 7 guest/ Ubuntu host:

              -


              From Guest, NAT mode:

               

              C:\Users\Administrator>nslookup

              Default Server:  UnKnown

              Address:  172.16.202.2

              vmware.com

              Server:  UnKnown

              Address:  172.16.202.2

              DNS request timed out.

                  timeout was 2 seconds.

              DNS request timed out.

                  timeout was 2 seconds.

              Non-authoritative answer:

              Name:    vmware.com

              Address:  165.193.233.120

               

              yahoo.com

              Server:  UnKnown

              Address:  172.16.202.2

               

              Name:    b1.www.vip.sp1.yahoo.com

              Addresses:  209.131.36.159

                        209.131.36.159

              Aliases:  yahoo.com.localdomain

               

              (172.16.202.2 is the default gateway assigned via NAT DHCP).

               

              -


              From Host:

              lou@dell690:~$ nslookup

              vmware.com

              Server:          208.67.222.222

              Address:     208.67.222.222#53

               

              Non-authoritative answer:

              Name:     vmware.com

              Address: 165.193.233.120

              -


               

              From Win7, changed to bridged mode, replicate physical network:

               

              C:\Users\Administrator>nslookup  vmware.com

              Server:  resolver1.opendns.com

              Address:  208.67.222.222

               

              Non-authoritative answer:

              Name:    vmware.com.ffhffh

              Address:  208.69.32.132

              -


              Note that converting the DNS to static, when in NAT mode does not help.

               

              Lou

              • 4. Re: Slow DNS lookup
                AWo Guru

                Which DNS server do you use in your guest? The host VMnet8 adapter +1?

                 


                AWo

                \[:o]===\[o:]

                =Would you like to have this posting as a ringtone on your cell phone?=

                =Send "Posting" to 911 for only $999999,99!=

                • 5. Re: Slow DNS lookup
                  srynoname Enthusiast

                  thank you all for your replies.

                  I'm using the  "NAT: used to share the hosts ip address" option (the one where you don't explicitely choose a network adapter).I tried the bridged entwork adapter, this one works fine (meaning fast dns lookup). interesting, that louyo gets the same results, so this seems to be a vmware problem.

                   

                  I also tried:

                   

                   

                   

                  • custom network (VMnet 8) and in the network editor (option nat settings for vmnet 8) I added the DNS server manually (instead of auto detect available dns servers).

                  • "NAT: used to share the hosts ip address" option and setting IP and DNS manually. Even this doesn't work! (like louyo also noted)

                   

                   

                  I want to use NAT though, not bridged ):

                   

                   

                  @Awo: DNS server in guest is the one VMware assigns (which seems to be a virtual one / it's not the address of the only one DNS server / router I have). Also tried setting the router as DNS Server manually. Still takes around 4 seconds when using the NAT interface!

                  • 6. Re: Slow DNS lookup
                    srynoname Enthusiast

                    maybe a dumb question, but where can I report this as bug? Support is not available for trial users!?

                    • 7. Re: Slow DNS lookup
                      Scissor Virtuoso

                      DNS lookups are (mostly) UDP based -- maybe something is messing with UDP packets...  What operating system are you running on your Host?  Will assume Windows.

                       

                      What Antivirus do you have installed on your Host?  Any 3rd party firewall or other "security" software installed? 

                       

                      Try (temporarily) disabling any "task offload" or other "offload" settings for the Network Adapter installed in your Host to see if that makes a difference.

                      • 8. Re: Slow DNS lookup
                        srynoname Enthusiast

                        hello,

                        yes, I'm running win 7 x64. no anti virus and only the windos firewall. no other security software installed.

                        unfortunately I don't know, what you mean with task offload settings and where to find them? thanks!

                        • 9. Re: Slow DNS lookup
                          Scissor Virtuoso
                          srynoname wrote:

                          unfortunately I don't know, what you mean with task offload settings and where to find them? thanks!

                           

                          From your Desktop... Right Click Computer -> Manage -> Device Manager -> Network adapters -> right-click on your Network Adapter, properties -> Advanced Tab

                           

                          Look for entries that mention "offload".  Each adapter will be different.  For example, my Broadcom adapter has "Large Send Offload", "Proxy ARP offload", "Proxy NS Offload", and "TCP/UDP Checksum offload" settings that can be enabled or disabled.

                          • 10. Re: Slow DNS lookup
                            srynoname Enthusiast

                            thanks for your instructions, I tried that, but it din't change anything ): Also the problem only occurs when using NAT (it works fine when using bridged), while both connections - nat and bridged - use the same (real) lan card, so shouldn't this problem be independet of the network card if one of them works?

                            • 11. Re: Slow DNS lookup
                              Scissor Virtuoso
                              srynoname wrote:

                              thanks for your instructions, I tried that, but it din't change anything ): Also the problem only occurs when using NAT (it works fine when using bridged), while both connections - nat and bridged - use the same (real) lan card, so shouldn't this problem be independet of the network card if one of them works?

                               

                              Ideally that would be correct, but who knows exactly how the vmware NAT service works? 

                               

                              Maybe check to make sure you are running the latest driver for your Host's network card?

                               

                              What happens if you manually configure the DNS entry for your Guests while they are using NAT and set it to be the same DNS server that your desktop uses?  Are Guest DNS lookups faster then?

                              • 12. Re: Slow DNS lookup
                                srynoname Enthusiast

                                 

                                After hours of playing aroudn I finally found a way to fix it, though I claim it's still a VMware Workstation problem:

                                On Windows 7 you can select a network profile (home, at work, public...). You have to select home and maybe restart your NAT-ted VM, then DNS lookups are as fast as they should be. If one selects the public profile, this results in very slow DNS lookups. This is the irony of it - in an insecure, public environment you get problems (slow DNS lookups) when you try to secure your guest by using the NAT interface! For me this is clearly a bug, however I still don't know where to report this...

                                 

                                 

                                BTW the free virtualbox has no problems using nat and the public network profile...

                                 

                                 

                                • 13. Re: Slow DNS lookup
                                  mateid Lurker

                                  I have what appears to be the same problem and your solution doesn't work for me.

                                   

                                  I'm running VMware Player 4.0.0 build-471780 on a Windows 7 Pro x64 host, with a Mint 11/Kubuntu 11.04 guest. My network adapter is set to NAT. The contents of my /etc/resolv.conf are:

                                   

                                  $ cat /etc/resolv.conf

                                  domain localdomain
                                  search localdomain
                                  nameserver 192.168.106.2

                                   

                                  Each nslookup through the (virtual) DNS above takes 2s, each nslookup through the host's DNS is instantaneous:

                                   

                                  $ time nslookup vmware.com
                                  Server:         192.168.106.2
                                  Address:        192.168.106.2#53

                                  Non-authoritative answer:
                                  Name:   vmware.com
                                  Address: 165.193.233.120


                                  real    0m2.006s
                                  user    0m0.000s
                                  sys     0m0.000s

                                   

                                  $ time nslookup vmware.com <real_dns_ip>
                                  Server:         <real_dns_ip>
                                  Address:        <real_dns_ip>#53

                                   

                                  Non-authoritative answer:
                                  Name:   vmware.com
                                  Address: 165.193.233.120

                                   


                                  real    0m0.006s
                                  user    0m0.000s
                                  sys     0m0.000s

                                   

                                  I tried Home/Work/Public network settings in the Windows host, but I see no difference in results. The problem goes away if I manually add the external DNS ip at the top of resolv.conf. Is there a way to do this automatically each time I switch the external network of the host?

                                   

                                  When using a Bridged connection for the VM network (instead of NAT), the problem also goes away. In that case resolv.conf gets the real DNS ip. However, I would prefer using NAT.

                                   

                                   

                                  EDIT: I have realized in the meantime that for me, the problem above occurs only when using a wired network connection for the host. Wireless seems to be fine. I still wish this was fixed.

                                  • 14. Re: Slow DNS lookup
                                    derickso Enthusiast

                                    I'm seeing the same behavior, Win 7 host with Ubuntu guest, I tried setting the network to private in my host and it made no difference.  This looks like a bug in their NAT-DNS code, it is taking an explicit timeout before sending the query out on the wire, eg if I go to the VMware Virtual Network Editor -> click the NAT network -> NAT Settings -> DNS Settings -> Timeout, the Timeout value in seconds is the amount of time between when your guest will send the DNS request, and your host will actually put it on the wire.  Unfortunately timeout of 0 uses the default value of 2s, but you can set 1 which is at least better than 2.  This definitely needs to be fixed asap.  As a workaround set static DNS in your guest if you can.

                                    1 2 Previous Next