写在前面
设置共享这些就不写了,主要写一下这次遇到的问题
1,共享后,本地局域网IP:192.168.2.2 能正常打开共享目录
2,zerotier后,虚拟的IP:192.168.192.215 ,WEB能正常访问
3,IP:192.168.192.215 SMB不能访问共享目录
过程
首先以为是防火墙问题,一通设置后,把原来跑不满千兆原因反而找到了,也算因额外收获吧!
接着从共享找原因
先看对比以前能正常使用的模板
[global]
netbios name = |NAME|
display charset = |CHARSET|
interfaces = |INTERFACES|
server string = |DESCRIPTION|
unix charset = |CHARSET|
workgroup = |WORKGROUP|
bind interfaces only = no
deadtime = 30
enable core files = no
# invalid users = root
local master = no
map to guest = Bad User
max protocol = SMB2
min receivefile size = 16384
null passwords = yes
security = user
passdb backend = smbpasswd
smb passwd file = /etc/samba/smbpasswd
use sendfile = yes
现在固件代码
[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 = yes
map to guest = Bad User
max protocol = SMB2
min receivefile size = 16384
null passwords = yes
passdb backend = smbpasswd
security = user
smb passwd file = /etc/samba/smbpasswd
socket options = TCP_NODELAY IPTOS_LOWDELAY
use sendfile = yes
通过对比
以现能正常使用的模板与不能访问的新模板有2行代码不一样
bind interfaces only = no
local master = no
新模板还多了行代码
socket options = TCP_NODELAY IPTOS_LOWDELAY
解决办法
只要把bind interfaces only = yes 改成no就可以了
模板是在哪里查看?