locked
Custom Task - Run Command Line: Return Code -2147467259 0x80004005 RRS feed

  • Question

  • What I'm trying to do:  Use a custom task with a 'run command line' to copy a folder from my deployment share to the C drive of the system I am deploying software to.

    What happens:  The system is a freshly deployed Vista Enterprise OS with MS Office 2007 installed from MDT 2010.  Everything works just fine but I can't get this one custom task with two run command line items to work.  I've made sure that I have admin on the system and I'm using litetouch.vbs to start the process from the system I want to install the stuff from since the full install works up to this point.  It is on the domain.  Process is to setup a share via 'net use' to access the deployment server, then run litetouch.vbs from the scripts folder.  Command to be run to copy the folder is as follows.  ( copy \\server\share$\applications\student c:\"student materials" )  Note that this command works from the command line on the system but won't work when placed in the run command line task.  

    Red Deployment summary screen, "OS deployment did not complete successfuly"  -- even though there is no OS being deployed....  Error, "Litetouch deployment failed, Return Code = -2147467259 0x40004005". 

    Below is the BDD log starting where it started the Custom Task.  Note, the task only has two 'run command line' entries in the task.  One to copy the folder from share to system and one to copy a shortcut from the folder to a previously restored USMT added profile during OS installation.

    "<![LOG[Property TaskSequenceName is now = Deploy Student Materials]LOG]!><time="13:40:31.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property TaskSequenceVersion is now = 1.0]LOG]!><time="13:40:31.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Unable to find Task Sequence step of type //step[@type='BDD_InstallOS']]LOG]!><time="13:40:31.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[ Open Control File: Applications]LOG]!><time="13:40:31.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Unable to find Task Sequence step of type //step[@type='BDD_InstallApplication'], performing more exhaustive search...]LOG]!><time="13:40:32.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Unable to find Task Sequence step of type //step[@type='BDD_InstallApplication']]LOG]!><time="13:40:32.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Unable to find Task Sequence step of type //step[@name='Create WIM'], performing more exhaustive search...]LOG]!><time="13:40:32.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Unable to find Task Sequence step of type //step[@name='Create WIM']]LOG]!><time="13:40:32.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property UserCredentials is now = True]LOG]!><time="13:40:47.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property TSGuid is now = {e8c592ee-e00e-47a4-84dd-42bfc503c6f1}]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property OSGUID is now = ]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property DeploymentType is now = CUSTOM]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property UserID is now = bmF0ZS5mb3hf]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[<Message containing password has been suppressed>]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property UserDomain is now = YXI=]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property WizardComplete is now = Y]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Validating connection to \\SERVER\Share$]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Already connected to server SERVER as that is where this script is running from.]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[DestinationDisk and DestinationPartition are not set, reading from TS.XML]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Property OSDComputerName is now = ZWA073NB9458C3T]LOG]!><time="13:40:50.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Validating connection to \\SERVER\Share$]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Found Existing UNC Path Z:  = \\SERVER\Share$]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Found Existing UNC Path Z:  = \\SERVER\Share$]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Successfully established connection using supplied credentials.]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Property DeployDrive is now = Z:]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[DeployDrive = Z:]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Property ResourceRoot is now = \\SERVER\Share$]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[DeploymentType = CUSTOM]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[ResourceRoot = \\SERVER\Share$]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Property ResourceDrive is now = Z:]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[ResourceDrive = Z:]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Property _SMSTSPackageName is now = Lite Touch Installation]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[SMS Task Sequencer found at \\SERVER\Share$\Tools\X86, copying to C:\MININT\Tools\X86]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\CcmCore.dll to C:\MININT\Tools\X86\CcmCore.dll]LOG]!><time="13:40:51.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\CcmUtilLib.dll to C:\MININT\Tools\X86\CcmUtilLib.dll]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\Smsboot.exe to C:\MININT\Tools\X86\Smsboot.exe]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\SmsCore.dll to C:\MININT\Tools\X86\SmsCore.dll]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\TsCore.dll to C:\MININT\Tools\X86\TsCore.dll]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\TSEnv.exe to C:\MININT\Tools\X86\TSEnv.exe]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\TsManager.exe to C:\MININT\Tools\X86\TsManager.exe]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\TsmBootstrap.exe to C:\MININT\Tools\X86\TsmBootstrap.exe]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\TsMessaging.dll to C:\MININT\Tools\X86\TsMessaging.dll]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\TsProgressUI.exe to C:\MININT\Tools\X86\TsProgressUI.exe]LOG]!><time="13:40:52.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\TSResNlc.dll to C:\MININT\Tools\X86\TSResNlc.dll]LOG]!><time="13:40:53.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\xprslib.dll to C:\MININT\Tools\X86\xprslib.dll]LOG]!><time="13:40:53.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Tools\X86\00000409\tsres.dll to C:\MININT\Tools\X86\00000409\tsres.dll]LOG]!><time="13:40:53.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying \\SERVER\Share$\Control\6\TS.XML to C:\MININT\Tools\X86]LOG]!><time="13:40:53.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Copying C:\MININT\SMSOSD\OSDLOGS\VARIABLES.DAT to C:\MININT\Tools\X86\VARIABLES.DAT]LOG]!><time="13:40:53.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[LTI beginning deployment]LOG]!><time="13:40:53.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[About to run command: "C:\MININT\Tools\X86\TsmBootstrap.exe" /env:SAStart]LOG]!><time="13:40:53.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Litetouch deployment failed, Return Code = -2147467259  0x80004005]LOG]!><time="13:40:54.000+000" date="03-12-2010" component="LiteTouch" context="" type="3" thread="" file="LiteTouch">
    <![LOG[For more information, consult the task sequencer log ...\SMSTS.LOG.]LOG]!><time="13:40:54.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Property RetVal is now = -2147467259]LOG]!><time="13:40:54.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[CleanStartItems Complete]LOG]!><time="13:40:54.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[About to run command: MSHTA.exe "\\SERVER\Share$\Scripts\Wizard.hta" /definition:Summary_Definition_ENU.xml]LOG]!><time="13:40:54.000+000" date="03-12-2010" component="LiteTouch" context="" type="1" thread="" file="LiteTouch">
    <![LOG[Property definition is now = Summary_Definition_ENU.xml]LOG]!><time="13:40:55.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Microsoft Deployment Toolkit version: 5.0.1641.0]LOG]!><time="13:40:55.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Not Wizard = False]LOG]!><time="13:40:55.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">
    <![LOG[Property WizardComplete is now = N]LOG]!><time="13:40:55.000+000" date="03-12-2010" component="Wizard" context="" type="1" thread="" file="Wizard">"


    Any help in figuring this out would be great.  I think I'm going to redeploy everything but not add it to the domain and see what happens.  I know that Office installs just fine with it on the domain though and all of the permissions work so I'm not sure what the issue with the command line is.

    Friday, March 12, 2010 10:35 PM

