PowerShell for Windows Admins:

February, 2012


February 18, 2012  4:58 AM

LDAP filter issues

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

I have been using LDAP filters a lot recently. One thing that can cause subtle errors that are difficult to track down are LDAP filters.

As an example consider this code which discovers all objects with the creatorSID attribute set and then resolves that SID to discover the user who...

February 15, 2012  12:23 PM

My first script

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

PowerShell is an incredible tool with the ability to automate a load of your mundane tasks. A frequent question is where do I start?

Now the obvious starting point is to learn a little PowerShell – PowerShell in a Month of Lunches is ideal if you are a complete beginner...


February 13, 2012  12:16 PM

String replacement

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

A question of the forum involved changing the file path for a folder. The original path was like this

$folder = "C:\FolderName\NextFolder\ThirdFolder"

 

The first attempt uses the –replace operator

PS> $newfolder = $folder -replace...


February 12, 2012  4:31 AM

Domain Controller Service Health–revisited

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

A bit more digging as a follow up to the previous post shows that the NTDS service is shown when PowerShell is run with elevated privileges i.e. Run as Administrator. That means we want to be able to test is PowerShell is running in that mode

The test-dcservicehealth function becomes

...


February 11, 2012  2:36 PM

Domain Controller Service Health

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

The correct functioning of our AD domains depends on the services that are running on our domain controllers

A quick test for the services that could affect AD

function test-dcServiceHealth 
			
		


February 11, 2012  5:53 AM

Changing folder creation date

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

A question on the forum asked about setting creation date on folders after they have been copied to match the source folder.

I created a source folder with three folders and modified the creation dates

Set-ItemProperty -Path c:\testsource\folder1 -Name CreationTime -Value...


February 11, 2012  5:09 AM

Tools for administering Active Directory

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

It was pointed out in a comment that in my series of posts on administering Active Directory (started with Bookmark and Share     0 Comments     RSS Feed     Email a friend


February 9, 2012  1:48 PM

February PowerShell group meeting–SQL server and PowerShell

Richard Siddaway Richard Siddaway Profile: Richard Siddaway


When: Tuesday, Feb 28, 2012 7:30 PM (GMT)


Where: Virtual

*~*~*~*~*~*~*~*~*~*

SQL Server forms the core of many of our systems - how can we administer and access it using PowerShell

Notes


Richard Siddaway has invited you to attend an...


February 6, 2012  6:28 AM

Inbound replication

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

Continuing round the MicrosoftActiveDirectory namespace we get to the MSAD_ReplCursor class which provides inbound replication state information about all replicas of a Naming Context

 

Get-WmiObject -Namespace root\MicrosoftActiveDirectory -Class MSAD_ReplCursor  | ...


February 6, 2012  5:00 AM

Automating replication testing

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

Building on the recent post about testing replication I though a bit more automation was needed. Lets create a function to discover the domain controllers

function get-DomainControllerNames 
				
								
				 

				Bookmark and Share

				   

				 0 Comments
				   

				  RSS Feed
				   

				  Email a friend

			
			
		


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: