一.问题描述
windows用户登录连接始终不能在共享盘里创建文件。
无论在samba服务配置了writable = yes valid users =指定用户 等等一系列配置,文件也chmod 777都不行。被折磨了一下午。
二.解决方法
关闭SElinux可以解决:
vim /etc/selinux/config
把 SELINUX=enforcing 注释掉:#SELINUX=enforcing ,
然后新加一行为:SELINUX=disabled
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded. #SELINUX=enforcing SELINUX=disabled # SELINUXTYPE= can take one of these two values: # targeted - Targeted processes are protected,
# minimum - Modification of targeted policy. Only selected processes are protected.
# mls - Multi Level Security protection. SELINUXTYPE=targeted
:wq保存。
shutdown -r now 重启服务器。