Dealing with reboot pending clients in Configuration Manager 2012

Guess most of you are struggling with troubleshooting software update compliance and installing applications in Configuration Manager 2012. What I have found, is that clients in a reboot pending state often is the root cause to the problems. In previous posts I have described how you can use tools like Coretech Shutdown Utility to automatically restart computers that has been in a reboot pending state for X number of hours/days.  The information about the reboot pending state is stored in WMI Root\ccm\ClientSDK namespace as illustrated here with the Coretech WMI & PowerShell explorer: Identify reboot state using PowerShell Launch PowerShell [...]

By |2014-01-19T17:14:28+01:00januar 19th, 2014|Configuration Manager (SCCM), General info|19 Comments

NIC 2014 – Deck and links from my ConfigMgr Community session

Once again, to all who has ever contributed to the community – We salute you – keep on working and know that you are making a difference for 1000’s of IT pros “out there”. Download deck Just some of the community tools: Infrastructure and Client Management Johan Arwidmark ConfigMgr R2 Hydration Kit - http://www.deploymentresearch.com/Research/tabid/62/EntryId/113/The-Hydration-Kit-for-ConfigMgr-2012-R2-is-available-for-download.aspx Mikael Nyström System center Hydration Kit - http://deploymentbunny.com/2013/01/04/hydration-kit-v3-is-out/ Startup Script -http://blog.configmgrftw.com/?page_id=349 Right Click tools - http://psrightclicktools.codeplex.com/releases/view/104529 Right click took - http://myitforum.com/myitforumwp/2012/09/21/sccm-rctools/ Client Center - https://sccmclictr.codeplex.com/ David’s Inventory Script PowerShell - http://www.david-obrien.net/2013/06/20/huge-powershell-inventory-script-for-configmgr-2012/ Garth’s Inventory Script vbSript - http://www.enhansoft.com/pages/downloads.aspx CM12Healthcheck toolkit - https://www.rflsystems.co.uk/sccm-2012-r2-healthcheck-toolkit/ ConfigMgr 2012 Registration Request - [...]

Error enrolling Apple MAC OS X 10.9.1 client in Configuration Manager 2012 R2

Been spending a few good hours trying to get the super enterprise friendly operating system Apple Mac OS X 10.9.1 (In Denmark we really use irony a lot!). There a some good blog post on how to configure MAC support that I advice you all to follow and if you are working with latest version Maverick 10.9.1 I strongly advise you to read this blog post from Yvette -http://blogs.technet.com/b/configmgrteam/archive/2013/12/16/mac-os-x-10-9-support-for-sc-2012-config-manager-clients.aspx Here is what I did, the error I saw and how I fixed it. Configuring Apple MAC support according to Technet Enrolled the client on OS X version 10.9.1 (which is [...]

By |2014-01-05T12:26:00+01:00januar 5th, 2014|Configuration Manager (SCCM)|1 Kommentar

How to add Configuration Manager Distribution Point Remotely with PowerShell

