DFS node status checking

  • Thread starter =?ISO-8859-2?Q?Ji=F8=ED_Jany=B9ka?=
  • Start date
?

=?ISO-8859-2?Q?Ji=F8=ED_Jany=B9ka?=

Hi,

I run the attached vbs code (from MS Script Center) to check DFSnodes
properties in my domain DFS root. Properties are displayed OK, I'm
focused especially on State/Status of each node. The 'State' for each
node is '0' (OK), 'Status' is empty.
When I make any of DFSnodes inaccessible (for ex. by shutting down
the server hosting that node's only DFStarget) and run the script again,
State/Status show always the same values, like if the node was still
ONLINE, but it is in fact OFFLINE! (easy to confirm in GUI DFSconsole)
I don't understand what's wrong, or what are the Status/States
properties good for then :-(
Or is there another script way of realtime checking DFSnode's state ?

Thanx for any help
George

----------------------------------------------------------------
strComputer = "Our_DC"
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")

Set colDfsNodes = objWMIService.ExecQuery _
("Select * from Win32_DFSNode")

For each objDfsNode in colDfsNodes
Wscript.Echo "Caption: " & objDfsNode.Caption
Wscript.Echo "Description: " & objDfsNode.Description
Wscript.Echo "Install Date: " & objDfsNode.InstallDate
Wscript.Echo "Name: " & objDfsNode.Name
Wscript.Echo "Root: " & objDfsNode.Root
Wscript.Echo "State: " & objDfsNode.State
Wscript.Echo "Status: " & objDfsNode.Status
Wscript.Echo "Timeout: " & objDfsNode.Timeout
Next
-------------------------------------------------------------------
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top