It will also help if you try to identify what part of file sharing isn't working. There are basically three parts.
- Network Browsing (shows list of computers)
- Name Resolution (Computer Name to IP address)
- SMB (connect, list and transfer files)
To eliminate the first two as possible problems, find out the correct IP address of the server computer (the one sharing files). Then enter the IP address instead of the computer name like this.
Code:
\\nnn.nnn.nnn.nnn\sharename
Replace the "nnn.nnn.nnn.nnn" with the IP address of the computer. Replace "sharename" with the name of the network share (shared folder name). You may have to enable the folder option to view the folder address bar. Enter the IP and share name in the address bar of a folder. You will be prompted for an account name and password.
If you cannot list files, usually that means your user account does not have permissions to log in to samba. Windows will try using your account name and password, and also will try using the guest account with no password. In some cases you may have to map a network drive and override the account name and password in order to access a shared folder.
Make sure that TCP ports 139 and 445 are not being blocked by firewall software (Kaspersky, Norton or Macafee). Those ports are required to communicate when listing and transferring files.
Also, be careful if you had a failed attempt to access something. You may need to delete the "$IPC" share that is left over from the last attempt.
To display currently established sessions use this from a command prompt.
You can delete left over sessions like this.
Code:
NET USE \\computername\IPC$ /D
Once you are able to list and access files using the IP address then you can try using the computer name. Type in the computer name instead of an IP address. If Windows can't find the computer's IP address (or can't find the computer name) then the problem is with name resolution.
Windows tries to resolve computer names in a few different ways.
- NETBIOS broadcasts on UDP port 137
- Domain Name Service (DNS)
- The "hosts" file
- The "LMHOSTS" file
- A Windows Internet Name Service (WINS) server if one is configured
On most people's network, there is no DNS server that allows PCs to register names. DNS is only useful for looking up web addresses on most people's home network since it just gets relayed to the Internet provider's DNS server. That means for most people's home network the computer names are resolved by NETBIOS broadcasts. NETBIOS broadcasts won't work for computers on different IP network addresses even if they are connected to the same LAN. Also, some routers may block some kinds of broadcasts on wireless. If you're having problems with name resolution, the simplest solution is to add the server computer name and IP address to the "hosts" file on the client computers. If that fixes the problem you know it was due to name resolution.
The last, and most troublesome part to deal with is network browsing. That maintains a list of computers that are "seen" in the work-group or domain. If you can connect to computers by typing in the name or IP address but can't "see" the computer names in the list of detected computers then the problem is network browsing. The work around for this is to create shortcuts that have the computer name and share name to avoid having to click on computer names that are "seen". Or, you can simply type the computer name and share name in the address bar of a folder window.
Network browsing uses broadcasts on UDP port 138. Make sure that port is not blocked and broadcasts are not being blocked. Since the list of detected computers is updated infrequently, it can take 15 minutes or more for a computer to appear in the browse list. Computers negotiate to see which ones will maintain the list. I won't go into it here, but there are registry settings (and samba settings) to control which computers maintain the browse list. If you're unlucky, a slow or mobile computer is keeping the list. You could have problems after shutting down or starting up computers. When you connect or disconnect computers frequently, or shut off power, you should designate the computers that you want to maintain the browse list for your network. There are settings you can add to the "LMHOSTS" file in Windows that allow seeing computers in other work-groups or domains. It's easiest just to make sure that all your computers are in the same work-group so that they "see" each other.