我有一台Ubuntu 11.04计算机,有两个vms:debian和
windows xp.每个vm还具有仅主机连接,因此我可以从主机看到它们,而无需设置端口转发.
所有机器都可以使用ip地址互相ping通,但linux机器(ubuntu主机和debian guest)不能通过名称ping Windows XP,只能使用’nmblookup’等工具或在nautilus中输入’smb:// hostname’. Windows XP可以按名称ping所有计算机.
当然我必须缺少smb.conf中的一些配置.这是我正在使用的当前版本:
[global] workgroup = WORKGROUP server string = %h server (Samba,Ubuntu) name resolve order = bcast host lmhosts wins printing = cups printcap name = cups printcap cache time = 750 cups options = raw use client driver = yes map to guest = Bad User usershare allow guests = Yes usershare max shares = 100 usershare owner only = False
任何帮助将不胜感激.
解决方法
这不仅仅是桑巴!
您需要安装Winbind,它还会安装您正在寻找所需的名称服务交换机库.如果您的系统上存在/ lib / libnss_winbind,您需要做的就是修改/etc/nsswitch.cfg中的主机行:
hosts files dns winbind
关键是winbind线.这告诉Linux使用Windows系统进行名称解析.