Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I need to automatically mount a network share to a mount point whenever I log into my computer. Currenlty I am doing this manually by running through my history to run the command again and again.

sudo mount IPADDRESS:/path/todir path/to/local/mount/point

How can this be done?

share|improve this question
    
What sort of share is this? NFS? Samba? –  Oli Apr 3 '12 at 9:03
    
NFS. The directory is on a ubuntu installation. –  rsman Apr 3 '12 at 11:25

2 Answers 2

You should read this

But the key part is this

Add a line at the bottom of your /etc/fstab file that specifies:

//$SERVER/$SHARE $MOUNTPOINT $FS_TYPE credentials=$SMB_CREDENTIALS,uid=$UID,gid=$GID

share|improve this answer

Just add a line to your /etc/fstab file. For fstab entries, you can use the auto or noauto option to let your system mount the remote filesystem automatically on boot or on mount -a, or to prohibit automounting. AFAIK auto is the default.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.