PowerShell for Windows Admins

Sep 3 2011   1:31PM GMT

Logging options

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

With 24 logging options to choose from its difficult to keep track of them. We already have the data in a ash table so lets just display it

function get-logsettingoptions{             
PROCESS{            
              
 1..$logtype.Count |            
 foreach {            
  $logtype["$_"]            
 }            
            
}#process             
END{}#end            
            
<# 
.SYNOPSIS
Displays logging options

.DESCRIPTION
Displays logging options

.EXAMPLE
get-logsettingoptions

#>            
            
}

A simple loop through the hash table and we get this display

1 Knowledge Consistency Checker

2 Security Events

3 ExDS Interface Events

4 MAPI Interface Events

5 Replication Events

6 Garbage Collection

7 Internal Configuration

8 Directory Access

9 Internal Processing

10 Performance Counters

11 Initialization/Termination

12 Service Control

13 Name Resolution

14 Backup

15 Field Engineering

16 LDAP Interface Events

17 Setup

18 Global Catalog

19 Inter-site Messaging

20 Group Caching

21 Linked-Value Replication

22 DS RPC Client

23 DS RPC Server

24 DS Schema

We can filter down the results using where-object or just copy the names to use when we set the logging options

 Comment on this Post

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to: