新手配samba问题解决
开发机环境:freebsd
1、添加samba用户
smbpasswd 路径:/usr/local/etc/smbpasswd
sudo smbpasswd -a eoiioe //添加的用户名必须是系统内已有的用户名,此时会提示输入密码
sudo smbpasswd -e eoiioe //激活用户
2、修改/usr/local/etc/smb.conf配置用户信息
添加用户响应信息
[eoiioe]
comment = eoiioe's Services //此处写提示语
path = /home/eoiioe
public = no
valid users = eoiioe
writable = yes
create mask =0755
guest ok = no
3、重启samba服务
sudo samba.sh stop
系统提示
“Waiting for PIDS: 2038, 2038,2038, ....”
wait了很长时间,于是
sudo kill -9 2038
显示“smbd already running? (pid=2059).”
此时只是kill掉了nmbd, smbd还在running,此时还应该kill -9 2059
最后 sudo samba.sh start
samba配置完成
samba.sh 文件 内容
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
2
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
3
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
4
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
5
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
6
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
7
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
8
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
9
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
10
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
11
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
12
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
13
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
14
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
15
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
16
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
17
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
18
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
19
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
20
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
21
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
22
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
23
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
24
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
25
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
26
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
27
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
28
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
29
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
30
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
centos 下相对简单
1.启动 Samba 服务。
# chkconfig smb on ← 设置 Samba 自启动
# service smb start ← 启动Samba服务
Starting SMB services: [ OK ]
Starting NMB services: [ OK ]
# smbpasswd -a root ← 将系统用户 root 加入到 Samba 用户数据库
New SMB password: ← 输入该用户用于登录 Samba 的密码
Retype new SMB password: ← 再次确认输入该密码
Added user centospub.
# smbpasswd -e root ← 激活该用户
2.配置Samba
通过编辑 /etc/samba/smb.conf 让将要被共享的目录拥有充分的读写权限属性。
3.修改完smb.conf文件后一定要重启sam服务
# servcie smb restart ---重启smb服务