locked
SCCM 2012 Client Deployment via GPO and SCCM Server 2012 RRS feed

  • Question

  • Hi,

    I have deployed the SCCM 2012 for a customer the deployment was very smooth but i got some issues in the client push out of 1000 clients there are around 400 machines which are having some problems.

    So i am planning to deploy SCCM client through GPO.

    If i deploy the SCCM Client through GPO does it reinstall the SCCM Client on the machines which already got the agent installed and working fine?

    Regards,

    Maqsood


    Maqsood Mohammed Senior Systems Engineer MCITP-Enterprise Admin & ITILv3 Foundation Certified

    Thursday, July 4, 2013 4:52 PM

Answers

  • Hi,

    First, we talk about the client default installation location,

    SCCM 2007 is %Windir%\System32\CCM\ folder or the %Windir%\SysWOW64\CCM\ folder

    SCCM 2012 is %Windir%\CCM

    Hence, the script can deploy to all computers. Then the script will check whether ccmexec.exe found in %Windir%\CCM. If yes, skip. If no, install.

    Regards,
    Hau

    Monday, July 8, 2013 11:39 AM
  • Hi,

    The problem is identified it is the configuration of the Root CA which is not configured with CDP and the CRL not published.

    We had the Offline Root CA & Enterprise Subordinate CA.

    So we have to do the following.

    1 - Bring up the Offline Root CA.

    2 - Configure the CDP & publish CRLs.

    3 - Issue a new certificate to Enterprise Subordinate CA.

    4 - Install new certificate from Root CA on Enterprise Subordinate CA.

    5 - Issue new certificate to all of the services in Domain ex. Exchange, Lync, SharePoint, etc...

    6 - Reonroll the certificate for all the clients.

    Regards,

    Maqsood


    Maqsood Mohammed Senior Systems Engineer MCITP-Enterprise Admin & ITILv3 Foundation Certified

    Wednesday, July 31, 2013 10:41 AM

All replies

  • Hi,

    Below is a vbs script that will first check whether ccmexec.exe exist in C:\Windows\CCM. If yes, skip the installation. If no, proceed the installation.

    First, copy the client folder and share the folder. Modify str_SiteCode, str_InstallString.  

    Option Explicit
    On Error Resume Next

    Dim oShell, objFSO, objFile1, objFile2, ADSysInfo, CurrentUser, wshNet, oSMSClient
    Dim sysdir, compname, username, strGroups, sitename, strDiscoverSite, strTemp, message
    Dim str_SiteAssignmentText,str_SCCMInstallLogFile ,str_InstallString, str_SiteCode

     

    Set wshNet = CreateObject("WScript.Network")
    Set ADSysInfo = CreateObject("ADSystemInfo")
    Set oShell = WScript.CreateObject("WScript.Shell")
    sysdir = oshell.ExpandEnvironmentStrings("%systemroot%")
    Set objFSO = CreateObject("Scripting.FileSystemObject")
    Const ForAppending = 8

    '/////////////////////////////////////////////////////////////////////////////////////////////////////////////
    '
    ' KEY IN YOUR PARAMETERS HERE

     

    str_SiteCode = "XXX"
    str_InstallString = "\\SERVER.domain.com\Client\ccmsetup.exe SMSSITECODE=XXX /source:\\SERVER.domain.com\client /mp:SCCMSERVER.domain.com FSP=SCCMSERVER.domain.com"

     

    '
    '
    '/////////////////////////////////////////////////////////////////////////////////////////////////////////////

        ' Check whether or not ccmexec.exe file exists, if yes return client site assignment for checking
        If objFSO.FileExists(sysdir & "\ccm\ccmexec.exe") Then
     'Wscript.echo "Agent already installed " & sitename
     Set oSMSClient = CreateObject ("Microsoft.SMS.Client")

     sitename = oSMSClient.GetAssignedSite
            If err.number=-2147221502 then
               sitename = "Not assigned"
     End If

     If sitename <> str_SiteCode  then
        'Wscript.echo "Current site assignment is " & sitename
        'strDiscoverSite = str_SiteCode
        'Call SetAssignedSite (strDiscoverSite)
        'Wscript.echo "Installing the Client now " & sitename
        oShell.Run str_InstallString
        WScript.Sleep 5000

        'strTemp = oSMSClient.GetAssignedSite
        'If LCase(strTemp) = LCase(strDiscoverSite) Then
         'message = "Successfully assigned site code to " & strDiscoverSite
        'Else
         'message = "Unable to set assigned site code to " & strDiscoverSite & ". Attempting WMI repair"
         'Call RepairWMI

        'End If


     End If

     Set oSMSClient=Nothing

        Else

             set objFile2 = objFSO.OpenTextFile(str_SCCMInstallLogFile, ForAppending, true)
             compname = oshell.ExpandEnvironmentStrings("%computername%")
             username = oshell.ExpandEnvironmentStrings("%username%")
      'Wscript.echo "Installing the Client now " & sitename
             oShell.Run str_InstallString


        End If


    Sub SetAssignedSite (SiteCode)
     'Wscript.Echo "About to assign site code to " & SiteCode
     oSMSClient.SetAssignedSite SiteCode,0
    End Sub

    Sub RepairWMI
     'Wscript.Echo "Attempting to repair WMI"
     oShell.Run "rundll32 wbemupgd, UpgradeRepository"
    End Sub

    Regards,
    Hau

    Thursday, July 4, 2013 5:56 PM
  • Hi,

    I almost Always use this excellent script from Jason Sandys, it can also install hotifxes for the client during installation and much more: http://blog.configmgrftw.com/?page_id=349

    Regards,
    Jörgen


    -- My System Center blog ccmexec.com -- Twitter @ccmexec

    Thursday, July 4, 2013 7:01 PM
  • Hi,

    Thanks for the script, i have a situation.

    I got two version of clients running in the environment.

    SCCM 2007 clients which are still connected to Old SCCM Server.

    SCCM 2012 clients which are connected to New SCCM Server.

    So i just want to enforce GPO deployment to the machines with SCCM 2007 Clients and the machines which don't have the client installed at all, please suggest.

    Regards,

    Maqsood


    Maqsood Mohammed Senior Systems Engineer MCITP-Enterprise Admin & ITILv3 Foundation Certified

    Friday, July 5, 2013 4:46 PM
  • Hi,

    First, we talk about the client default installation location,

    SCCM 2007 is %Windir%\System32\CCM\ folder or the %Windir%\SysWOW64\CCM\ folder

    SCCM 2012 is %Windir%\CCM

    Hence, the script can deploy to all computers. Then the script will check whether ccmexec.exe found in %Windir%\CCM. If yes, skip. If no, install.

    Regards,
    Hau

    Monday, July 8, 2013 11:39 AM
  • Hi,

    The problem is identified it is the configuration of the Root CA which is not configured with CDP and the CRL not published.

    We had the Offline Root CA & Enterprise Subordinate CA.

    So we have to do the following.

    1 - Bring up the Offline Root CA.

    2 - Configure the CDP & publish CRLs.

    3 - Issue a new certificate to Enterprise Subordinate CA.

    4 - Install new certificate from Root CA on Enterprise Subordinate CA.

    5 - Issue new certificate to all of the services in Domain ex. Exchange, Lync, SharePoint, etc...

    6 - Reonroll the certificate for all the clients.

    Regards,

    Maqsood


    Maqsood Mohammed Senior Systems Engineer MCITP-Enterprise Admin & ITILv3 Foundation Certified

    Wednesday, July 31, 2013 10:41 AM