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
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
- Checks where the name in question is the local host name
- Checks DNS client resolver cache
- Checks Local NetBIOS name cache
- Contacts the configured WINS servers (You more than likely don't have any)
- Broadcasts NetBIOS Name Query Request messages to the local subnet
- 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
- nbtstat -R
- 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"
- Click "Start" -> Type "Network and Sharing Center" -> Click "Network and Sharing Center"
- Click "Change advanced sharing settings" on the left panel
- Expand out the menu for the type of Network you are set to Home, Work, or Public
- "Turn on" "network discovery" and "file and printer sharing"
- 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
- Open and administartor command prompt
- Execute
netsh winsock reset catalog 2 - Execute
netsh int ip reset reset.log
Check Services Computer Browser and TCP/IP NetBIOS Helper are running
- Click "Start" -> Type "Services" -> Click "Services"
- Find "Computer Browser" on the list and make sure it is "Started"
- Do the same for "TCP/IP NetBIOS Helper"
Make sure Windows firewall is not blocking the connection.
Domain Issues
User not in a Domain accessing share in a Domain
- Clear the shares to prevent errors
net use * /deletethis will wipe all the mounted network shares. - Connect to \\DAVES-PC
- Tick Connect using a different username
- 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
- 3,744
- 2
- 23
- 30
-
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 '11 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 '11 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 '11 at 17:56
-
Try turning your firewall off temporarily to see if it work without that restriction http://windows.microsoft.com/en-US/windows-vista/Turn-Windows-Firewall-on-or-off – Riguez Mar 25 '11 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 '11 at 20:31
-
Doubt the vmware/virtualbox are the problem why do you have both btw? – Riguez Mar 25 '11 at 20:32
-
Couple other things to try. Click Start -> Type "View Network Connections" -> Right Click on your adapter and click properties. Make sure "Client for Microsoft Networks" is check. Click Internet Protocol Version 4 -> Click Properties -> Click Advanced -> Click WINS Tab -> Tick Enable NetBIOS over TCP/IP -> Click Ok... Ok... Close and then reboot. – Riguez Mar 25 '11 at 20:41
-
Already done as soon you suggested it was a NETBIOS problem. Netbios wan disabled and I turned it on as you describe here. As soon as I did it I managed to ping DAVES-PC. So now I have its ip address but then I don't see its network shares and the same happen for another network share that is in my office. So now my problem is that I cannot see network shares even if I am able to ping the corresponding computers. Thanks for all your support. Sadly I cannot vote up your answers yet. – register Mar 26 '11 at 07:04
-
Did you make sure you are in the same workgroup,turn off firewall, and check those services I described? Also something I should have said before what type of network are you using in the "Network and Sharing Center" is it "Home network" "Work Network" or "Public network" make sure it is set to "Home". If you want it on "Public" you will need to click "Advanced Sharing settings" on the left panel and turn on "Network Discovery" "File and Printer Sharing" "Public Folder Sharing" etc etc. – Riguez Mar 26 '11 at 09:38
-
I am in the same workgroup, no external firewalls. The network type is work network. Network and printer discovery is on: I can explore networks and the printer are automatically discorevered and installed correctly. However I cannot print nor access to the networks. – register Mar 28 '11 at 10:43
-
I have just found that ONLY the shares that I cannot access are on domains that are different from the one I'm joined to. – register Mar 28 '11 at 12:20
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.
- 896
- 7
- 13
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
- 331
- 1
- 3
-
We are using DHCP. I tryed to flush the cache, no improvement though. – register Mar 25 '11 at 14:51
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.
.
- 58,044
- 21
- 113
- 176
-
1This 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 '11 at 14:50
-
-
-