Roshan Book

My Tech Notebook

Liberian Geek – Tutorials for Linux, Ubuntu, Fedora and Windows Users! [Follow Us] Home About Us Contact Us Home How-To/Tips Internet Linux Security Web Windows How to Permanently Mount Samba Shares in Ubuntu 11.04 Natty Narwhal


Source:http://www.liberiangeek.net/2011/04/how-to-permanently-mount-samba-shares-in-ubuntu-11-04-natty-narwhal/

This article describes how to permanently mount Samba Shares in Ubuntu 11.04 Natty Narwhal. We have written many tutorials about file sharing on this site. This one shows you how to mount those shares permanently in Ubuntu. These can be shares on Windows  or Linux machines. When shares are permanently mounted, they will always be there everytime you login to your desktop.

 

Getting started:

 

To get started, press Ctrl – Alt – T to open Terminal. Then install Samba Server by running the command below:

sudo apt-get install samba smbfs

natty_samba_permanent

 

After installing Samba, run the command below to edit the fstab file.

gksu gedit /etc/fstab

natty_samba_permanent_1

 

When fstab file open, add the line below at the bottom of the file and save. Replace //SERVER/Shares with the IP Address or Hostname of the computer and the share name. For username and password, enter your username and password for the computer hosting the shares.

//SERVER/shares /MOUNTPOINT smbfs username=user,password=pass 0 0

natty_samba_permanent_2

 

Restart your computer and the file should be mounted at the mount point you specified automatically.

 

natty_samba_permanent_3

 

If you don’t have full access to the mounted shares, open the fstab file and add the below options to the line.

uid=username,gid=groupname

natty_samba_permanent_4

 

 

My personal option is shown below:

//HOSTNAME/shares /MountPoint smbfs username=richard,password=pass,uid=richard,gid=richard 0 0

Replace user with your Windows’ username and pass with your Windows’ password. Also replace and reference of ‘richard’ to your own Ubuntu account.

 

Enjoy!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: