转自:http://www.cnblogs.com/phinecos/archive/2009/06/06/1497717.htmlhtml
一. samba的安装:windows
sudo apt-get insall samba
sudo apt-get install smbfs服务器
二. 建立共享目录:session
mkdir /home/phinecos/share
sodu chmod 777 /home/phinecos/share测试
三. 建立Samba配置文件:rest
1. 保存现有的配置文件htm
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf.bakblog
2. 修改现配置文件ip
sudo gedit /etc/samba/smb.confget
在smb.conf最后添加
[share]
path = /home/phinecos/share
available = yes
browsealbe = yes
public = yes
writable = yes
四. 建立samba账户
sudo touch /etc/samba/smbpasswd
sudo smbpasswd -a phinecos
而后会要求你输入samba账户的密码
[若是没有第四步,当你登陆时会提示 session setup failed: NT_STATUS_LOGON_FAILURE]
五. 重启samba服务器
sudo /etc/init.d/samba restart
六. 测试
smbclient -L //localhost/share
七,使用
能够到windows下输入ip使用了,在文件夹处输入 "\\" + "Ubuntu机器的ip或主机名" + "\\" + "share"
标签: Linux