If you are trying to add a Configuration Manager Distribution Point remotely you may end up with issue: WARNING: The self-signed certificate could not be created successfully Validation of input parameters failed. Cannot Continue Code example Invoke-Command -ScriptBlock { #Step 1 Import-Module $env:SMS_ADMIN_UI_PATH.Replace("\bin\i386","\bin\configurationmanager.psd1") #Step 2 $SiteCode = Get-PSDrive -PSProvider CMSITE #Step 3 Set-Location "$($SiteCode.Name):\" #Step 4 Add-CMDistributionPoint -SiteSystemServerName TestServer.corp.viamonstra.com -SiteCode $SiteCode.Name ` -ClientConnectionType Intranet -MinimumFreeSpaceMB 50 -PrimaryContentLibraryLocation Automatic ` -SecondaryContentLibraryLocation Automatic -PrimaryPackageShareLocation Automatic -EnablePxeSupport ` -SecondaryPackageShareLocation Automatic -CertificateExpirationTimeUtc ((Get-Date).AddYears(100)) -ErrorAction STOP } -ComputerName CM01.corp.viamonstra.com If you take same code and run it locally on your Primary Site Server, then it [...]

Error in policypv.log after upgrade to ConfigMgr 2012 R2

Ran into an interesting error today after updating ConfigMgr 2012 SP1 to ConfigMgr 2012 R2. The hierarchy is a CAS and 3 primary sites (but I do not believe that the error is releated to having multiple primary sites). *** insert DepPolicyAssignment (PADBID, PolicyAssignmentID, PolicyID, DepPADBID, DepPolicyAssignmentID, DepPolicyID, IsTombstoned, LastUpdateTime) values (67118015, N'{ccff0eb1-db33-49c3-9dd3-c704c3a638f8}', N'PS120012-PS10013D-6F6BCC28', 67689129, N'{060a13d7-7ed8-46ae-927f-4420b0fefdcb}', N'DEP-PS120012-PS1002B1-6F6BCC28', 0, GetUTCDate()) *** [23000][547][Microsoft][SQL Server Native Client 11.0][SQL Server]The INSERT statement conflicted with the FOREIGN KEY constraint "DepPolicyAssignment_1_FK". The conflict occurred in database "CM_PS1", table "dbo.PolicyAssignment", column 'PADBID'. Failed to create policy and policy assignment based on package PS1002B1, program * and offer [...]

By |2013-11-12T20:32:56+01:00november 12th, 2013|Configuration Manager (SCCM)|1 Kommentar

Modify Maintenance Windows with Configuration Manager cmdlets

One of the new features in Configuration Manager 2012 R2 is that you can configure Maintenance Windows only for Software Updates We can configure all these new stuff with ConfigMgr cmdlets also :) #Import ConfigMgr PSH Module Import-Module $env:SMS_ADMIN_UI_PATH.Replace("\bin\i386","\bin\configurationmanager.psd1") #Get the CMSITE SiteCode $SiteCode = Get-PSDrive -PSProvider CMSITE # Change the connection context Set-Location "$($SiteCode.Name):\" #Apply MW only to Task Sequence $Collection = Get-CMDeviceCollection -Name "MW 2 - LOB Servers" Set-CMMaintenanceWindow -CollectionID $Collection.CollectionID -ApplyToTaskSequenceOnly -Name "TEST 2" #Apply MW only to Software Updates $Collection = Get-CMDeviceCollection -Name "MW 2 - LOB Servers" Set-CMMaintenanceWindow -CollectionID $Collection.CollectionID -ApplyToSoftwareUpdateOnly -Name "TEST 2" #Modify [...]

By |2013-10-18T09:28:43+01:00oktober 18th, 2013|Configuration Manager (SCCM), Powershell, Scripting & Development|Kommentarer lukket til Modify Maintenance Windows with Configuration Manager cmdlets

Create Maintenance Windows with Configuration Manager cmdlets

Configuration Manager 2012 R2 PowerShell module contains now New-CMMaintenanceWindow cmdlet :) #Import ConfigMgr PSH Module Import-Module $env:SMS_ADMIN_UI_PATH.Replace("\bin\i386","\bin\configurationmanager.psd1") #Get the CMSITE SiteCode $SiteCode = Get-PSDrive -PSProvider CMSITE # Change the connection context Set-Location "$($SiteCode.Name):\" #Occurs day 3 of every 2 months effective 10/17/2013 1:00 PM $Schedule = New-CMSchedule -DurationCount 1 -DurationInterval Hours -RecurCount 2 -DayOfMonth 3 -Start ([Datetime]"13:00") $Collection = Get-CMDeviceCollection -Name "MW 1 - Windows Servers" New-CMMaintenanceWindow -CollectionID $Collection.CollectionID -Schedule $Schedule -Name "TEST 1" #Occurs the First Thursday of every 2 months effective 10/17/2013 1:00 PM $Schedule = New-CMSchedule -DurationCount 1 -DurationInterval Hours -RecurCount 2 -DayOfWeek 4 -WeekOrder First -Start [...]

New cmdlets in Configuration Manager 2012 R2

