I'm trying to mount some smb shares on bootup using fstab on a Kbuntu box. Here are the steps I using to accomplish this:sudo mkdir /mnt/MyShareThen I add this line to my fstab file://myserver/myshare /mnt/MyShare smbfs username=user1,password=password1 0 0However after restarting the /mnt/MyShare folder is removed. If i re-create this directory and run sudo mount -a, everything works fine. Can browse the share. But when I reboot, /mnt/MyShare is gone.Any hints as to what I am doing wrong?
/mnt Directories Disappearing
networking;file sharing
I don't think you should be using /mnt in this way. According to the Filesystem Hierarchy Standard;This directory is provided so that the system administrator may temporarily mount a filesystem as needed. The content of this directory is a local issue and should not affect the manner in which any program is run.This directory must not be used by installation programs: a suitable temporary directory not in use by the system must be used instead.A permanent mount, specified in fstab, should go somewhere else.Note that current Ubuntu systems use subdirectories in /media for removable disks, and /mnt is always left as an empty directory for manual, one-off mounts. I suspect that Ubuntu is enforcing this, or at least facilitating it, by deleting and recreating it on each startup.I suggest you create a new root-level directory /network and put your permanent network mounts in there. You may be able to get away with putting them in /media, but it's probably better to leave that for use by the system. Using /network as the prefix nicely labels yours as network drives.