Deploying SCCM 2012 Part 11 – Deploying Applications Using SCCM 2012

Deploying Applications Using SCCM 2012

Deploying Applications Using SCCM 2012 In this post we will see the ways for deploying applications using SCCM 2012. Before we start deploying applications, lets see what’s new about application deployment in SCCM 2012. An application in Configuration Manager contains the files and information required to deploy a software package to a device and the information about the software that all deployment types share. Applications are similar to packages in Configuration Manager 2007, but contain more information to support smart deployment. When you make changes to an application, a new revision of the application is created. Previous versions of the application are stored, and you can retrieve them at a later time.

When we deploy applications, we will come across few of the elements of applications :
1) Application Information – This provides general information about the application such as the name, description, version, owner and administrative categories. Configuration Manager can read this information from the application installation files if it is present.

2) Application Catalog – Provides information about how the application is displayed to users who are browsing the Application Catalog.

3) Deployment Types – A deployment type is contained within an application and contains the information that is required to install software. A deployment type also contains rules that specify if and how the software is deployed. A single application can have multiple deployment types that use the same technology. There are multiple deployment types available in CM2012.

a) Windows Installer – Creates a deployment type from a Windows Installer file. Configuration Manager can retrieve information from the Windows Installer file and related files in the same folder to automatically populate some fields of the Create Deployment Type Wizard.

b) Microsoft Application Virtualization – Detects application information and deployment types from a Microsoft Application Virtualization 4 manifest (.xml) file.

c) Windows Mobile Cabinet – Creates a deployment type from a Windows Mobile Cabinet (CAB) file.

d) Nokia SIS file – Creates a deployment type from a Nokia Symbian Installation Source (SIS) file.

When you deploy an application in CM 2012 you come across 2 things, Deployment Action and Deployment Purpose. Both of these are really important.

Deployment Action – Deployment Action includes “Install” or “Uninstall“. We can install an app or uninstall an app by providing relevant information in deployment action.

Deployment Purpose – This is really important, you have an option to specify Deployment purpose as “Available” or “Required“. If the application is deployed to a user, the user sees the published application in the Application Catalog and can request it on-demand. If the application is deployed to a device, the user sees it in Software Center and can install it on demand.

Now lets go ahead and deploy an application to a device in configuration Manager 2012. The first step would be creating an application. We will first download an application named 7-zip x64 for here : Download 7-zip. We will place the setup file in folder called softwares and share the folder.

Deploying SCCM 2012 Part 11 Snap 1

On the SCCM machine login with the user account sccmadmin and launch the configuration manager console. Select Software Library, Under Application Management select Applications.

Deploying SCCM 2012 Part 11 Snap 2

Right click Applications and select Create Application. Select Automatically detect information.. and choose the type as Windows Installer (Native), Specify the location of 7zip.msi file.

Deploying SCCM 2012 Part 11 Snap 4

We get to know that CM 2012 couldn’t get the details about the publisher of 7zip setup file. We will import the file by clicking Yes.

Deploying SCCM 2012 Part 11 Snap 3

Click Next.

Deploying SCCM 2012 Part 11 Snap 5

On the next screen, lets specify some details about the software and for Install behavior select Install for a system if resource is device, otherwise install for user. Click Next.

Deploying SCCM 2012 Part 11 Snap 6

Click Next.

Deploying SCCM 2012 Part 11 Snap 7

The Application has been created successfully , click Close.

Deploying SCCM 2012 Part 11 Snap 8

The Applications that are created can be seen by clicking Applications under Application Management. Since we have not deployed this application to any device or collection we see “0” under deployments. Once we deploy this application the count should increment.

Deploying SCCM 2012 Part 11 Snap 9

Right click the application and click Deploy.

Deploying SCCM 2012 Part 11 Snap 10

Click Browse and specify the collection as All Systems. Click Next.

Deploying SCCM 2012 Part 11 Snap 11

To add the Distribution Points, click in Add and choose your distribution point.

Deploying SCCM 2012 Part 11 Snap 12

Choose Action as “Install” and Purpose as “Required“.

