Home » Visitors/New Users/Printing/Email/etc » Current Page

Mounting SMB shares in Linux

Problem:

You have resources being served remotely from Windows systems via SMB. You'd like to access them from your Linux system.

Solution:

There exists a Windows Network interface for Linux called Samba. Using this software, one can mount any Windows share just as easily as if it were an NFS share.

HOWTO:

1. First make sure you have samba installed:

On Ubuntu:

# apt-get install smbclient smbfs

On Fedora:

# yum install samba samba-client

2. Configure samba. There's a great deal more to this than may be covered within this document, but for our purposes, there are only a couple key settings which must be changed. Edit /etc/samba/smb.conf.

Workgroup = phy-ast
Security = user
Wins support = yes
Wins server = 35.9.68.81
Encrypt passwords = true

3. You may now mount your shares. For instance, if you'd like to mount the users directory on endeavor:

# mount -t smbfs -o username=domainuser \ //endeavor.pa.msu.edu/users /mountpoint

4. And, of course, to unmount your share:

# umount /mountpoint
Further Notes:

You may also use the samba server for mounting directories on your linux system on a windows system. This, however, is beyond this document, and should probably involve the assistance of Computing Services, as it is possible to configure a samba server which may interfere with the normal functioning of the Windows domain.

Last updated October 2007, by Nathan Gamber