Answers

  • what does SMSTS.LOG say? have you tryed xcopy /S/D/C instead of copy?

    and let me get that right, you're running the command AFTER the deployment is compleated and you're back in your new OS? because if you run it out of winPE, make sure the c: drive exists, since winPE changes all drives (and so drive letters). if you wanna make sure its getting the right dir try %systemdrive% instead of c: (same rules here: make sure you're back in windows when running that)
    • Marked as answer by Nate Fox Thursday, April 1, 2010 11:16 PM
    Friday, March 12, 2010 10:40 PM
  • Thanks to Robert for pointing me in the right direction.  I was using a custom task as an application install so I could copy the folder during the State Restore phase of a Standard Client Task to deploy a clean OS.  I managed to get it working with a few changes to the commands.

    Ended up with xcopy /s /c \\server\share\folder c:\foldername\

    Also, if copying from or too a folder that has a space formating would look like xcopy /s /c \\server\share\folder c:\"folder name\" 

    The other key piece was that I had to force it to run the commands as admin in each task object.

    • Marked as answer by Nate Fox Thursday, April 1, 2010 11:16 PM
    Thursday, April 1, 2010 11:16 PM

All replies

  • what does SMSTS.LOG say? have you tryed xcopy /S/D/C instead of copy?

    and let me get that right, you're running the command AFTER the deployment is compleated and you're back in your new OS? because if you run it out of winPE, make sure the c: drive exists, since winPE changes all drives (and so drive letters). if you wanna make sure its getting the right dir try %systemdrive% instead of c: (same rules here: make sure you're back in windows when running that)
    • Marked as answer by Nate Fox Thursday, April 1, 2010 11:16 PM
    Friday, March 12, 2010 10:40 PM
  • Thanks to Robert for pointing me in the right direction.  I was using a custom task as an application install so I could copy the folder during the State Restore phase of a Standard Client Task to deploy a clean OS.  I managed to get it working with a few changes to the commands.

    Ended up with xcopy /s /c \\server\share\folder c:\foldername\

    Also, if copying from or too a folder that has a space formating would look like xcopy /s /c \\server\share\folder c:\"folder name\" 

    The other key piece was that I had to force it to run the commands as admin in each task object.

    • Marked as answer by Nate Fox Thursday, April 1, 2010 11:16 PM
    Thursday, April 1, 2010 11:16 PM
  • Hi,

    VERY VERY Grateful for your conversation.  I have struggled with copying a file from my Scriptroot to the C:\WINDOWS... I saw tohers also have this problem...

    I followed your advice, and in the end i had this :

    xcopy /s /c \\MDT_Server.fqdn\DeploymentShare$\Scripts\PsExec.exe c:\windows

    It did the Job.

    Much appreciated, Thank you.

    Friday, December 20, 2019 12:01 PM