Here are the new cmdlets in Configuration Manager 2012 R2. Now we have totally 560 cmdlets Copy-CMClientAuthCertificateProfileConfigurationItem Copy-CMRemoteConnectionProfileConfigurationItem Copy-CMTrustedRootCertificateProfileConfigurationItem Copy-CMVpnProfileConfigurationItem Copy-CMWirelessProfileConfigurationItem Get-CMAccessLicense Get-CMClientAuthCertificateProfileConfigurationItem Get-CMClientOperations Get-CMDeviceVariable Get-CMInitialModifiableSecuredCategory Get-CMMaintenanceWindow Get-CMRemoteConnectionProfileConfigurationItem Get-CMRemoteConnectionProfileConfigurationItemXmlDefinition Get-CMTrustedRootCertificateProfileConfigurationItem Get-CMVhd Get-CMVpnProfileConfigurationItem Get-CMWirelessProfileConfigurationItem Invoke-CMClientNotification Invoke-CMContentValidation Invoke-CMDeviceRetire Invoke-CMDeviceWipe Move-CMObject New-CMClientAuthCertificateProfileConfigurationItem New-CMDeviceVariable New-CMMaintenanceWindow New-CMRemoteConnectionProfileConfigurationItem New-CMTrustedRootCertificateProfileConfigurationItem New-CMVhd New-CMVpnProfileConfigurationItem New-CMWirelessProfileConfigurationItem Publish-CMPrestageContentTaskSequence Remove-CMClientAuthCertificateProfileConfigurationItem Remove-CMContentDistribution Remove-CMDeviceVariable Remove-CMMaintenanceWindow Remove-CMRemoteConnectionProfileConfigurationItem Remove-CMTrustedRootCertificateProfileConfigurationItem Remove-CMVhd Remove-CMVpnProfileConfigurationItem Remove-CMWirelessProfileConfigurationItem Set-CMAssignedSite Set-CMClientAuthCertificateProfileConfigurationItem Set-CMDeviceOwnership Set-CMDeviceVariable Set-CMMaintenanceWindow Set-CMRemoteConnectionProfileConfigurationItem Set-CMTrustedRootCertificateProfileConfigurationItem Set-CMVhd Set-CMVpnProfileConfigurationItem Set-CMWirelessProfileConfigurationItem Get-CMInitModifiableSecuredCategory

Configure Coretech Application E-Mail Approval tool to always use the fallback mail

As you can read in this blog post – we recently released a new version of our E-Mail approval tool. One of the new features in the tool is to configure a fallback address. You can either specify a Manager as the approver or a fallback group like Servicedesk. In order to configure the tool to always use the fallback address follow these steps: Open C:\Program Files (x86)\coretech\Coretech Application Approval Service Edit the CM_AppReqListen.exe.config.xml file Find the Section in called <setting name="UseManager" serializeAs="String"> Change <value>True</value> to <value>False</value> Save and close the file Restart the Coretech CM Application Request Listener service

By |2013-10-15T14:50:00+01:00oktober 15th, 2013|Configuration Manager (SCCM), General info, Tools|12 Comments

Quick and Dirty – Build Configuration Manager 2012 Admin Console Extensions automatically

I just finished one PowerShell script that queries all the Admin Console XML files and it creates automatically Admin Console Extension. You can use this script to locate correct place for you right-click tool. There are totally 655 Console GUIDs. You can download the script from here  

By |2013-10-15T13:27:20+01:00oktober 15th, 2013|Configuration Manager (SCCM), Powershell, Scripting & Development|Kommentarer lukket til Quick and Dirty – Build Configuration Manager 2012 Admin Console Extensions automatically

Can you combine Get-WmiObject with ConfigMgr cmdlets? Yes, you can

Last week I discovered that you can create a Refresh Schedule with New-CMSchedule cmdlet and then you can easily use that object with Get-WmiObject cmdlet to query and modify for example Device Collection Refresh Schedule. Import-Module $env:SMS_ADMIN_UI_PATH.Replace("\bin\i386","\bin\configurationmanager.psd1") $SiteCode = Get-PSDrive -PSProvider CMSITE Set-Location "$($SiteCode.Name):\" $Schedule = New-CMSchedule -RecurCount 2 -RecurInterval Days $Collection = Get-WmiObject -Namespace "Root\SMS\Site_PS1" -Class SMS_Collection -Filter "Name='Windows 8.1 OSD'" $Collection.RefreshType = 2 $Collection.RefreshSchedule = $Schedule.psbase.ManagedObject $Collection.Put() You can create the Device Collection with correct Refresh Schedule but Set-CMDeviceCollection cmdlet does not allow to change the Refresh Schedule. $Schedule = New-CMSchedule -RecurCount 2 -RecurInterval Days New-CMDeviceCollection -Name "Windows [...]

