A command-line tool for managing the browser

The Browser network service, which you see through its Network Neighborhood interface, must have seemed a good idea at one time, but sometimes its unreliability makes Browser seem more like a bug than a feature. Whenever Browser gives a user fits, the network administrator needs to try to figure out why it's misbehaving. But what tools does an administrator have to monitor Browser's behavior? In a word, the answer is Browstat.

Browstat, a command-line tool, tells you a lot about a network's browsers. For example, it can tell you which machine is a workgroup's browse master, list all servers that are candidates to be the browse master, and list browsing statistics for the workgroup. Browstat's one annoying feature is that it requires that you do some typing to identify transport protocols.

As you might know, Microsoft network OSs elect a separate browse master for each workgroup and network transport protocol on a subnet. To find out which system is the browse master for a workgroup named Fishes on TCP/IP, you could type the command

browstat getmaster netbt_el90x1 fishes

The getmaster option tells Browstat to report the browse master for the Fishes workgroup. (Browstat commands aren't case sensitive.) The purpose of the netbt_el90x1 part of the command string isn't as obvious. This part of the command is Windows NT-ese for "the NetBIOS over TCP/IP (NetBT) stack running on your 3Com Etherlink 3C905B-TX NIC." You must type the name correctly; Browstat won't help you if you don't. Fortunately, you can use the Net config rdr command to easily find the name of your system's transport protocols. On an NT 4.0 system, the transport name will resemble \Device\NetBT_El90x1 (you can drop the \Device\ part). On a Windows 2000 system, the device names look like \Device\NetBT_Tcpip_\{418786EA-FAFE-443C-A9Fb-DC0CE26D87E5\}, probably because of Win2K's Plug and Play (PnP) nature. After you've typed the transport name a few times, you'll wonder, as I did, why Browstat's author didn't either include wildcard support for transport names or drop the need to type the transport for single-protocol environments.

Browstat has a number of options.

browstat status -v

reports the name of the master and backup browsers and lists the number and type of servers in the workgroup. The workgroup name is optional; if you don't include it, Browstat reports on your workgroup.

browstat view   name>

shows all servers that are potential browse masters as well as the OS that they claim to run (Samba servers commonly fib about their OS version to ensure that they're browse masters). This command also reports the characteristics Browser uses to grade servers' fitness to act as a browse master during an election. Again, the workgroup name is optional. For example,

browstat view netbtel90x1

will list the potential servers running TCP/IP on my workstation's workgroup.

browstat getpdc

returns the name of the PDC for the specified domain (the domain name is optional).

browstat getmaster

reports the browse master for the specified transport and workgroup--­information that you can also get from the browstat stats command.

browstat stats \\

asks the specified system (or your local machine, if you don't specify a system) to report its Browser statistics (e.g., how many elections the system has seen, how many times a server has announced itself).

Browstat is small (42KB), requires no installation, and provides a quick-and-dirty look at browsing on a network. Add it to your toolkit; Browstat earns its keep.