首页 > 学院 > 开发设计 > 正文

samba服务器搭建共享文件夹

2019-11-08 03:03:16
字体:
来源:转载
供稿:网友

1、第一步安装:sudo apt-get install samba

                              sudo apt-get install smbclient 

      可能会出现dpkg was interrupted, you must manually run 'dpkg --configure -a' to correct the PRoblem问题,

  这里先按提示输入:dpkg --configure -a

  然后使用:sudo apt-get update 

          sudo apt-get upgrade

  即可解决

2、配置共享文件

   sudo vi /etc/samba/smb.conf 编辑smb.conf 文件   在配置文件的最末尾加上:   [share]   comment = Shared Folder require passWord   path = /home/share  //共享文件夹目录   public = yes   writable = yes   valid users = share    //访问的用户名   create mask = 0777   directory mask = 0777   force user = nobody   force group = nogroup   available = yes   browseable = yes   保存后重新启动samba:sudo /etc/init.d/samba restart3、设置用户密码   sudo smbpasswd -a hzkljy 接着俺提示输入密码   New SMB password:   Retype new SMB password:      


发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表