By |2013-10-14T10:28:47+01:00oktober 14th, 2013|Configuration Manager (SCCM), Powershell, Scripting & Development|Kommentarer lukket til Can you combine Get-WmiObject with ConfigMgr cmdlets? Yes, you can

Coretech Application E-Mail Approval Tool

A little over a year ago we released the first version of our Application E-mail approval utility. Ever since our first release we have received lots of positive feedback and ideas to new features. Most of the ideas are implemented in this new release. Thanks for all the feedback and please keep it coming. This blog post will explain how you can install CTAA (Coretech Application Approval tool) – Download Additional blog posts will follow and explain how you can customize the tool. Why the need for this utility The idea with this utility is to integrate a “real approval [...]

By |2017-09-13T11:42:26+01:00oktober 11th, 2013|Configuration Manager (SCCM), General info, Tools|168 Comments

Configuration Items and Baselines, Using Scripts (Powershell Example)

In the previous blog post i used file and registry settings for my Configuration Item. Another way to define your Configuration Item setting are scripts. And in CM2012 we have 3 scripting options: JScript PowerShell VBScript (The same goes for the use of scripts in Detection Methods when we create Application Deployment Types.)   Since the new colour fashion in scripting today is blue, i guess the popular choice would be PowerShell. On a serious note – PowerShell is now everywhere, just ask my buddy Kaido Järvemets. And in this example i will be checking for a setting on the [...]

Configuration Items and Baselines, Example: SCEP Client Compliance

This example will show you a way to get compliance data from your clients regarding the System Center Endpoint Protection 2012 Client. Now, I'm aware that we through CM2012 reports and console views already have good tools to monitor the client states in regard to SCEP - but lets say you have another antimalware product and would like some compliance info from the clients inserted into CM2012 that you then can use to create reports etc. The principals are the same. First of all you will need to create configuration Items in the CM2012 Console - these items will hold [...]

Case of the missing Hardware Inventory

I recently played around with adding registry data to SCCM Hardware Inventory using RegKeyToMof, but during the tests I ended up with a big problem, no clients were delivering any hardware inventory at all. The problem quickly spread to all clients so I started the oh-so well known journey of troubleshooting. First let’s look at the symptoms of the issue. The Resource Explorer shows no inventory data for clients Client Actions does not show the Hardware Inventory Action The PolicyEvaluator.log file contains errors A Bad MOF file is generated on the client Things that did not work I tried replacing [...]

By |2013-10-01T20:57:39+01:00oktober 1st, 2013|Configuration Manager (SCCM)|10 Comments

The Coretech Software Update Management Tool

As demonstrated @TechEd in Australia and New Zealand our latest free tool is the Software Update Management Tool. The sole purpose of the tool is to automate the creation of software update deployments. The benefits of using the tool are: All deployments will be using the same naming standard. the naming standard is WRK/SRV + Year + Value of Month WRK 2013 09. The names are automatically generated using the actual month. You save time by automating the process. You eliminate errors by automating the process. All deployments are created as disabled deployments. This gives you complete control over the [...]

By |2013-09-20T13:45:06+01:00september 20th, 2013|Configuration Manager (SCCM)|30 Comments

Slides and scripts from the System Center 2012 Configuration Manager R2 Advanced Infrastructure session #WCL307

