yum install samba smbfs -y
useradd -s /sbin/nologin username1 smbpasswd -a username1
mkdir -p /data/samba # 修改权限为777,权限交给samba管理 chmod 777 /data/samba
vi /etc/samba/smb.conf
[username1] comment = username1 path = /data/samba public = no valid users = @username1 write list = username1 printable = no
/etc/init.d/smb start