4

I have a laptop installed with Windows 7 that has problems in accessing network shares. Even if I am able to ping the computers containing the share then I get the infamous "Windows cannot access the ... share". At the beginning I hadn't netbios enabled so I was not able to reach the computers. After enabling netbios I ping the computers containing the shares correctly. I have an installation of VMPlayer, Virtual Box and Avira Antivir. No 3rd party firewall or other security software is installed.

4 Answers 4

4

The issue is not with DNS the issue is with NetBIOS

DNS(Domain Name Service) resolves FQDN(Fully Qualified Domain Names) to IP addresses like http://www.google.com to http://74.125.229.84/

NetBIOS resolves local computer names(hostnames) to IP addresses like \\DAVES-PC to 192.168.1.190

The way NetBIOS resolves names is in this order

  1. Checks where the name in question is the local host name
  2. Checks DNS client resolver cache
  3. Checks Local NetBIOS name cache
  4. Contacts the configured WINS servers (You more than likely don't have any)
  5. Broadcasts NetBIOS Name Query Request messages to the local subnet
  6. Searches LMHosts file (Resolves names on remote subnets)

Option 1

You can try to clean out the cache by

Clicking Start -> Type cmd -> Right Click and "Run As Administrator" -> Click Yes

Execute these commands

  1. nbtstat -R
  2. ipconfig /flushdns

If you are still having issues make sure your computers are in the same workgroup this is typically named WORKGROUP

For Windows 7

Click Start -> Right Click on Computer -> Click Properties -> Click Advanced System Settings(on the left panel) -> Click Computer Name Tab -> Click Change

Here you can change the name of your workgroup make sure all your computers are in the same one.

Option 2

You can add manual entries into your hosts file these entries will be loaded into your DNS client resolver cache which is the second thing checked.

Click Start -> Type Notepad -> Right Click "Run As Administrator" -> Click Yes -> File Menu -> Open -> Navigate to C:\Windows\System32\drivers\etc -> Open hosts ->

Add you entries at the end of the file in this format

<IP Address> <Name>

Example:

192.168.1.190 DAVES-PC

This would work best with static IP addresses which are easy to configure but depend on the other OS you are using just google it.. it will work with DHCP as most home routers seem to repeatedly give the same IP to the same computer based on the MAC address at least in my experience... have changed OS's and kept the same IP on mine using DHCP lol.

From Comments

Check Share Settings in "Network and Sharing Center"

  1. Click "Start" -> Type "Network and Sharing Center" -> Click "Network and Sharing Center"
  2. Click "Change advanced sharing settings" on the left panel
  3. Expand out the menu for the type of Network you are set to Home, Work, or Public
  4. "Turn on" "network discovery" and "file and printer sharing"
  5. Adjust the other settings to your needs.

Reset the TCP/IP Stack. This will revert all your settings back to default so you may need to change some back e.g. Static IP will be reset to DHCP

  1. Open and administartor command prompt
  2. Execute netsh winsock reset catalog 2
  3. Execute netsh int ip reset reset.log

Check Services Computer Browser and TCP/IP NetBIOS Helper are running

  1. Click "Start" -> Type "Services" -> Click "Services"
  2. Find "Computer Browser" on the list and make sure it is "Started"
  3. Do the same for "TCP/IP NetBIOS Helper"

Make sure Windows firewall is not blocking the connection.

  1. Allow sharing as described Here or Here

Domain Issues

User not in a Domain accessing share in a Domain

  1. Clear the shares to prevent errors net use * /delete this will wipe all the mounted network shares.
  2. Connect to \\DAVES-PC
  3. Tick Connect using a different username
  4. Fill in valid credentials for that domain/share DOMAIN\Username and Password e.g. DAVEco\Dave for username.

User in different Domain requires there to be trust between the two domains read here for more information

11
  • Hi, your asnwer is interesting and probably in the right direction. Now I am able to ping DAVES-PC however when I try to access its shared folder I get the usual "Windows cannot access \\DAVES-PC" message. After entering the "nbtstat -R" command I received the following message " NetBT is not bound to any devices ". Any clue?
    – register
    Mar 25, 2011 at 16:03
  • Try these commands at the administrator command prompt 1. netsh winsock reset catalog 2. netsh int ip reset reset.log then Reboot your computer and try again. These commands help repair the tcp/ip stack
    – Riguez
    Mar 25, 2011 at 16:21
  • No luck: same as before. I can ping DAVES-PC but then still getting the message "Windows cannot access \\DAVES-PC". Of course the share is accessible by other laptops. I have a Vmware and VirtualBox installed. The add some virtual ethernet cards: could this be the root of the problem?
    – register
    Mar 25, 2011 at 17:56
  • Try turning your firewall off temporarily to see if it work without that restriction windows.microsoft.com/en-US/windows-vista/…
    – Riguez
    Mar 25, 2011 at 19:42
  • You should also make sure "Computer Browser" and "TCP/IP NetBIOS Helper" are started and maybe restarting them would help. This can be done on under the services manager Click Start -> Type Services -> click the one labeled Services
    – Riguez
    Mar 25, 2011 at 20:31
1

Try clearing the DNS cache. Run command prompt with elevated privilages and type

ipconfig /flushdns

May also be worth checking the details your network adapter is given by typeing

ipconfig /all

look for the Ethernet controller and see what gateway and dns is has been given.

Also try using tracert to the name you are trying to reach, e.g.

tracert www.yahoo.com

I had some trouble with DNS, turns out my laptop was trying to use my Wireless connection instead of my Ethernet connection to access it.

0

are you using DHCP or static IP? if using static IP could you have entered a wrong DNS server? if using DHCP you can try to clear your DNS Cache by keying in at the command prompt:

ipconfig /flushdns

1
  • We are using DHCP. I tryed to flush the cache, no improvement though.
    – register
    Mar 25, 2011 at 14:51
0

Be sure the DNS Client service is set to automatic and is running (Windows Services)

You could hard code those IP's into your hosts file.

Open Notepad as an administrator, then use file > Open and navigate to

C:\Windows\System32\drivers\etc

(you may need to set the browser window to "all files" to see the hosts file)

Open hosts

add your entries, save changes.

.

4
  • 1
    This won't solve all the problems. We are using DHCP so some ip are changing from time to time. Also my colleagues' laptops work fine, so it is something that has to do with my laptop. I want to understand and solve the root of the problem. Could you help?
    – register
    Mar 25, 2011 at 14:50
  • Do you have some sort of security software running on your PC?
    – Moab
    Mar 25, 2011 at 15:58
  • I have Avira Antivir
    – register
    Mar 25, 2011 at 19:34
  • any 3rd party firewall?, just pain old antivirus?
    – Moab
    Mar 25, 2011 at 23:13

You must log in to answer this question.

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