As promised in the session here are the scripts and links that I was using. Video and slides available on Channel 9: http://channel9.msdn.com/Events/TechEd/NewZealand/2013/WCL307 Blog: Management Point replica https://blog.ctglobalservices.com/kea/working-with-database-replicas-on-your-management-point/ http://myitforum.com/myitforumwp/2012/08/06/next-sccm-guru-webcast-features-brian-mason/   SQL Scripts: Index and Statistics Maintenance: http://ola.hallengren.com/sql-server-index-and-statistics-maintenance.html Pre-creating the SQL database: Download   My generel SQL recommendations: https://blog.ctglobalservices.com/kea/system-center-2012-configuration-manager-sql-recommendations/   Planning for Cloud based Distribution Points http://technet.microsoft.com/en-us/library/jj613909.aspx   Getting started with PowerShell: https://blog.ctglobalservices.com/kea/coretech-wmi-powershell-explorer-part-ii/

By |2013-09-11T22:24:35+01:00september 11th, 2013|Configuration Manager (SCCM), Events|2 Comments

PoshCAT 0.2 version released

I just published PoshCAT 0.2 version and the changes are as follows: · New Client Actions o Desired Configuration Manager Cycle o Application Machine Policy Cycle o Application Global Evaluation Cycle o Install ConfigMgr Client o Get App-V Client Packages o Get App-V Client Configuration o Get App-V Client Version o Enable App-V Client Package Scripts o Get ConfigMgr Client Available Applications o Get Applied Group Policies o Refresh Group Policies o Get Free Disk Space · Alternate Credentials Support – you can specify only one account · Active Directory Connector · Better error handling · Separate folder for reports [...]

Automate importing and creating driver packages in SCCM 2012 R2

  I take that you are familiar with drivers and manually creating driver categories and driver packages in Configuration Manager. Here I will show you how you can optimize the process by running a very need little PowerShell script called ImportDrivers.ps1 (main developer is Claus Codam). There are a few prerequisites that needs to be in place before the script will work. Driver source has to be 3 levels deep like this example (Make\Model\OS). The driver source is where you store the original driver packages from the vendor. You need to create a Driver packages folder (where ConfigMgr will import [...]

Building PoshCAT Part 3 – Enabling PowerShell Remoting through Group Policy for PoshCAT

You may want to read these posts before: · How to install PoshCAT · Building PoshCAT Part 1 – Create different Client Actions lists · Building PoshCAT Part 2 – Adding your own custom functions One of the most important thing you need to know before you start using PoshCAT is that it relies on PowerShell remoting. If you don’t configure PowerShell remoting on your computers, then the Client Actions will fail. In this post I will show how you can enable PowerShell remoting through Group Policy but you can also configure it manually. To enable PowerShell remoting manually you [...]

Building PoshCAT Part 2 – Adding your own custom functions

Last week I showed how you can create different Client Actions lists for different support groups in your organization and in this post I will show how you can add/create your own custom functions for PoshCAT So let’s assume that you would like to query applied Computer Group Policy objects. If you want that your custom function returns some kind of information, then it must return PSObject. Here is the function that I use in this example. This function queries only applied/enabled policies 1 Function Get-ComputerAppliedPolicies 2 { 3 $GPOPolicies = @() 4 $GPOQuery = Get-WmiObject -Namespace "ROOT\RSOP\Computer" -Class RSOP_GPLink [...]

Building PoshCAT Part 1 – Create different Client Actions lists

Last week I published our new tool PoshCAT and in the upcoming weeks I will cover different things. In this blog post I will show how to create different Client Action lists for different support groups. PoshCAT uses XML based configuration file for different Client Actions that you can execute through UI. One of the main ideas was that the tool should be customizable: · Ability to add and remove commands from UI · Ability to add your own custom actions/functions By default there are over 30 commands that are ready for use. Commands.xml configuration · TASK – Client Action [...]

By |2013-08-13T09:34:57+01:00august 13th, 2013|Configuration Manager (SCCM), Powershell, Scripting & Development|Kommentarer lukket til Building PoshCAT Part 1 – Create different Client Actions lists

How to install PoshCAT

1. Download and Unzip PoshCAT_v0.2.zip 2. Right-Click Start-PoshCAT.ps1, WorkerFunctions.ps1, SharedFunctions.ps1 and Commands.xml and select properties. 3. Unblock the files if needed and click OK. 4. Right-click Start-PoshCAT.ps1 and choose Run with PowerShell 5. If you don’t have administrative permissions, this message will be shown.   Enjoy!