Archive for April, 2012

Powershell: Get all Groupnames and Memberships

April 12, 2012 8 comments

In this post I will show you how to get all group names and memberships of a specific OU in Active Directory. If you want to get all memberships and display groupnames with Powershell you can use the combination of Get-QADGroup and Get-QADGroupmember of the Quest AD Cmdlets.

#List groupnames with memberships from a specific OU

#Define OU:
$SecurityGroups = "Joris.Local/Groups/Security"

Get-QADGroup -SearchRoot $SecurityGroups -SizeLimit 0 | Foreach-Object{
       $group = $_
       Get-QADGroupmember $group -sizelimit 0 | `
       select @{n="GroupName";e={$group}},samaccountname,firstname,lastname
} | export-Csv  C:\Powershell\ADGroups\SecurityGroups.csv

First you get all Groups of a specific OU with Get-QADGroup and then pipe the results to a Foreach-Object with the combination of Get-QADGroupmeber which loops through all Groups to retrieve the users of each AD Group. I get the required output with the select-object
cmdlet and I make use of a hashtable ” @{n=”GroupName”;e={$group}}”. There are two pairs – first one with a key “Name” that specifies the name of the resulting property(groupname) and second one with the key “Expression” that specifies the value of the property which is in this case just the group name we have gotten from Get-QADGroup. I made also an export to a CSV File.

Categories: Powershell

SCCM 2012: Required SQL Server Collation

April 2, 2012 16 comments

I had yet another SQL error at the Prerequisite Check page regarding the required SQL Server Collation:

Configuration Manager required that you configure your SQL Server instance and Configuration Manager site database (if already present) to use the SQL_Latin1_General_CP1_CI_AS collation, unless you are using a Chinese operation system and require GB18030 support.

The server collation is specified during SQL Server installation.  So this means that you need to re-install the SQL server or rebuild your database.  The server collation acts as the default collation for all system databases that are installed with the instance of SQL Server, and also any newly created user databases.

It is highly recommend to do this only on a SQL which is not in use by any other application!

Navigate to your SQL setup folder or DVD where the setup.exe is located and execute the underneath command:


More info:

Categories: SCCM 2007 / 2012

SCCM 2012: Setup is unable to connect to SQL Server

April 2, 2012 10 comments

There is a big change that you catch the underneath error during your SCCM 2012 deployment:

 Setup is unable to connect to SQL Server with the connection information provided. Verify the following:

– The SQL Server and instance names are entered correctly
– The specified SQL Server instance is not configured to use dynamic ports
– If a firewall is enabled on the SQL Server, inbout rules exist to allow connections to the correct ports
– The account used to run Setup has permissions to connect to the specified SQL server instance

Open the “SQL Server Configuration manager” and Naviagte to The Protocols of your SQL Instance in the “SQL Server Network Configuration”

Enable “Named Pipes” and “TCP/IP”

Restart the SQL Service Instance within the SQL Server Services:

This seems to be a common issue during the SCCM 2012 setup:  Windows-Noobs

Verify also that you are running the one of the supported  SQL versions:

– SQL Server 2008 SP2 with Cumulative Update 9
– SQL Server 2008 SP3 with Cumulative Update 4
– SQL Server 2008 R2 with SP1 and Cumulative Update 4


Categories: SCCM 2007 / 2012