Microsft Windows Network Discovery Process

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Guys,
I have seen sometimes that when I browse "Microsoft Windows Network" I
have a bunch of domains even though I have never added my machine to any of
those domains (in fact I have not added my machine to any domain for that
matter). Also, i do not see the domains in the drop down list at the login
prompt...So, how did Windows learn about these?

At other times, I know there is a domain on my network and i can ping the
DC but Microsoft Windows Network does not show this domain? why? How is
Windows working here?

Let me know

Thanks,
Neelay
 
Guys,
I have seen sometimes that when I browse "Microsoft Windows Network" I
have a bunch of domains even though I have never added my machine to any of
those domains (in fact I have not added my machine to any domain for that
matter). Also, i do not see the domains in the drop down list at the login
prompt...So, how did Windows learn about these?

At other times, I know there is a domain on my network and i can ping the
DC but Microsoft Windows Network does not show this domain? why? How is
Windows working here?

Let me know

Thanks,
Neelay

Neelay,

When you look at "Microsoft Windows Network", you are looking at the output from
the browser. The browser for your workgroup inventories all "servers" in your
workgroup, plus it receives broadcasts from the browsers for other domains and
workgroups and workgroups on your network.

The browser is a fascinating subsystem, and there are many reasons why you might
not see some domains or servers in "Microsoft Windows Network", at various
times. I've written a short article, and included a link to a Microsoft article
with more technical depth.
<http://nitecruzr.blogspot.com/2005/04/nt-browser-or-why-cant-i-always-see.html>
http://nitecruzr.blogspot.com/2005/04/nt-browser-or-why-cant-i-always-see.html
 
Thanks Chuck!
I had the "Computer Browser" service stopped. I started it and then it
started working. I think also Windows firewall was blocking it.

But, now I stumbled on another problem which I cannot seem to solve:
In my program when I use WNetOpenEnum() and WNetEnumResource() I get the
exact output as if I was browsing the "Microsoft Windows Network" but if I
use the more specific API to browse the domain
DWORD dwErr = ::NetServerEnum(NULL, 100,
(LPBYTE*) &bufServerData,
MAX_PREFERRED_LENGTH,
&dwEntriesRead,
&dwTotalMachinesVisible,
SV_TYPE_ALL,
"test-domain",
&dwResumeHandle);
I always get ERROR_NO_BROWSER_SERVERS_FOUND or 6118 as the return code.

What am I doing wrong? My machine is in its own workgroup and not added to
any domain and uses a different DNS than that from "test-domain". If I can
see and browse "test-domain" in Microsoft Windows Network, shouldn't I be
able to enumerate it through NetServerEnum() as well?

What am I doing wrong?

Let me know

Thanks,
Neelay
 
Thanks Chuck!
I had the "Computer Browser" service stopped. I started it and then it
started working. I think also Windows firewall was blocking it.

But, now I stumbled on another problem which I cannot seem to solve:
In my program when I use WNetOpenEnum() and WNetEnumResource() I get the
exact output as if I was browsing the "Microsoft Windows Network" but if I
use the more specific API to browse the domain
DWORD dwErr = ::NetServerEnum(NULL, 100,
(LPBYTE*) &bufServerData,
MAX_PREFERRED_LENGTH,
&dwEntriesRead,
&dwTotalMachinesVisible,
SV_TYPE_ALL,
"test-domain",
&dwResumeHandle);
I always get ERROR_NO_BROWSER_SERVERS_FOUND or 6118 as the return code.

What am I doing wrong? My machine is in its own workgroup and not added to
any domain and uses a different DNS than that from "test-domain". If I can
see and browse "test-domain" in Microsoft Windows Network, shouldn't I be
able to enumerate it through NetServerEnum() as well?

What am I doing wrong?

Let me know

Thanks,
Neelay

Hi Neelay,

Well, to start, you're top posting. Try bottom posting - type below, after my
reply.
<http://nitecruzr.blogspot.com/2005/05/how-to-post-on-usenet-and-encourage.html#TopPosting>
http://nitecruzr.blogspot.com/2005/05/how-to-post-on-usenet-and-encourage.html#TopPosting

Now then, a 6118 is well known here.
The list of servers for this workgroup is not currently available.

What do you get when you run "browstat status"?
<http://nitecruzr.blogspot.com/2005/05/browstat-utility-from-microsoft.html>
http://nitecruzr.blogspot.com/2005/05/browstat-utility-from-microsoft.html

Which computer did you start the browser on? If your computer is in its own
workgroup, it needs to run the browser. Each workgroup has to have a browser,
so it can see:
1) The servers in that workgroup.
2) The other workgroups.
 
Chuck said:
Hi Neelay,

Well, to start, you're top posting. Try bottom posting - type below, after my
reply.
<http://nitecruzr.blogspot.com/2005/05/how-to-post-on-usenet-and-encourage.html#TopPosting>
http://nitecruzr.blogspot.com/2005/05/how-to-post-on-usenet-and-encourage.html#TopPosting

