ubuntu18.04 set up Samba server

Samba is mainly used in the LAN environment, linux windows system and file sharing system, which set up the following steps:

  1.  sudo su
  2.    Create a shared directory mkdir / home / semie / share
  3.    Change the directory permissions chmod 777 / home / semie / share
  4.    install Samba相关  sudo apt-get install samba samba-common
  5.    add a user and set a password sudo smbpasswd -a semie semie as my user name    
  6.    edit the samba conf sudo nano /etc/samba/smb.conf finally add in the configuration file as follows
    [share]
    comment = share folder
    browseable = yes
    path = /home/semie/share
    create mask = 0700
    directory mask = 0700
    valid users = semie
    force user = semie
    force group = semie
    public = yes
    available = yes
    writable = yes
  7.   restart service        sudo service smbd restart 
  8.   windows next visit \\ 192.168.0.105

        

Guess you like

Origin www.cnblogs.com/semie/p/12634982.html