目录
1.安装和配置
bash
#1.安装
sudo apt install samba smbldap-tools
#2.配置/home目录共享
sudo vim /etc/samba/smb.conf
[home]
comment = my home
path = /home
browseable = yes
writable = yes
#3.增加用户,用户必须是系统用户,否则需要建立用户参考6
sudo smbpasswd -a lin
#4.启动
sudo service smbd restart
sudo service nmbd restart
#5.验证
#在windows系统上,文件浏览器中输入 \\IP, 会显示共享文件夹
#6.另外情况
#提示Failed to add entry for user的错误,只需增加相应的系统账号share(用户名)就可以了:
groupadd share(用户名)
useradd share(用户名) -s /sbin/nologin -d /dev/null
2.iphone无法通过samba向服务器写入照片等数据
bash
sudo vim /etc/samba/smb.conf
[global]
vfs objects = catia fruit streams_xattr
## Browsing/Identification ###
# Change this to the workgroup/NT-domain name your Samba server will part of
workgroup = WORKGROUP