教程:http://www.linuxsir.org/main/?q=node/158
http://www.linuxpk.com/80183.html
http://www.linuxeden.com/doc/20555.html
http://www.4so.net/system/linux/59388.html
http://tristones.viaspeip.com/archives/000307.html
http://www.gbunix.com/htmldata/2004_07/15/27/article_162_1.html
samba的位置:
/etc/init.d/smb
用cat命令可以查看此文件内容,可见其有start、stop、restart、reload、rhstatus等函数。
启动smb:
[root@localhost ~]# /etc/init.d/smb start
停止smb:
[root@localhost ~]# /etc/init.d/smb stop
重启smb:
[root@localhost ~]# /etc/init.d/smb restart
smbd和nmbd的位置;
[root@localhost ~]# /usr/sbin/smbd
[root@localhost ~]# /usr/sbin/nmbd
smb.conf的位置:
/etc/samba/smb.conf
===================================
在D盘下建一个文件夹Share,设置为共享。
设置主机计算机名为liukun-windows。
在虚拟机中执行smbclient -L liukun-windows -N,可以看到Windows的主机名和共享文件架Share。
在/home下新建文件夹samba。
执行 mount -t smbfs //liukun-windows/share /home/samba。
进入/home/samba可以对文件进行操作。
要始Samba生效,必须激活eth0,即ifconfig eth0 192.168.0.23 netmask 255.255.255.0,
route add default gw 192.168.0.1