samba.md
How to use samba to share your folder in linux
Share your folder in linux by samba
Install samba
I use ubuntu taking an example.
apt-get install samba
Edit file smb.conf
vim this file
vim /etc/samba/smb.conf
Add some configuration in smb.conf
[vmware-samba-share]comment = my sharing spacepath = /home/witt/work/valid users = wittcreate mask = 0777directory mask = 0777public = yeswritable = yesavailable = yesbrowseable = yessecurity = shareguest ok = yes
Add a valid user
sudo smbpasswd -a [your valid users]
sudo smbpasswd -a witt
Restart the samba server
sudo systemctl restart smbd
Login in the sharing folder
Linux
sudo smbclient -U [shared username]
Style 1 - smbclient
apt-get install smbclient
sudo smbclient -U witt //192.168.18.131/work
Style 2 - mount
apt-get install cifs-utils
sudo mount -t cifs -o username='[shared-username]',password='[your password]',dir_mode=0777,file_mode=0777 //192.168.18.131/work /mnt/share-work/
Windows
Input the following elements on the address box of windows explorer
\\192.168.18.131\work
you can also mount it into your computer as an remote disk.
That all.Thank your reading.