Win32_PerfRawData_NTDS vbscript sample code
The foundations for Manageability in Windows is Windows Management Instrumentation (WMI; formerly WBEM) and WMI extensions for Windows Driver Model (WDM).
ActiveXperts Network Monitor provides the ability to build monitor check routines based on WMI. ActiveXperts has collected more than a hundred WMI samples. You can use these samples as a base for new check routines you can write yourself. The Win32_PerfRawData_NTDS WMI class can be used in ActiveXperts Network Monitor to monitor your servers.
Sample Code
Set objWMIService = GetObject("winmgmts:\\.\root\cimv2") Set colItems = objWMIService.ExecQuery("Select * From Win32_PerfRawData_NTDS_NTDS") For Each objItem in colItems WScript.Echo "ABANRPersec:" & objItem.ABANRPersec WScript.Echo "ABBrowsesPersec:" & objItem.ABBrowsesPersec WScript.Echo "ABClientSessions:" & objItem.ABClientSessions WScript.Echo "ABMatchesPersec:" & objItem.ABMatchesPersec WScript.Echo "ABPropertyReadsPersec:" & objItem.ABPropertyReadsPersec WScript.Echo "ABProxyLookupsPersec:" & objItem.ABProxyLookupsPersec WScript.Echo "ABSearchesPersec:" & objItem.ABSearchesPersec WScript.Echo "ATQEstimatedQueueDelay:" & objItem.ATQEstimatedQueueDelay WScript.Echo "ATQOutstandingQueuedRequests:" & objItem.ATQOutstandingQueuedRequests WScript.Echo "ATQRequestLatency:" & objItem.ATQRequestLatency WScript.Echo "ATQThreadsLDAP:" & objItem.ATQThreadsLDAP WScript.Echo "ATQThreadsOther:" & objItem.ATQThreadsOther WScript.Echo "ATQThreadsTotal:" & objItem.ATQThreadsTotal WScript.Echo "BasesearchesPersec:" & objItem.BasesearchesPersec WScript.Echo "Caption:" & objItem.Caption WScript.Echo "DatabaseaddsPersec:" & objItem.DatabaseaddsPersec WScript.Echo "DatabasedeletesPersec:" & objItem.DatabasedeletesPersec WScript.Echo "DatabasemodifysPersec:" & objItem.DatabasemodifysPersec WScript.Echo "DatabaserecyclesPersec:" & objItem.DatabaserecyclesPersec WScript.Echo "Description:" & objItem.Description WScript.Echo "DigestBindsPersec:" & objItem.DigestBindsPersec WScript.Echo "DRAHighestUSNCommittedHighpart:" & objItem.DRAHighestUSNCommittedHighpart WScript.Echo "DRAHighestUSNCommittedLowpart:" & objItem.DRAHighestUSNCommittedLowpart WScript.Echo "DRAHighestUSNIssuedHighpart:" & objItem.DRAHighestUSNIssuedHighpart WScript.Echo "DRAHighestUSNIssuedLowpart:" & objItem.DRAHighestUSNIssuedLowpart WScript.Echo "DRAInboundBytesCompressedBetweenSitesAfterCompressionPersec:" & objItem.DRAInboundBytesCompressedBetweenSitesAfterCompressionPersec WScript.Echo "DRAInboundBytesCompressedBetweenSitesAfterCompressionSinceBoot:" & objItem.DRAInboundBytesCompressedBetweenSitesAfterCompressionSinceBoot WScript.Echo "DRAInboundBytesCompressedBetweenSitesBeforeCompressionPersec:" & objItem.DRAInboundBytesCompressedBetweenSitesBeforeCompressionPersec WScript.Echo "DRAInboundBytesCompressedBetweenSitesBeforeCompressionSinceBoot:" & objItem.DRAInboundBytesCompressedBetweenSitesBeforeCompressionSinceBoot WScript.Echo "DRAInboundBytesNotCompressedWithinSitePersec:" & objItem.DRAInboundBytesNotCompressedWithinSitePersec WScript.Echo "DRAInboundBytesNotCompressedWithinSiteSinceBoot:" & objItem.DRAInboundBytesNotCompressedWithinSiteSinceBoot WScript.Echo "DRAInboundBytesTotalPersec:" & objItem.DRAInboundBytesTotalPersec WScript.Echo "DRAInboundBytesTotalSinceBoot:" & objItem.DRAInboundBytesTotalSinceBoot WScript.Echo "DRAInboundFullSyncObjectsRemaining:" & objItem.DRAInboundFullSyncObjectsRemaining WScript.Echo "DRAInboundLinkValueUpdatesRemaininginPacket:" & objItem.DRAInboundLinkValueUpdatesRemaininginPacket WScript.Echo "DRAInboundObjectsAppliedPersec:" & objItem.DRAInboundObjectsAppliedPersec WScript.Echo "DRAInboundObjectsFilteredPersec:" & objItem.DRAInboundObjectsFilteredPersec WScript.Echo "DRAInboundObjectsPersec:" & objItem.DRAInboundObjectsPersec WScript.Echo "DRAInboundObjectUpdatesRemaininginPacket:" & objItem.DRAInboundObjectUpdatesRemaininginPacket WScript.Echo "DRAInboundPropertiesAppliedPersec:" & objItem.DRAInboundPropertiesAppliedPersec WScript.Echo "DRAInboundPropertiesFilteredPersec:" & objItem.DRAInboundPropertiesFilteredPersec WScript.Echo "DRAInboundPropertiesTotalPersec:" & objItem.DRAInboundPropertiesTotalPersec WScript.Echo "DRAInboundTotalUpdatesRemaininginPacket:" & objItem.DRAInboundTotalUpdatesRemaininginPacket WScript.Echo "DRAInboundValuesDNsonlyPersec:" & objItem.DRAInboundValuesDNsonlyPersec WScript.Echo "DRAInboundValuesTotalPersec:" & objItem.DRAInboundValuesTotalPersec WScript.Echo "DRAOutboundBytesCompressedBetweenSitesAfterCompressionPersec:" & objItem.DRAOutboundBytesCompressedBetweenSitesAfterCompressionPersec WScript.Echo "DRAOutboundBytesCompressedBetweenSitesAfterCompressionSinceBoot:" & objItem.DRAOutboundBytesCompressedBetweenSitesAfterCompressionSinceBoot WScript.Echo "DRAOutboundBytesCompressedBetweenSitesBeforeCompressionPersec:" & objItem.DRAOutboundBytesCompressedBetweenSitesBeforeCompressionPersec WScript.Echo "DRAOutboundBytesCompressedBetweenSitesBeforeCompressionSinceBoot:" & objItem.DRAOutboundBytesCompressedBetweenSitesBeforeCompressionSinceBoot WScript.Echo "DRAOutboundBytesNotCompressedWithinSitePersec:" & objItem.DRAOutboundBytesNotCompressedWithinSitePersec WScript.Echo "DRAOutboundBytesNotCompressedWithinSiteSinceBoot:" & objItem.DRAOutboundBytesNotCompressedWithinSiteSinceBoot WScript.Echo "DRAOutboundBytesTotalPersec:" & objItem.DRAOutboundBytesTotalPersec WScript.Echo "DRAOutboundBytesTotalSinceBoot:" & objItem.DRAOutboundBytesTotalSinceBoot WScript.Echo "DRAOutboundObjectsFilteredPersec:" & objItem.DRAOutboundObjectsFilteredPersec WScript.Echo "DRAOutboundObjectsPersec:" & objItem.DRAOutboundObjectsPersec WScript.Echo "DRAOutboundPropertiesPersec:" & objItem.DRAOutboundPropertiesPersec WScript.Echo "DRAOutboundValuesDNsonlyPersec:" & objItem.DRAOutboundValuesDNsonlyPersec WScript.Echo "DRAOutboundValuesTotalPersec:" & objItem.DRAOutboundValuesTotalPersec WScript.Echo "DRAPendingReplicationOperations:" & objItem.DRAPendingReplicationOperations WScript.Echo "DRAPendingReplicationSynchronizations:" & objItem.DRAPendingReplicationSynchronizations WScript.Echo "DRASyncFailuresonSchemaMismatch:" & objItem.DRASyncFailuresonSchemaMismatch WScript.Echo "DRASyncRequestsMade:" & objItem.DRASyncRequestsMade WScript.Echo "DRASyncRequestsSuccessful:" & objItem.DRASyncRequestsSuccessful WScript.Echo "DRAThreadsGettingNCChanges:" & objItem.DRAThreadsGettingNCChanges WScript.Echo "DRAThreadsGettingNCChangesHoldingSemaphore:" & objItem.DRAThreadsGettingNCChangesHoldingSemaphore WScript.Echo "DSClientBindsPersec:" & objItem.DSClientBindsPersec WScript.Echo "DSClientNameTranslationsPersec:" & objItem.DSClientNameTranslationsPersec WScript.Echo "DSDirectoryReadsPersec:" & objItem.DSDirectoryReadsPersec WScript.Echo "DSDirectorySearchesPersec:" & objItem.DSDirectorySearchesPersec WScript.Echo "DSDirectoryWritesPersec:" & objItem.DSDirectoryWritesPersec WScript.Echo "DSMonitorListSize:" & objItem.DSMonitorListSize WScript.Echo "DSNameCachehitrate:" & objItem.DSNameCachehitrate WScript.Echo "DSNameCachehitrate_Base:" & objItem.DSNameCachehitrate_Base WScript.Echo "DSNotifyQueueSize:" & objItem.DSNotifyQueueSize WScript.Echo "DSPercentReadsfromDRA:" & objItem.DSPercentReadsfromDRA WScript.Echo "DSPercentReadsfromDRA_Base:" & objItem.DSPercentReadsfromDRA_Base WScript.Echo "DSPercentReadsfromKCC:" & objItem.DSPercentReadsfromKCC WScript.Echo "DSPercentReadsfromKCC_Base:" & objItem.DSPercentReadsfromKCC_Base WScript.Echo "DSPercentReadsfromLSA:" & objItem.DSPercentReadsfromLSA WScript.Echo "DSPercentReadsfromLSA_Base:" & objItem.DSPercentReadsfromLSA_Base WScript.Echo "DSPercentReadsfromNSPI:" & objItem.DSPercentReadsfromNSPI WScript.Echo "DSPercentReadsfromNSPI_Base:" & objItem.DSPercentReadsfromNSPI_Base WScript.Echo "DSPercentReadsfromNTDSAPI:" & objItem.DSPercentReadsfromNTDSAPI WScript.Echo "DSPercentReadsfromNTDSAPI_Base:" & objItem.DSPercentReadsfromNTDSAPI_Base WScript.Echo "DSPercentReadsfromSAM:" & objItem.DSPercentReadsfromSAM WScript.Echo "DSPercentReadsfromSAM_Base:" & objItem.DSPercentReadsfromSAM_Base WScript.Echo "DSPercentReadsOther:" & objItem.DSPercentReadsOther WScript.Echo "DSPercentReadsOther_Base:" & objItem.DSPercentReadsOther_Base WScript.Echo "DSPercentSearchesfromDRA:" & objItem.DSPercentSearchesfromDRA WScript.Echo "DSPercentSearchesfromDRA_Base:" & objItem.DSPercentSearchesfromDRA_Base WScript.Echo "DSPercentSearchesfromKCC:" & objItem.DSPercentSearchesfromKCC WScript.Echo "DSPercentSearchesfromKCC_Base:" & objItem.DSPercentSearchesfromKCC_Base WScript.Echo "DSPercentSearchesfromLDAP:" & objItem.DSPercentSearchesfromLDAP WScript.Echo "DSPercentSearchesfromLDAP_Base:" & objItem.DSPercentSearchesfromLDAP_Base WScript.Echo "DSPercentSearchesfromLSA:" & objItem.DSPercentSearchesfromLSA WScript.Echo "DSPercentSearchesfromLSA_Base:" & objItem.DSPercentSearchesfromLSA_Base WScript.Echo "DSPercentSearchesfromNSPI:" & objItem.DSPercentSearchesfromNSPI WScript.Echo "DSPercentSearchesfromNSPI_Base:" & objItem.DSPercentSearchesfromNSPI_Base WScript.Echo "DSPercentSearchesfromNTDSAPI:" & objItem.DSPercentSearchesfromNTDSAPI WScript.Echo "DSPercentSearchesfromNTDSAPI_Base:" & objItem.DSPercentSearchesfromNTDSAPI_Base WScript.Echo "DSPercentSearchesfromSAM:" & objItem.DSPercentSearchesfromSAM WScript.Echo "DSPercentSearchesfromSAM_Base:" & objItem.DSPercentSearchesfromSAM_Base WScript.Echo "DSPercentSearchesOther:" & objItem.DSPercentSearchesOther WScript.Echo "DSPercentSearchesOther_Base:" & objItem.DSPercentSearchesOther_Base WScript.Echo "DSPercentWritesfromDRA:" & objItem.DSPercentWritesfromDRA WScript.Echo "DSPercentWritesfromDRA_Base:" & objItem.DSPercentWritesfromDRA_Base WScript.Echo "DSPercentWritesfromKCC:" & objItem.DSPercentWritesfromKCC WScript.Echo "DSPercentWritesfromKCC_Base:" & objItem.DSPercentWritesfromKCC_Base WScript.Echo "DSPercentWritesfromLDAP:" & objItem.DSPercentWritesfromLDAP WScript.Echo "DSPercentWritesfromLDAP_Base:" & objItem.DSPercentWritesfromLDAP_Base WScript.Echo "DSPercentWritesfromLSA:" & objItem.DSPercentWritesfromLSA WScript.Echo "DSPercentWritesfromLSA_Base:" & objItem.DSPercentWritesfromLSA_Base WScript.Echo "DSPercentWritesfromNSPI:" & objItem.DSPercentWritesfromNSPI WScript.Echo "DSPercentWritesfromNSPI_Base:" & objItem.DSPercentWritesfromNSPI_Base WScript.Echo "DSPercentWritesfromNTDSAPI:" & objItem.DSPercentWritesfromNTDSAPI WScript.Echo "DSPercentWritesfromNTDSAPI_Base:" & objItem.DSPercentWritesfromNTDSAPI_Base WScript.Echo "DSPercentWritesfromSAM:" & objItem.DSPercentWritesfromSAM WScript.Echo "DSPercentWritesfromSAM_Base:" & objItem.DSPercentWritesfromSAM_Base WScript.Echo "DSPercentWritesOther:" & objItem.DSPercentWritesOther WScript.Echo "DSPercentWritesOther_Base:" & objItem.DSPercentWritesOther_Base WScript.Echo "DSSearchsuboperationsPersec:" & objItem.DSSearchsuboperationsPersec WScript.Echo "DSSecurityDescriptorPropagationsEvents:" & objItem.DSSecurityDescriptorPropagationsEvents WScript.Echo "DSSecurityDescriptorPropagatorAverageExclusionTime:" & objItem.DSSecurityDescriptorPropagatorAverageExclusionTime WScript.Echo "DSSecurityDescriptorPropagatorRuntimeQueue:" & objItem.DSSecurityDescriptorPropagatorRuntimeQueue WScript.Echo "DSSecurityDescriptorsuboperationsPersec:" & objItem.DSSecurityDescriptorsuboperationsPersec WScript.Echo "DSServerBindsPersec:" & objItem.DSServerBindsPersec WScript.Echo "DSServerNameTranslationsPersec:" & objItem.DSServerNameTranslationsPersec WScript.Echo "DSThreadsinUse:" & objItem.DSThreadsinUse WScript.Echo "ExternalBindsPersec:" & objItem.ExternalBindsPersec WScript.Echo "FastBindsPersec:" & objItem.FastBindsPersec WScript.Echo "Frequency_Object:" & objItem.Frequency_Object WScript.Echo "Frequency_PerfTime:" & objItem.Frequency_PerfTime WScript.Echo "Frequency_Sys100NS:" & objItem.Frequency_Sys100NS WScript.Echo "LDAPActiveThreads:" & objItem.LDAPActiveThreads WScript.Echo "LDAPBindTime:" & objItem.LDAPBindTime WScript.Echo "LDAPClientSessions:" & objItem.LDAPClientSessions WScript.Echo "LDAPClosedConnectionsPersec:" & objItem.LDAPClosedConnectionsPersec WScript.Echo "LDAPNewConnectionsPersec:" & objItem.LDAPNewConnectionsPersec WScript.Echo "LDAPNewSSLConnectionsPersec:" & objItem.LDAPNewSSLConnectionsPersec WScript.Echo "LDAPSearchesPersec:" & objItem.LDAPSearchesPersec WScript.Echo "LDAPSuccessfulBindsPersec:" & objItem.LDAPSuccessfulBindsPersec WScript.Echo "LDAPUDPoperationsPersec:" & objItem.LDAPUDPoperationsPersec WScript.Echo "LDAPWritesPersec:" & objItem.LDAPWritesPersec WScript.Echo "LinkValuesCleanedPersec:" & objItem.LinkValuesCleanedPersec WScript.Echo "Name:" & objItem.Name WScript.Echo "NegotiatedBindsPersec:" & objItem.NegotiatedBindsPersec WScript.Echo "NTLMBindsPersec:" & objItem.NTLMBindsPersec WScript.Echo "OnelevelsearchesPersec:" & objItem.OnelevelsearchesPersec WScript.Echo "PhantomsCleanedPersec:" & objItem.PhantomsCleanedPersec WScript.Echo "PhantomsVisitedPersec:" & objItem.PhantomsVisitedPersec WScript.Echo "SAMAccountGroupEvaluationLatency:" & objItem.SAMAccountGroupEvaluationLatency WScript.Echo "SAMDisplayInformationQueriesPersec:" & objItem.SAMDisplayInformationQueriesPersec WScript.Echo "SAMDomainLocalGroupMembershipEvaluationsPersec:" & objItem.SAMDomainLocalGroupMembershipEvaluationsPersec WScript.Echo "SAMEnumerationsPersec:" & objItem.SAMEnumerationsPersec WScript.Echo "SAMGCEvaluationsPersec:" & objItem.SAMGCEvaluationsPersec WScript.Echo "SAMGlobalGroupMembershipEvaluationsPersec:" & objItem.SAMGlobalGroupMembershipEvaluationsPersec WScript.Echo "SAMMachineCreationAttemptsPersec:" & objItem.SAMMachineCreationAttemptsPersec WScript.Echo "SAMMembershipChangesPersec:" & objItem.SAMMembershipChangesPersec WScript.Echo "SAMNonTransitiveMembershipEvaluationsPersec:" & objItem.SAMNonTransitiveMembershipEvaluationsPersec WScript.Echo "SAMPasswordChangesPersec:" & objItem.SAMPasswordChangesPersec WScript.Echo "SAMResourceGroupEvaluationLatency:" & objItem.SAMResourceGroupEvaluationLatency WScript.Echo "SAMSuccessfulComputerCreationsPersecIncludesallrequests:" & objItem.SAMSuccessfulComputerCreationsPersecIncludesallrequests WScript.Echo "SAMSuccessfulUserCreationsPersec:" & objItem.SAMSuccessfulUserCreationsPersec WScript.Echo "SAMTransitiveMembershipEvaluationsPersec:" & objItem.SAMTransitiveMembershipEvaluationsPersec WScript.Echo "SAMUniversalGroupMembershipEvaluationsPersec:" & objItem.SAMUniversalGroupMembershipEvaluationsPersec WScript.Echo "SAMUserCreationAttemptsPersec:" & objItem.SAMUserCreationAttemptsPersec WScript.Echo "SimpleBindsPersec:" & objItem.SimpleBindsPersec WScript.Echo "SubtreesearchesPersec:" & objItem.SubtreesearchesPersec WScript.Echo "Timestamp_Object:" & objItem.Timestamp_Object WScript.Echo "Timestamp_PerfTime:" & objItem.Timestamp_PerfTime WScript.Echo "Timestamp_Sys100NS:" & objItem.Timestamp_Sys100NS WScript.Echo "TombstonesGarbageCollectedPersec:" & objItem.TombstonesGarbageCollectedPersec WScript.Echo "TombstonesVisitedPersec:" & objItem.TombstonesVisitedPersec WScript.Echo "" WScript.Echo "########" WScript.Echo "" Next