Date: Mon, 18 Feb 2008 17:53:42 +0100 From: gvm999 <gvm999@gmail.com> To: freebsd-ports@freebsd.org Subject: Netbios name resolving for ping and other software (rdesktop,..) Message-ID: <a1ed72c0802180853vf9bc745m686ebdd55e252e74@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
I want to be able to resolve Netbios names without the use of /etc/hosts nor a DNS server. However I cant get it to work. I want to be able to use the netbios name for example with CUPS, rdesktop, ssh. CUPS for example uses the netbios name with its shared printers. If another computer lists shared printer then the netbios name is used, which cannot be resolved, leaving it not working. So I wanted to have transparent name resolving. I had this working previously on Linux (debian) I thought I could fix this with /etc/nsswitch.conf but without any luck. Does someone knows what I am doing wrong? I have been searching for this for a few days :s I have a samba configured as wins server and nmbd is also running. Resolving with nmblookup works fine... however does not with for example PING. This is my config. My smb.conf: Code: [global] workgroup = MYGROUP server string = Samba Server interfaces = 192.168.1.11/24 log file = /usr/local/samba/var/log.%m max log size = 50 name resolve order = wins hosts lmhosts bcast printcap name = printcap os level = 33 preferred master = Yes domain master = Yes wins support = Yes hosts allow = 192.168.1., 192.168.100., 127. [homes] comment = Home Directories [printers] comment = All Printers path = /usr/spool/samba printable = Yes browseable = No [share] comment = Torrent Share path = /home/gvm/downloaded read only = No [torrent-watch] comment = Torrent Share path = /home/gvm/watch-torrent read only = No When I do smbclient -L vpn-gateway: Code: Anonymous login successful Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.0.23c] Sharename Type Comment --------- ---- ------- homes Disk Home Directories share Disk Torrent Share torrent-watch Disk Torrent Share IPC$ IPC IPC Service (Samba Server) Anonymous login successful Domain=[MYGROUP] OS=[Unix] Server=[Samba 3.0.23c] Server Comment --------- ------- VPN-GATEWAY Samba Server Workgroup Master --------- ------- MYGROUP VPN-GATEWAY Still if I want to ping I get unknown host. Cat /etc/nsswitch.conf Code: group: compat group_compat: nis hosts: files wins winbind bcast dns networks: files passwd: compat passwd_compat: nis shells: files nmblookup vpn-gateway: Code: nmblookup vpn-gateway querying vpn-gateway on 192.168.1.255192.168.1.11 vpn-gateway<00> What I dont understand are the contents of /etc/host.conf They dont have wins or broadcast (bcast) in it. But it says that it is automatically generated. How can I regenerate that file? cat /etc/host.conf Code: # Auto-generated from nsswitch.conf, do not edit hosts dns Maybe it is just normal that it only has those 2 entrys.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?a1ed72c0802180853vf9bc745m686ebdd55e252e74>