Configuring a Windows PC to share FilesMany unexperienced users have problems configuring their Windows PC to share files. The definitive reference for this type of questions is the documentation that comes with your Windows operating system, of course. We have compiled this guide for those who want a short, technically oriented recipe. It is a mixture of setup instructions and a trouble shooting guide (you would not read this section if you had no problems, would you?).
ping 192.168.1.55If ping works, IP connectivity is established. If not, right-click the "Network Neighborhood" on the Windows desktop, choose "Properties", double-click your network interface adapter and click the "Properties" button. You will now see a window with various services and protocols. One of them is TCP/IP networking. Browse the properties of TCP/IP to see whether everything looks OK. Use the Windows help where appropriate. Note that you need to be an administrator in order to change any settings!
Once you have ping and thus basic IP networking running, check TCP. This is best done from the Unix command line with "telnet". With the example IP address from above that would be:
telnet 192.168.1.55 139This command tries to establish a connection to TCP port 139. There are three possible results:
(1) The port can be reached and everything works as expected:
$ telnet 192.168.1.55 139Everything is OK and you can quit the session by typing the escape character and then "q".
(2) The port is not "listening":
$ telnet 192.168.1.55 139In this case the server service is probably not started on the Windows side or the server has Netbios over TCP disabled. Go to the list of services and protocols as described above, but instead of inspecting TCP/IP, have a look at "File and Print Services for Microsoft Networks". Check that they are installed and active.
(3) The port is not reachable:
$ telnet 192.168.1.55 139Then it hangs waiting for a reply. After a couple of minutes it prints:
telnet: connect to address 192.168.1.55: Operation timed outIn this case a firewall is probably blocking the connection. Please make sure to allow access to TCP ports 139 and 445 and UDP ports 137 and 138 in your Windows firewall.
If the server does not allow Netbios over TCP, Sharity can still connect. Please repeat the steps above with port number 445 instead of 139 to verify that the CIFS port is "open".
It will help you to know that SMB/CIFS has two modes of operation: User Level security and Share Level security. In user level security, users authenticate to the server and then have access to all shares available on the server. Each user has a separate private password. In share level security, each share has a separate password and everybody who knows this share password is granted access. It's the same password for all users and no user name is required. Windows 95, 98 and ME are primarily built for share level security. The server operating systems (NT, 2000 Server and 2003 Server) as well as Windows 2000 Professional and XP Professional all prefer user level security. XP Home Edition uses a kind of faked user level security: It asks for a user name and password, but accepts login only if an empty password is provided.
Since you want to access the Windows computer by name, there must be a service which maps the name to the appropriate IP address. Windows traditionally used Netbios Name service for this purpose. With Windows 2000, Microsoft has migrated to DNS (Domain Name Service), though. Netbios is usually still supported. If your network uses DNS, you can verify name resolution with ping or telnet. Using the computer name instead of the IP address should work. If you rely on Netbios, there is no standard utility available for testing, you need a special tool like "nmblookup" which is part of the Samba distribution. If your network uses a WINS server, make sure that the WINS setting is the same in Sharity and on the PC.
If the name service works, accessing a share through /CIFS/share[computer] should work. Browsing the network in the "entire_network" directory requires an other service: the Local Master Browse server (LMB). This service is elected dynamically among all Windows computers and other computers running an SMB server (such as e.g. Samba servers). The LMB service is usually enabled on computers where file and printer sharing is enabled. As a last resort, you can install Samba on your own Unix computer to ensure that there is an LMB. The easiest way to circumvent browsing problems, however, is to enter the resources manually in the Sharity GUI.