国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 系統(tǒng) > CentOS > 正文

CentOS6.5安裝samba

2024-06-28 14:32:33
字體:
供稿:網(wǎng)友

1. 安裝軟件

yum install samba samba-client samba-swat

2. 修改samba配置文件

vi /etc/samba/smb.conf

修改

workgroup = hitachigst.globalnetbios name = hitachigst.global[all]comment = Public Stuffpath = /home/lbl/allavailable = yesbrowseable = yespublic = yeswritable = yesPRintable = nowrite list = lblguest ok = no

3. 添加samba用戶

touch /etc/samba/smbpasswdsmbpasswd -a lbl

4. 修改共享目錄的訪問權(quán)限

chmod 777 -R /home/lbl/allchcon -R -t samba_share_t /home/lbl/all#編輯/etc/rc.local,末尾加入/usr/bin/chcon -t samba_share_t /home/lbl/all

5. 修改iptables開放samba端口

vi /etc/sysconfig/iptables

在“ACCEPT”下一行加入

-A INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT-A 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

重啟服務(wù)

/etc/rc.d/init.d/iptables restart

6. 重啟samba服務(wù)

/etc/init.d/smb restart/etc/init.d/nmb restart

  


發(fā)表評論 共有條評論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 青川县| 金秀| 甘南县| 洞头县| 吉安市| 浦县| 沙河市| 大竹县| 泰和县| 鹤岗市| 彭山县| 唐山市| 临洮县| 内乡县| 武冈市| 儋州市| 海晏县| 桓台县| 太白县| 湛江市| 郁南县| 平山县| 红安县| 肃宁县| 肇庆市| 辰溪县| 昌黎县| 峨山| 彰武县| 南康市| 汉川市| 夏邑县| 大悟县| 泉州市| 鄢陵县| 曲沃县| 梁河县| 繁昌县| 梁平县| 宁陵县| 靖宇县|