Finding out IP Number.
Matthew Carpenter
matt
Mon May 17 11:39:16 PDT 2004
If they run Samba or are a Windows box, I always do the following:
# nmblookup -A <ip-address>
Actually, not helping you but to disperse the information, here is the
actual script I use, since I run on a network with multiple WINS servers
and like to lookup using either name or IP without worrying about syntax:
~/bin/nmbcheck
--------------
#!/bin/bash
IPADDY=`echo "$*" | grep "^[0-9]*\.[0-9]*\.[0-9]*\.[0-9]*$"`
if [ .$IPADDY == . ] ; then
echo "Executing CIFS Query on HOSTNAME"
nmblookup -R -S -U <wins-server> $*
else
echo "Executing CIFS Query on IP Address"
nmblookup -R -U <wins-server> -A $*
fi
--------------
Try it out. It's very nice. Not only does it tell you the name of the
machine, but the workgroup/domain name and whoever is logged into it (if
it's Winblows).
-Matt
On Tue, 22 Oct 2002 08:37:53 -0500
"Ben Duncan" <bns at meta3.net> wrote:
> I need to know a users telneted/rlogin .etc ..etc.. IP on a flat
> network that does not have DNS.
>
> Any Idea how to get it?
>
> Who -l , only does a DNS resolution.
> --
> Ben Duncan Phone (601)-355-2574 Fax (601)-355-2573 Cell
> (601)-946-1220
> Business Network Solutions
> 336 Elton Road Jackson MS, 39212
> "Software is like Sex, it is better when it's free" - Linus Torvalds
>
> _______________________________________________
> Linux-users mailing list
> Linux-users at linux-sxs.org
> Unsubscribe/Suspend/Etc ->
> http://www.linux-sxs.org/mailman/listinfo/linux-users
More information about the Linux-users
mailing list