Mount SMB on Ubuntu® on boot

1970 + 1685737415

Install SMB/CIFS

sudo apt install cifs-utils
sudo mkdir /media/SharedFolder
sudo nano /etc/fstab

Inside fstab paste this line and modify the IP address, folder path, user name as localusername, user credential path:

// /media/SharedFolder cifs rw,_netdev,users,uid=localusername,credentials=/home/localusername/.smbcredentials 0 0

Make file for user details

nano ~/.smbcredentials

Type in your network share's credentials by replacing networkusername and networkuserpassword:


Make your credentials accessible by current user only

chmod 600 ~/.smbcredentials

More posts