Finding Windows boxes by their netbios name

Another tip I found – this one allows you to ping hunt for a Windows box from Ubuntu without having to change the hosts file to manually create the IP lookups.

  1. Install smbfs/cifs:
    apt-get install smbfs
  2. Edit your nsswitch file
    sudo nano /etc/nsswitch.conf

    Search through the file and look for the line that looks something like:

    hosts: files dns

    and add “wins” to the end of the line so it looks something like this:
    hosts: files wins dns
    NB: “wins” MUST come before “dns” if you are using the openDNS service.

  3. Install winbind
    apt-get install winbind

Done.  🙂  Ping away!


Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s