Hi,
Some time ago, I wrote a small script based on some information on one
of the Samba lists, which let me figure out which machine a user was
logged in on. The script was this:-
# smbfind: watch for someone to log in
PATH=/bin:/usr/bin
case $# in
0)      echo 'Usage: smbfind <nt_login>' 1>&2; exit 1
esac
nmblookup -S "${1}#03" | awk '/<00> -  /{print $1}'
This has recently stopped working, and I'm at a loss as to why - node
status queries seem to simply fail on my network these days. I'm using
Samba 2.0.7, and I've no idea what changed to stop the script from
working. I'd appreciate any ideas...
Mike.
On Tue, 25 Jul 2000, Mike Brodbelt wrote:> Hi, > > Some time ago, I wrote a small script based on some information on one > of the Samba lists, which let me figure out which machine a user was > logged in on. The script was this:- > > # smbfind: watch for someone to log in > > PATH=/bin:/usr/bin > > case $# in > 0) echo 'Usage: smbfind <nt_login>' 1>&2; exit 1 > esac > > nmblookup -S "${1}#03" | awk '/<00> - /{print $1}' > > > This has recently stopped working, and I'm at a loss as to why - node > status queries seem to simply fail on my network these days. I'm using > Samba 2.0.7, and I've no idea what changed to stop the script from > working. I'd appreciate any ideas...Maybe I'm missing some detail here, but can't you get that information from the smbstatus program? Or would your script allow you to do lookups even if the machine did not have any samba shares mounted? Andy
I have two samba servers, 2.2.6, on my domain. They are both visible in Network Neighborhood. However, running nmblookup returns different results: [root@centauri /]# nmblookup '*' querying * on 192.168.0.255 192.168.0.231 *<00> 192.168.0.7 *<00> 192.168.0.5 *<00> 192.168.0.10 *<00> 192.168.0.14 *<00> 192.168.0.8 *<00> 192.168.0.6 *<00> 192.168.0.9 *<00> 192.168.0.16 *<00> [root@thor /]# nmblookup '*' querying * on 192.168.0.255 192.168.0.10 *<00> Thor only gets a response from thor, but centauri gets a response from all nodes, including thor. Why? -------------- next part -------------- HTML attachment scrubbed and removed