1. Install cifs-utils package
1 |
sudo apt-get install cifs-utils |
2. Create a file for authentication information with root account
1 2 3 |
yli@yli-VirtualBox ~ $ su Password: yli-VirtualBox yli # less ~/.servercred |
3. In authentication file, please specify username, password and domain.
1 2 3 |
username=xxxx password=yyyy domain=zzzz |
4. Modify /etc/fstab file and to mount the samba at start-up.
Add following line to the end.
1 |
//server/path /mnt/local_mount_dir cifs credentials=/root/.servercred,iocharset=utf8,file_mode=0777,dir_mode=0777 0 |
then use “mount -a” to mount immediately.