Unable to run Bat file from sccm 2012 task sequence

Posted on 2014-08-28
Last Modified: 2014-09-04
I have a bat file that consist of these lines:

cd C:\Program Files (x86)\PGP Corporation\PGP Desktop
C:\Program Files (x86)\PGP Corporation\PGP Desktop\pgpwde --decrypt --disk 0 --passphrase xxxxxxxxx
ECHO PGP decryption starting

I really don't need the echo's, but would be nice to have them.

I've tried creting a tsk sequence that just runs "C:\Program Files (x86)\PGP Corporation\PGP Desktop\pgpwde" --decrypt --disk 0 --passphrase xxxxxxxxx

But it didn't work. Tried a package, still nothing., Not sure if I'm creating them right.

Any thoughts?
Question by:rdefino
    1 Comment
    LVL 16

    Accepted Solution


    For 2012, you can only use a package (because it's an EXE not an MSI) or use a task-sequence.
    Personally, I would install MDT 2013 and run the integration if you haven't already as it adds lots of extra functionality. This would then allow you to use the MDT framework and run the job with vbscript instead of a batch file.

    Using a batch file will work, but is a "fire and forget" method: SCCM has no control other than launching it. It certainly has no idea what your batch file does or what the result it. MDT + vbscript can return a result code (0 means success) and let's SCCM trap errors.

    Any script with a pause or other action that displays a prompt will fail as SCCM defaults to run as local system which has no user context and can never display messages etc. The job will fail after the process is killed.

    Create a package and make the command line:
    pgpwde --decrypt --disk 0 --passphrase xxxxxxxxx

    but by sure to add the package source with pgpwde inside. It should work with just a task-sequence and the full path as you've already tried but you would have to provide smsts.log, appenforce.log and maybe ccmexec.log for people to see why it failed. I suspect it's the parameters somehow.


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    Suggested Solutions

    The reason that corporations and businesses use Windows servers is because it supports custom modifications to adapt to the business and what it needs. Most individual users won’t need such powerful options. Here I’ll explain how you can enable Wind…
    In this Micro Tutorial viewers will learn how to restore their server from Bare Metal Backup image created with Windows Server Backup feature. As an example Windows 2012R2 is used.
    This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles to another domain controller. Log onto the new domain controller with a user account t…

    761 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now