Deploying SCCM 2012 Part 11 Snap 13

The application will be available once you distribute the content to content servers. If you want to schedule the availability of application, then select “schedule the application to be available at“. We will not schedule the application availability and distribute the content immediately to the Content servers. Select the Installation deadline “as soon as possible“. Click Next.

Deploying SCCM 2012 Part 11 Snap 14

For the User Notifications, select Hide in Software Center and all notifications. Click next.

Deploying SCCM 2012 Part 11 Snap 15

Do not select anything here, click next twice.

Deploying SCCM 2012 Part 11 Snap 16

We see that the deploy Software Wizard has completed successfully. Click Close.

Deploying SCCM 2012 Part 11 Snap 17

Now under Deployments we see the value is “1” which was previously “0“. Since we have deployed the application to a collection, the value is changed.

Deploying SCCM 2012 Part 11 Snap 18

Lets check whether the application has been deployed in the one of the computers. We will check in the machine named “CLIENT.PRAJWAL.LOCAL”. Wow, the application can be seen in the start menu

Deploying SCCM 2012 Part 11 Snap 19

Lets Check from the SCCM console to find more information about the deployment of application. On the Left hand side of console Select Monitoring , select Deployments. We get a lot of information about the application that we deployed. Total Asset Count = 2 which means the application was installed on 2 devices.

Deploying SCCM 2012 Part 11 Snap 20

Double click the application, we get to see the Asset Details here. We see that the application 7zip was installed on 2 devices, SCCM and CLIENT. If the deployment is unsuccessful you can get to know what went wrong by clicking Error tab.

Deploying SCCM 2012 Part 11 Snap 21

 

About The Author

I am Prajwal Desai and I have been working in the IT for over 5 years with a strong focus on Microsoft Server Technologies. For the last five years, as a System Administrator I have been working on Lync, SCCM, Vmware, VDI, Exchange, Windows Servers etc. I’m currently very interested in everything related to Configuration Manager 2012, Lync, Windows Server and Exchange.

