Windows Share FAQ

The CS labstaff maintains a server, named share, which runs the SAMBA software. This allows Windows users to access files in their UNIX home directories. The following FAQ is designed to help Windows users set up their machines to access share.

If you do login to share, please remember to disconnect when you are done. This can be accomplished by disconnecting the drive, logging out of the system or rebooting.

Windows XP/2000 access to the network.

  1. Make sure your machine has obtained an IP address. This can be done either by using DHCP or you can request a static IP from the Lab Staff (please mention the machine type, OS, and name you would like).
  2. Properly install Windows XP/2000 and its networking software. If you are doing the initial installation of XP/2000, it may automatically prompt you for the network settings. If not, right-click on the My Network Places icon on your desktop and select Properties.
  3. In the Network and Dial-up Connections window right-click on Local Area connection and select Properties. This will pop-up another window labeled Local Area Connection Properties.
  4. The default behavior for Windows is to install three things: Client for Microsoft Networks, File and Printer Sharing, and Internet Protocal (TCP/IP). You should disable File and Printer Sharing and enable the other two.
  5. Now double-click on Internet Protocol(TCP/IP). This will bring up a new window where you can set the IP address, subnet mask, default gateway and preferred DNS server.
  6. If you are using DHCP, check the radio button Obtain an IP address automatically. Otherwise, enter the IP address given to you, the Subnet Mask ( and the Default gateway (

    You can set the DNS Servers or choose to Obtain DNS sever address automatically. The Preferred DNS server should be and the Alternate DNS server should be set to

  7. Click on the Advanced tab. In the new window you will see tabs for IP Settings, WINS, DNS and Options.
  8. Select the WINS tab and under NetBIOS Setting select the Default radio button.
  9. Select the DNS tab and select the append these DNS suffixes (in order): button. Add and Also, uncheck the box that says Register this connection's addresses in DNS.
  10. Click OK.
  11. Click Start → Run... and run the Regedit.exe command
  12. From the HKEY_LOCAL_MACHINE on Local Machine window, navigate to the following folder: SYSTEM\CurrentControlSet\Services\LanmanWorkStation\Parameters
  13. Click Edit → New → DWORD Value and name the new value:
  14. Right Click on the above entry, select Modify and enter:
    Value Data: 1
  15. Click OK and then quit Regedit.exe
  16. Restart Windows.
  17. Map a network drive to the share server.

Mapping a Network Drive.

To do this, you must do what is commonly referred to as logging on to the share server. There are several methods for doing this. You can find step by step instructions (with pictures!) in the Drive Mapping FAQ.

Without knowing your configuration settings, this is the easiest way:

  1. Click Start → Run
  2. Enter the command: net use * \\share\homes
  3. Enter you UNIX username and password when prompted.
  4. The mapped drive will appear under My Computer and can be accessed from any Internet Explorer or Windows Explorer windows.

Installing a network printer.

Notes about printer naming and header pages:

To install a printer:

  1. Map a network drive to the share server.
  2. Click Start → Settings → Printers
  3. Double click Add Printer icon
  4. Select Network Printer Server and click Next
  5. Type \\share\printer and click OK (replace printer with the name of the printer)
  6. Click OK to install drivers on your local machine
  7. Select the make and model of your printer, and click OK (for a list of printer types see /etc/printcap)
  8. Select Yes or No for your default settings
  9. Click Next and then Finish

Accessing your home directory from untrusted networks

If you are outside the CS trusted network, you will need to setup a secure tunnel to access your CS directories. Examples of this include access from home through your ISP, from the Duke wireless network or from a network at another school. This can be accomplished by using a Windows or UNIX stunnel client.

As of May 2006, we have changed the way we share the Windows server. We have installed stunnel, which sets up a secure tunnel that is available at all times while your computer is connected to the internet. The program is available for most major platforms from the stunnel site; Mac OSX users can compile the source or install the darwin port.

In order to use stunnel, you will need to put the following files in the stunnel directory (typically C:\Program Files\stunnel). The client.pem will allow you to establish the secure connection, and the stunnel.conf file has all of the settings to connect to the servers, and use the client.pem file. (these files are only accessible from machines within the CS network; if you need access to the files outside the department network please contact the Lab Staff.

You will either need to uninstall File and Printer Sharing on your machine or temporarily stop the Server service on your system. If you choose to stop the server, it will restart on the next reboot. This is useful if you intend to reenable local file serving or printing services on your home network.

To uninstall File and Printer Sharing:

  1. Open Control Panel → Network Connections → (select enabled network device) → Properties
  2. Select the File and Print Sharing services and select Uninstall.

To stop the Windows Server Service:

  1. Start → Run and run the services.msc command
  2. Scroll down until you find the Server entry, and right-click on Server and select Stop.
  3. Note: This stops the server service during the current session. It will automatically start again after a reboot unless you change the Startup Type.

After putting the files in place, and starting stunnel you will have a secure tunnel for accessing your CS files as well as providing access to the CS printers.

In order to mount a directory, right-click on the My Computer icon and select Map Network Drive. When the Map Network Drive dialog box appears, enter the address The computer will select an available drive letter that is appropriate.

        \\\your-cs-username (replace your-cs-username with your CS login ID) 

This same method can be used to add printers. When configuring the printer, you can select a network printer and use the name:

To install a printer:

  1. Click Start → Settings → Printers
  2. Double click Add Printer icon
  3. Select Network Printer Server and click Next
  4. Type \\\printer-name and click OK (replace printer with the name of the printer)
  5. Click OK to install drivers on your local machine
  6. Select the make and model of your printer, and click OK (for a list of printer types see /etc/printcap)
  7. Select Yes or No for your default settings
  8. Click Next and then Finish