Install samba in CentOS 6.5
1. install the software yum install samba-client samba-swat 2. modify the samba configuration file vi/etc/samba/smb. conf modify workgroup = hitachigst. globalnetbios name = hitachigst. global [all] comment = Public Stuffpath =/home/lbl/allavailable = yesbrowseable = yespublic = yeswritable = yesprintable = nowrite list = lblguest OK = no 3. add samba user touch/etc/samba/smbpasswdsmbpasswd-a lbl 4. modify the access permission of the shared directory chcon-R-t samba_assist_t/home/lbl/allchmod 777-R/home/lbl/all 5. modify iptables open samba port vi/etc/sysconfig/iptables add-a input-m state -- state NEW-m tcp-p tcp -- dport 22-j ACCEPT-A under "ACCEPT "INPUT-m state -- state NEW-m tcp-p tcp -- dport 139-j ACCEPT-A INPUT-m state -- state NEW-m tcp-p tcp -- dport 445-j ACCEPT-A INPUT- p udp-m udp -- dport 137-j ACCEPT-A INPUT-p udp-m udp -- dport 138-j ACCEPT Restart service/etc/rc. d/init. d/iptables restart 6. restart the samba service/etc/init. d/smb restart/etc/init. d/nmb restart