Related posts

  • Suparno

    Hi Prajwal,

    How do I run a Service Controller (sc.exe) command from an elevated command prompt on my clients BEFORE I deploy an application through Configuration Manager 2012. Any help is highly appreciated.

    Thanks and Regards,
    Suparno

    • http://prajwaldesai.com Prajwal Desai

      @Suparno – May i know what exactly are you trying to achieve ?

      • Suparno

        Hi Prajwal, these are the details. I am deploying the recent released UE-V 1.0.5 Agent to client computers. I saw that the Offline Files Service (CscService) needs to be running before the installation will run. It seems that the Offline Files Service on Windows 8, by default, is set to Automatic (Trigger Start), which means that it’s not running during the deployment. So I am using the sc.exe tool to enable Offline Files from a command line. To enable the Offline Files feature using the sc.exe command, I need to run the following from an elevated command prompt: sc config CscService start=auto. How can I configure the UE-V Agent and enable the Offline Files feature using Configuration Manager 2012.

        • Suparno

          I think I should attempt a transform of the app’s MSI. My installation program command currently looks like this – msiexec /i “AgentSetupx64.msi” /quiet /norestart SyncMethod=None SyncEnabled=True. How do I run an elevated command line prompt in this. Or any other way that you advice through Configuration Manager 2012.

          • http://prajwaldesai.com Prajwal Desai

            try this Suparno –
            AgentSetup.exe /quiet /norestart /l*v “C:\UEVagentLog.txt”
            SettingsTemplateCatalogPath=”\\server\share\UE-V\Templates” SettingsStoragePath=\\server\share\%UserName%

  • Suparno

    Hi Prajwal,

    Thank you for your response. Let me explain the details. I am deploying the recent released UE-V 1.0.5 Agent to client computers. I saw that the Offline Files Service (CscService) needs to be running before the installation will run. It seems that the Offline Files Service on Windows 8, by default, is set to Automatic (Trigger Start), which means that it’s not running during the deployment. So I am using the sc.exe tool to enable Offline Files from a command line. To enable the Offline Files feature using the sc.exe command, I need to run the following from an elevated command prompt: sc config CscService start=auto. Problem is how can I configure the UE-V Agent and enable the Offline Files feature using Configuration Manager 2012.

    These is the installation program I am using –
    msiexec /i “AgentSetupx64.msi” /quiet /norestart SyncMethod=OfflineFiles SyncEnabled=True SettingsStoragePath=”\\server\SettingsStore\^%username^%” SettingsTemplateCatalogPath=”\\server\SettingsCatalog”

    msiexec /i “AgentSetupx86.msi” /quiet /norestart SyncMethod=OfflineFiles SyncEnabled=True SettingsStoragePath=”\\server\SettingsStore\^%username^%” SettingsTemplateCatalogPath=”\\server\SettingsCatalog”

    • Suparno

      Hi Prajwal,

      Tell me something. Can I resolve like this. What do you think.
      If I go through the Software Library > Overview > Operating Systems > Task Sequences > Command Line and fill in as Powershell.exe Start-Service CscService and then Add > General > Install Application.
      I am confused if this is the correct way of resolving this. I do not want to add this in operating system deployment sequence..just want to sequence my Powershell.exe Start-Service CscService and then deploy my UE-V agent application. Is this the correct way.

      • http://prajwaldesai.com Prajwal Desai

        Suparno if you are planning to do with Powershell check this link once , it might help you – http://ittechlog.wordpress.com/2012/04/08/configuring-ue-v-agent-with-powershell/. I think through powershell we can deploy it with ease rather that the old method that you specified.

        • Suparno

          Hi Prajwal,

          I also think a task sequence is far too heavy. Do you think I can just add it as an item in the uev agent package installation to keep it simple. What do you think.

          • http://prajwaldesai.com Prajwal Desai

            That would be the best and easiest way..

          • http://prajwaldesai.com Prajwal Desai

            @ Suparno- I will create a post on deploying UE-V agent to client computers soon..

  • Suparno

    Hi Prajwal,

    That would be fantastic. Is there any of your sites where I can follow this step for adding it as an item in the uev agent package installation (enabling offline files and then install the agent)

    Thanks and Regards,
    Suparno

    • http://prajwaldesai.com Prajwal Desai

      No suparno, i have not created any post on that. If i get time i will surely create a post on deploying UE-V agent..

      • Suparno

        Hi Prajwal,

        Thank you for your response. Please do create your post on deploying UE-V agent… You are the end-word on SCCM and you are highly appreciated by all my colleagues and co-workers.

        Thanks and Regards,
        Suparno

        • http://prajwaldesai.com Prajwal Desai

          Thank you Suparno..

  • Suparno

    Hi Prajwal,

    I do not know so it is best to ask the master. You may think me as complete muppet. I am very new to SCCM 2012 (4 days old).

    This is what I have completed till now –

    1) Created the UE-V Agent application in Configuration Manager
    2) Distributed the UE-V Agent Application
    3) Deployed the UE-V Agent Configuration Manager application

    Confused –
    Now how do I use the command line sc config CscService start=auto OR Get-WmiObject -Query “Select * From Win32_Service Where Name=’CSCService'”|ForEach-Object{$_.ChangeStartMode(“Automatic”) $_.StartService()} to enable the Offline Files as a pre-requisite to installing the application. What is the step by step method for this.

    Thanks and Regards,
    Suparno

    • Suparno

      Hi Prajwal,
      I progressed a little after writing to you. Now I have a doubt. How do I link a package to an application in Configuration Manager 2012. To explain in details –

      1) I have created one package that contains and runs the Offline files enabling command (sc config CscService start=auto). (We can also use like Get-WmiObject -Query “Select * From Win32_Service Where Name=’CSCService'”|ForEach-Object{$_.ChangeStartMode(“Automatic”) $_.StartService()})

      2) Created one application for UE-V Agent installation. (msiexec /i “AgentSetupx64.msi” /quiet /norestart /l*v “C:\UEVagentLog.txt” SyncMethod=OfflineFiles SyncEnabled=True SettingsTemplateCatalogPath=”\\server
      \SettingsCatalog” and msiexec /i “AgentSetupx86.msi” /quiet /norestart /l*v “C:\UEVagentLog.txt” SyncMethod=OfflineFiles SyncEnabled=True SettingsTemplateCatalogPath=”\\server\SettingsCatalog”)

      Confusion –
      How do I link the Offline files package to the agent installation application as a dependency.

      • Suparno

        In fact I went to dependencies – clicked on add dependency – it says specify the required application. Now problem is I want to add a package as dependency to the application. Any way to use a work-around. What do you think.

        • Suparno

          Hi Prajiwal,

          This may help someone like me. I think there is no way to link package with application. So here is what i did –
          1) Created the script with the application model..
          2) Linked it to the agent application as dependency.
          3) Deployed the agent application to client computers.

          Thanks and Regards,
          Suparno

        • http://prajwaldesai.com Prajwal Desai

          Suparno – Lets try this. Use this command to deploy the UE-V agent “AgentSetup.exe /quiet /norestart /l*v SyncMethod=None”. For this step do not enable offline files, in other words we are deploying ue-v agent with sync feature disabled. Tell me if this works.. The issue here is the CSC service needs to be enabled first on windows 8 and that has to be done from elevated command prompt. When you run a task sequence it runs with local system account, let me find a way to run the command prompt as local administrator.

          • Suparno

            Hi Prajwal,

            Thank you for your response. My findings are if the Offline Files are disabled (as it is in Windows 8 by default, unlike Windows 7), we will not be able to install the UE-V agent. It will give an error Offline Files needs to be enabled.

            So we have to figure out a way to install the Offline Files first (this command works – sc config CscService start=auto) and then install the UE-V agent through SCCM.

            Important point that I found in lab – Even if we use “AgentSetup.exe /quiet /norestart /l*v SyncMethod=None” as agent installation command, we need Offline Files to be enabled before installation. (Sync Method = None will ensure that sync does not happen between Offline Cache and server)

            Thanks and Regards,
            Suparno

          • Suparno

            Hi Prajwal,

            I wanted to share few findings with you. What do you think. Am I on the correct track.

            1) Found that we can create a script package with the App model for delivery in SCCM 2012.
            2) Found that we can link an application with another application as a dependency. (We cannot link a package to an application as a dependency or vice versa.)

            Now as you said the requirement here is the CSC service (Offline files) needs to be enabled first on windows 8 and that has to be done from elevated command prompt. This is what I have done.

            1) Created the script with the application model..(sc config CscService start=auto) (We can also use like Get-WmiObject -Query “Select * From Win32_Service Where Name=’CSCService'”|ForEach-Object{$_.ChangeStartMode(“Automatic”) $_.StartService()})
            2) Linked it to the UE-V agent installation application as dependency.
            3) Deployed the application to client computers.

            As you correctly mentioned my doubt is also SCCM probably runs the application model script as local system account, we have to find a way to run the command prompt as local administrator. What do you think.

            Thanks and Regards,
            Suparno

          • http://prajwaldesai.com Prajwal Desai

            I am finding out on running this command with administrator account.. I will try to simulate the same in my lab..

  • Suparno

    Hi Prajwal,

    The system account has full rights to the machine. (So ideally we don’t need a different account) What do you think.

    Thanks and Regards,
    Suparno

    • http://prajwaldesai.com Prajwal Desai

      It doesn’t work Suparno.. You can give a try…

  • Suparno

    Hi Prajwal,

    You are correct. I was thinking how to resolve the issue and this is what I did.

    1) Enabled Offline Files by GPO. (Computer configuration – Administrative templates – Network – Offline Files and select “Allow or Disallow use of the Offline Files feature” and click Enable. Machine restart is needed).

    2) SCCM 2012 silently installs the UE-V agent to user computer. (Machine restart is needed).

    We need to test what happens if a machine restart does not happen between 1 and 2, but does happen after 2. If that succeeds that will be good. What do you think.

    Thanks and Regards,
    Suparno

    • http://prajwaldesai.com Prajwal Desai

      Suparno – If you were okay with using GPO to enable service, I would have suggested this at the first time. You wanted to enable the service through task sequence..Anyway, you can use GPO to start any windows service. Did you try using /norestart switch ?

      • Suparno

        Hi Prajwal,

        Little confused. You mean using /norestart switch for GPO ? (Computer configuration -Administrative templates – Network – Offline Files and select “Allow or Disallow use of the Offline Files feature” and click Enable)

        Thanks and Regards,
        Suparno

        • Suparno

          Hi Prajwal,

          I think I understood. Yes I used /norestart while installing the agent application through SCCM 2012. It will be good if the machine restart happens only AFTER enabling Offline Files and installation of agent. Do you think it is possible.

          These are the details of the msi used while creating the agent application.
          msiexec /i “AgentSetupx64.msi” /quiet /norestart /l*v “C:\UEVagentLog.txt” SyncMethod=OfflineFiles SyncEnabled=True SettingsTemplateCatalogPath=”\\namespace\SettingsCatalog”

          msiexec /i “AgentSetupx86.msi” /quiet /norestart /l*v “C:\UEVagentLog.txt” SyncMethod=OfflineFiles SyncEnabled=True SettingsTemplateCatalogPath=”\\namespace\SettingsCatalog”

          Thanks and Regards,
          Suparno

        • http://prajwaldesai.com Prajwal Desai

          /norestart switch to be used while you deploy UEV agent…

          • Suparno

            Hi Prajwal,

            (I dont have your email address otherwise I would have written to you one on one). As you have a full-fledged lab, can you just check this step –

            We need to test what happens if a machine restart does not happen between 1 and 2, but does happen after 2. Is it successfully installing the agent.

            1) Enabled Offline Files by GPO. (Computer configuration – Administrative templates – Network – Offline Files and select “Allow or Disallow use of the Offline Files feature” and click Enable.).

            2) SCCM 2012 silently installs the UE-V agent to user computer.

            Thanks and Regards,
            Suparno

  • Suparno

    Hi Prajwal,

    Have you encountered this before. I need your opinion. I have installed the SCCM Configuration Client on my target computer. But the client certificate is None (should be PKI). The CCM Notification Agent is Disabled (should be enabled). Actions should be more (Discovery Data Collection cycle, Software inventory cycle and others missing). What do you think is the issue.

    Trouble-shooting steps tried –
    1) I have re-installed the agent (ccmsetup.exe /usepkicert SMSSITECODE=),
    2) Host file is correct
    3) Checked the logs on failed client – ccmsetup.log, ClientIDManagerStartup.log.
    4) Requested for a new certificate from AD.
    5) Modified the installation command as ccmsetup.exe /NoCRLCheck /UsePKICert /mp:sccm2012sp2.OCEANIA.local /logon SMSSITECODE=

    Thanks and Regards,
    Suparno

    • http://prajwaldesai.com Prajwal Desai

      I would want to see the ccmsetup.log. Attach and send it to prajwal@prajwaldesai.com.

      • Suparno

        Hi Prajwal,

        Yes you were correct. It was a certificate issue. The certificate showed as valid till 2023 however in thumb print it was showing a different date. Deleted the certificate and got a new one. Issue is resolved.

        Wanted to share my finding on something else regarding UE-V client installation process. My requirement was to ensure that user has to restart system only once and not twice. This would have helped in customer experience but it seems it is not possible.

        1) Action – Enabled Offline files GPO on server (Computer configuration – Administrative templates – Network – Offline Files and select “Allow or Disallow use of the Offline Files feature” and click Enable)
        2) Result – Offline files on client is enabled but not active. (I did not restart computer)
        3) Action – Tried to install Agentsetup.exe on client.
        4) Result – Installation fails saying Offline files is not enabled.

        As an alternative tried –

        1) Action – Enabled Offline files on client by sc config CscService start=auto.
        2) Result – Offline files on client is enabled but not active. (I did not restart computer)
        3) Action – Tried to install Agentsetup.exe on client.
        4) Result – Installation fails saying Offline files is not enabled.

        In point 2, if system is restarted, installation succeeds.

        Thanks and Regards,
        Suparno

  • Ravindra

    Hi Prajwal,

    I was curious. How long does it take for the software deployment to start after you choose “as soon as possible”? Is there a way to force the deployment to start right away?

    • http://prajwaldesai.com Prajwal Desai

      It would take 4-8 minutes for the deployment to begin. What software are you deploying ?

  • Suparno

    Hi Prajwal,

    Need your advice and help.

    Requirement – I have to create an application of the below PowerShell script and run this script in admin mode in SCCM 2012 as a dependency with my UE-V Agent application (this msi package has been tested successfully).

    Now how do I create an application of the below program and run this program in PowerShell admin mode in SCCM 2012. Should I do it with a small task sequence or should I use simple dependency feature.

    Program to force Offline Files to be enabled –

    $exists = Test-Path HKLM:\SYSTEM\CurrentControlSet\Services\CSC

    if ($exists)
    {

    $startvalue = get-itemproperty HKLM:\SYSTEM\CurrentControlSet\Services\CSC | foreach {$_.Start}
    if ($startvalue -eq 4)
    {
    set-itemproperty HKLM:\SYSTEM\CurrentControlSet\Services\CSC -Name Start -Value 1
    set-itemproperty HKLM:\SYSTEM\CurrentControlSet\Services\CscService -Name Start -Value 2
    }
    }

    $exists = Test-Path HKLM:\SYSTEM\CurrentControlSet\Services\CscService

    if ($exists)
    {
    $startvalue = get-itemproperty HKLM:\SYSTEM\CurrentControlSet\Services\CSCService | foreach {$_.Start}

    if ($startvalue -eq 4)
    {
    set-itemproperty HKLM:\SYSTEM\CurrentControlSet\Services\CSCService -Name Start -Value 2
    set-itemproperty HKLM:\SYSTEM\CurrentControlSet\Services\Csc -Name Start -Value 1
    }
    }

  • Selene

    This is the only post where i got actual step by step method to deploy applications using sccm… Can you also show us how to deploy other apps ?

    • http://prajwaldesai.com Prajwal Desai

      Yes I am working on it.

  • Ravikant Soni

    Hi Prajwal,

    I work on IBM tools, and I have given to integrate IBM SCCD with SCCM, what I just want to know is:

    1. How do we use soap connectivity of SCCM
    2. Is there any way to deploy software on client machine using command line let say I want install notepad on one of the target machine, and I have following details with me

    a. Asset (target machine)
    b. Owner of the asset (target machine)
    c. Software to be deployed

    Hence, can I use above info and instruct SCCM to install the software.. Your suggestions would be really helpful.

  • Ravikant Soni

    Hi Prajwal,

    Thanks for the link, this might help me…I’ll update soon on this..I know being selfish is not good thing…but can you just make me understand If I want to install notepad++ on some windows machine what exact command I need to shoot on target machine…!!!

    At first glance I couldn’t figure out the command out of the link.

  • Osama

    when i trying to add distribution point i cant find that so please help me.

    • Naveen Punj

      Check distmgr.log
      Ccmsetup.log
      Cas.log
      Ccm log

  • Naveen Punj

    Good work…

  • manish nair

    hi,
    msi is in E drive. there will b a C drive too. how in the unc path, there is no mention of drive letter, how sccm identifies its in which drive ? if my msi is in c drive then also the path given above wil work ?

    • http://PrajwalDesai.com/ Prajwal Desai

      In the UNC path you always provide the path along with the folder where the software is stored.

      • manish nair

        directly after server name, u mentioned folder path without mentioning the drive. thts my doubt. i m gettin error tht there is no such file/path. i tried all types of unc. my msi is directly under C:

        • http://PrajwalDesai.com/ Prajwal Desai

          @Manish – Share the folder with least permissions so that it shows up in the UNC path. SCCM has to know where have you placed the .msi or .exe file.

Read previous post:
Deploying SCCM 2012 Part 9 – Create and Configure Custom Client Device Settings, Deploying CM Client Agent.

Deploying SCCM 2012 Part 9 – Create and Configure Custom Client Device Settings, Deploying CM Client Agent. In Part 1...

Close