Now then, a 6118 is well known here.
The list of servers for this workgroup is not currently available.

What do you get when you run "browstat status"?
<http://nitecruzr.blogspot.com/2005/05/browstat-utility-from-microsoft.html>
http://nitecruzr.blogspot.com/2005/05/browstat-utility-from-microsoft.html

Which computer did you start the browser on? If your computer is in its own
workgroup, it needs to run the browser. Each workgroup has to have a browser,
so it can see:
1) The servers in that workgroup.
2) The other workgroups.

Sorry about that. I did not realize and will bottom post from now on.

Here is the scenario:
I have one domain setup (test-domain). There are no machines added to it so
far.
I have my computer on which I started the browser service. My computer is in
its own workgroup and it is the only machine in that workgroup. Running
browstat on my machine gives:

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}
There are 1 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}
There are 1 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}
There are 5 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}

When I run it on the DC of test-domain I get a similar output which does say
Browsing is active and master browser is test-server

I also did not understand why browstat breaks the output by Device? Is that
per network card?

Currently, I can see the "test-domain" in "My Network Places" and the
WNetOpenEnum() and WNetEnumResource() do enumerate the "test-domain".

Let me know

Neelay
 
Neelay said:
Sorry about that. I did not realize and will bottom post from now on.

Here is the scenario:
I have one domain setup (test-domain). There are no machines added to it so
far.
I have my computer on which I started the browser service. My computer is in
its own workgroup and it is the only machine in that workgroup. Running
browstat on my machine gives:

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}
There are 1 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}
There are 1 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}
There are 5 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}

When I run it on the DC of test-domain I get a similar output which does say
Browsing is active and master browser is test-server

I also did not understand why browstat breaks the output by Device? Is that
per network card?

Currently, I can see the "test-domain" in "My Network Places" and the
WNetOpenEnum() and WNetEnumResource() do enumerate the "test-domain".

Let me know

Neelay

Going back one step:

I am trying to enumerate machines in a domain when I am not in any domain
But I can see the domain controller. I see that the WNet...() functions can
get it but they get the complete list ...I am trying to use NetServerEnum()
API's to get only the specific details...Anything wrong in the approach OR
any other way to do the same?

Neelay
 
Sorry about that. I did not realize and will bottom post from now on.

Here is the scenario:
I have one domain setup (test-domain). There are no machines added to it so
far.
I have my computer on which I started the browser service. My computer is in
its own workgroup and it is the only machine in that workgroup. Running
browstat on my machine gives:

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}
There are 1 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{C8AFA130-899A-4AC1-9AE4-F8B80A87A5EB}

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}
There are 1 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{F93C30A2-3D60-48E6-BBB4-D57F0D292EAF}

Status for domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}
Browsing is active on domain.
Master browser name is: machine-1
Master browser is running build 2600
1 backup servers retrieved from master machine-1
\\machine-1
There are 1 servers in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}
There are 5 domains in domain WRKGROUP on transport
\Device\NetBT_Tcpip_{FDAAA64D-7219-4ED9-B0BC-274FF8925328}

When I run it on the DC of test-domain I get a similar output which does say
Browsing is active and master browser is test-server

I also did not understand why browstat breaks the output by Device? Is that
per network card?

Currently, I can see the "test-domain" in "My Network Places" and the
WNetOpenEnum() and WNetEnumResource() do enumerate the "test-domain".

Let me know

Neelay

That's better. You've got multiple transports there though.

Let's look at "ipconfig /all", "net config server", and "net config workstation"
next please. That may give us some answers to your questions.
 
Chuck said:
That's better. You've got multiple transports there though.

Let's look at "ipconfig /all", "net config server", and "net config workstation"
next please. That may give us some answers to your questions.

Sorry Chuck, for replying late...The problem was the domain name paramater
(second last) arguments needs to be UNICODE. The function prototype uses
LMSTR as the data type, hitting F12 on which resolves to char* but MSDN seems
to say that only the Unicode version of NetServerEnum() is available on
WinXP. I made it Unicode and it worked fine.

But, I have now run into another issue...I am using NetUseAdd() and specify
the connection parameters in USE_INFO_2 structure. This is what I am
seeing...there are 4 members of the structure which are used for the
connection: remote path, user name, password and domain. I am trying to
connect to a DC using a domain account for the same...If I use the following
as connection parameters:

Remote-path: \\DC\ipc$
User name: administrator
Password: testpass
Domain:DomainDoesNotExist

and call NetUseAdd(), it actually succeeds! There is no domain named as
"DomainDoesNotExist" However there is a "administrator" account on the DC
with the password "testpass"...If I do a NetUseEnum() now, it returns the
exact same values(except the password) back...What is happening here?

Also, MSDN says "domain" is the domain of the remote resource....Does that
mean it is not the user domain? and if I want to use a domain user account to
connect I should specify the username as <domain name>\<username> format?

I don't get this...I am trying to connect with invalid domain credentials
but it suceeds...

Let me know

Thanks,
Neelay
 
Back
Top