1.安装samba,在软件包中查找samba,选择
luci-i18n-samba-zh-cn 安装,这个是中文界面的设置,会自动安装需要的依赖,包括samba的服务器端
然后在系统中的界面保存一下,就可以看到服务中增加了‘网络共享’选项

2.设置
LUCI更新后,会出现设置界面,不过我喜欢直接改设置文件,文件位于‘/etc/samba/smb.conf.template’
一下是我的设置:
[global]
netbios name = |NAME|
display charset = |CHARSET|
interfaces = |INTERFACES|
server string = |DESCRIPTION|
unix charset = |CHARSET|
workgroup = |WORKGROUP|
bind interfaces only = yes
deadtime = 30
enable core files = no
#invalid users = root
local master = no
map to guest = Bad user
max protocol = SMB
min receivefile size = 16384
null passwords = yes
passdb backend = smbpasswd
security = user
#smb passwd file = /etc/samba/smbpasswd
use sendfile = yes

以上,我已经修改过了,重点要修改的设置是:
max protocol = SMB
原来的设置,应该是SMB2,WIN10并不支持,修改成这样就可以正常连接了,
另外要注意的是,添加共享文件夹时如图:

允许用户留空,并勾选‘可浏览’‘允许匿名’即可不用输入用户名就可以访问共享,