testparm的完整输出
[root@localhost ~]# testparm
Load smb config files from /etc/samba/smb.conf
Processing section "[homes]"
Processing section "[printers]"
Processing section "[csilv]"
Processing section "[fringe]"
Loaded services file OK.
Server role: ROLE_STANDALONE
Press enter to see a dump of your service definitions
你的samba服务重启了没? 另外liuhongming这个用户加入smbpasswd了吗?
age 发表于 2011-6-16 16:03
你说的我都做过了 可是还是不行
age 于 2011-06-16 16:03:02发表:
引用:
[fringe]
comment = this is fringe
path = /share/fringe
hosts deny = ALL
valid users=liuhongming
hosts allow = 192.168.1.6 192.168.1.5
public = no
...
liuhongming 发表于 2011-6-16 15:53
你的samba服务重启了没? 另外liuhongming这个用户加入smbpasswd了吗?
liuhongming 于 2011-06-16 15:53:56发表:
[fringe]
comment = this is fringe
path = /share/fringe
hosts deny = ALL
valid users=liuhongming
hosts allow = 192.168.1.6 192.168.1.5
public = no
write list=liuhongming
我加了valid users=liuhongming 还是不行啊
age 于 2011-06-16 15:53:50发表:
引用:
[fringe]
comment = this is fringe
path = /share/fringe
hosts deny = ALL
hosts allow = 192.168.1.6 192.168.1.5
public = no
write list=liuhongming
...
liuhongming 发表于 2011-6-16 15:49
果然, 你没有valid user
没指定用户,samba怎么知道登录的是liuhongming而不是其它用户呢
liuhongming 于 2011-06-16 15:49:13发表:
[fringe]
comment = this is fringe
path = /share/fringe
hosts deny = ALL
hosts allow = 192.168.1.6 192.168.1.5
public = no
write list=liuhongming
liuhongming 于 2011-06-20 08:31:51发表:
高手,还是没有办法能够解决吗??困扰中
397778823 于 2011-06-19 21:53:43发表:
有smb用户么
deepwhite 于 2011-06-18 18:53:32发表:
我没仔细看,还以为 client 是 windows 呢。
age 于 2011-06-18 11:43:40发表:
感觉没多大区别,
无论security是share还是user
只要在[share]里指明了valid user= <> 就可以对用户进行认证
现在的问题, 用户可以正常登录进去, 只是没有W权限
pili818 于 2011-06-18 11:31:23发表:
高手高手
deepwhite 于 2011-06-18 07:29:31发表:
[i=s] 本帖最后由 deepwhite 于 2011-6-18 07:32 编辑 [/i]
把 security 改成 user 试试:把下面的代码放在你的 smb.conf 的开始:
[code]#============ Global Settings ===========
[global]
workgroup = MYGROUP
server string = Samba Server
security = user
log file = /var/log/samba/log.%m
max log size = 50
[/code]记得用 smbpasswd -a liuhongming 来向 SAMBA 添加用户。
liuhongming 于 2011-06-17 16:39:43发表:
testparm的完整输出
[root@localhost ~]# testparm
Load smb config files from /etc/samba/smb.conf
Processing section "[homes]"
Processing section "[printers]"
Processing section "[csilv]"
Processing section "[fringe]"
Loaded services file OK.
Server role: ROLE_STANDALONE
Press enter to see a dump of your service definitions
[global]
workgroup = MYGROUP
server string = FileServer
security = SHARE
passdb backend = tdbsam
username map = /etc/samba/smbusers
cups options = raw
[homes]
comment = Home Directories
read only = No
browseable = No
[printers]
comment = All Printers
path = /var/spool/samba
printable = Yes
browseable = No
[csilv]
comment = this is share csi
path = /share/csi
guest ok = Yes
hosts allow = 192.168.1.3
hosts deny = ALL
[fringe]
comment = this is fringe
path = /share/fringe
valid users = liuhongming
write list = liuhongming
hosts allow = 192.168.1.6, 192.168.1.5
hosts deny = ALL
smb.conf的内容
[fringe]
comment = this is fringe
path = /share/fringe
valid users = liuhongming
hosts deny = ALL
hosts allow = 192.168.1.6 192.168.1.5
public = no
write list = liuhongming
deepwhite 于 2011-06-17 16:34:00发表:
贴出 testparm 的完整输出和 /etc/samba/smb.conf 的完整内容看看?
cc_cop 于 2011-06-17 12:49:40发表:
顶下
liuhongming 于 2011-06-17 09:40:06发表:
{:2_94:}
qq403971094 于 2011-06-17 09:26:11发表:
顶下
cnbtoo 于 2011-06-17 08:59:01发表:
路过
liuhongming 于 2011-06-17 08:33:39发表:
非常感谢大家的帮助 你们说的我都做了 我在前面已经粘贴出来了,大家再帮我想想吧!谢谢!
jrs0335 于 2011-06-17 08:24:15发表:
要设置用户组,让这个组对这个目录有些的权限,然后把你要设置的用户归到这个组,然后才可以有写的权限的。不是在samba里面设置了就可以了。要双向设置的。
小小ac米兰 于 2011-06-16 23:09:28发表:
初来乍到,请多多指教
fujiefujie 于 2011-06-16 22:25:05发表:
用 testparm 检查一下配置文件
testparm 看看有没有提示配置出错
fujiefujie 于 2011-06-16 20:49:34发表:
[i=s] 本帖最后由 fujiefujie 于 2011-6-16 20:54 编辑 [/i]
你的配置项有问题 hosts allow ; hosts deny不能同时出现。况且你那个host deny 在前 拒绝所有.
hosts allow/deny 是全局配置项里的吧
fsxlp101 于 2011-06-16 18:25:40发表:
writable= yes 它只是开启写的权限, 当你给用户赋予权限的时候,你不开启权限,当然不能创建了。 就是个选项,就像vsftp里的 userlist表一样
age 于 2011-06-16 16:41:57发表:
一切正常....
我再想想原因吧
liuhongming 于 2011-06-16 16:37:32发表:
我的客户端是linux 红帽子5.4的
[root@localhost ~]# umount //192.168.1.2/fringe /mnt/
This utility only unmounts cifs filesystems.
This utility only unmounts cifs filesystems.
[root@localhost ~]# mount //192.168.1.2/fringe /mnt/ -o username=liuhongming
Password:
[root@localhost ~]# cd /mnt
[root@localhost mnt]# ll
总计 0
drwxr-xr-x 2 root root 0 06-15 14:01 111
drwxr-xr-x 2 root root 0 06-16 09:43 111111123
drwxr-xr-x 2 root root 0 06-16 09:43 11111112322
drwxr-xr-x 2 root root 0 06-16 09:51 1111111232212
drwxr-xr-x 3 root root 0 06-16 09:52 11111112322123
drwxr-xr-x 2 root root 0 06-16 09:22 112
drwxr-xrwx 2 root root 0 06-16 09:03 113
[root@localhost mnt]#
age 于 2011-06-16 16:31:55发表:
就是你访问那个文件夹时, 应该会让你输入帐号:密码, 这就是liuhongming:passwd
有这步吗?
liuhongming 于 2011-06-16 16:24:25发表:
通过samba验证 这是啥意思 不是很明白 我在客户端能够通过liuhongming进行共享 那就应该没有问题啊
现在writable没问题 可是这个就很麻烦
age 于 2011-06-16 16:21:47发表:
你的liuhongming能通过samba的验证吗?
liuhongming 于 2011-06-16 16:21:44发表:
你以前设置过这些东西吗
liuhongming 于 2011-06-16 16:18:52发表:
[root@localhost ~]# cd /share
[root@localhost share]# ll
总计 20
drwxr-xr-x 5 root root 4096 06-15 14:27 csi
drwxrwxrwx 9 liuhongming liuhongming 4096 06-16 09:51 fringe
-rw-r--r-- 1 root root 0 06-15 09:19 smb.conf
这个权限已经最高了 我觉得还是别的问题 要不我不可能把每个文件都弄成 777吧
agh353272297 于 2011-06-16 16:18:33发表:
想学呢。 在工作中慢慢学习。
age 于 2011-06-16 16:16:27发表:
[i=s] 本帖最后由 age 于 2011-6-16 16:17 编辑 [/i]
太奇怪了, 这样权限应该都对了啊
liuhongming 于 2011-06-16 16:10:03发表:
你说的我都做过了 可是还是不行
age 于 2011-06-16 16:03:02发表:
你的samba服务重启了没? 另外liuhongming这个用户加入smbpasswd了吗?
liuhongming 于 2011-06-16 15:53:56发表:
[fringe]
comment = this is fringe
path = /share/fringe
hosts deny = ALL
valid users=liuhongming
hosts allow = 192.168.1.6 192.168.1.5
public = no
write list=liuhongming
我加了valid users=liuhongming 还是不行啊
age 于 2011-06-16 15:53:50发表:
果然, 你没有valid user
没指定用户,samba怎么知道登录的是liuhongming而不是其它用户呢
liuhongming 于 2011-06-16 15:49:13发表:
[fringe]
comment = this is fringe
path = /share/fringe
hosts deny = ALL
hosts allow = 192.168.1.6 192.168.1.5
public = no
write list=liuhongming
[root@localhost share]# ll
总计 20
drwxr-xr-x 5 root root 4096 06-15 14:27 csi
drwxrwxrwx 9 liuhongming liuhongming 4096 06-16 09:51 fringe
-rw-r--r-- 1 root root 0 06-15 09:19 smb.conf
你看看 我给权限已经很多了 但是还是没有写的权限
age 于 2011-06-16 15:35:22发表:
突然想起来一点, 你用vlaid user = 指定用户了吗?
只有write list的话, samba是没法识别登录用户的, 自然也就无效了
liuhongming 于 2011-06-16 13:29:17发表:
有啥办法解决吗???各位大虾!
age 于 2011-06-16 10:37:03发表:
很奇怪的问题, 不知道怎么回事,
从功能上说, writeable=yes相当于把write list设为所有用户
对于write list设置的用户, 它自然享有write权限
很古怪