none
Orchestrator cloud pack - An error occurred while executing the custom action _Importrunbooks

    Question

  • Hello,

    I'm triying to install the cloud pack which contains private cloud runbooks...

    well.. I use the RC version for Orchestrator + the pack..

    I've disabled the UAC, unblocked the zip (System_Center_Cloud_Services_Process_ Pack_RC.zip) installed with "run as administrator" and still.. I'm getting the error: "An error occurred while executing the custom action _Importrunbooks" in "Import Cloud services runbooks" step.

    I don't see in procmon any access denied in registry as I saw before with the UAC enabled.

    These are the errors from the install logs (just the errors):

    MSI (s) (44:8C) [20:40:40:831]: Note: 1: 2205 2:  3: Error

    MSI (s) (44:8C) [20:40:41:659]: Note: 1: 2205 2:  3: Error

    MSI (s) (44:8C) [20:40:41:659]: Note: 1: 2228 2:  3: Error 4: SELECT `Message` FROM `Error` WHERE `Error` = 1302

    MSI (s) (44:74) [20:40:41:795]: NOTE: custom action _SetRunbook_Rollback unexpectedly closed the hInstall handle (type MSIHANDLE) provided to it. The custom action should be fixed to not close that handle.

    MSI (s) (44:E0) [20:40:56:839]: NOTE: custom action _Importrunbooks unexpectedly closed the hInstall handle (type MSIHANDLE) provided to it. The custom action should be fixed to not close that handle.

    CustomAction _Importrunbooks returned actual error code 1603 (note this may not be 100% accurate if translation happened inside sandbox)

    MSI (s) (44:8C) [20:40:57:969]: Error in rollback skipped.    Return: 5

    Action ended 20:40:57: INSTALL. Return value 3.

    MSI (s) (44:8C) [20:40:57:985]: Note: 1: 2205 2:  3: Error
    MSI (s) (44:8C) [20:40:57:985]: Note: 1: 2228 2:  3: Error 4: SELECT `Message` FROM `Error` WHERE `Error` = 1708
    MSI (s) (44:8C) [20:40:57:985]: Note: 1: 2205 2:  3: Error
    MSI (s) (44:8C) [20:40:57:985]: Note: 1: 2228 2:  3: Error 4: SELECT `Message` FROM `Error` WHERE `Error` = 1709
    MSI (s) (44:8C) [20:40:57:985]: Product: System Center Cloud Services Runbooks -- Installation failed.
    MSI (s) (44:8C) [20:40:57:985]: Windows Installer installed the product. Product Name: System Center Cloud Services Runbooks. Product Version: 7.5.1400.655. Product Language: 0. Manufacturer: Microsoft Corporation. Installation success or error status: 1603.

    Any Idea ?

    Thank you.


    • Edited by Sharon_A Monday, February 13, 2012 7:23 PM
    Monday, February 13, 2012 6:49 PM

Answers

  • I think these errors connected to the Orchestrator & Cloud Pack builds which got changed... the version need to match.

    Checking.

    • Marked as answer by Sharon_A Wednesday, March 07, 2012 1:13 PM
    Wednesday, February 15, 2012 6:34 PM

All replies

  • Hi, Sharon_A

    Can I second this - I get the same issue when installing the runbooks on my standalone Orchestrator server, Windows Server 2008 R2.  I am running setup from an administrative command prompt.

    My Installation log is much the same, but I have some extra information in mine.  I have used process monitor to try and diagnose this but have drawn a blank - the only thing I could see if that the installer requests access to the following reg keys and is denied:

    • HKLM\System\CurrentControlSet\Services\Eventlog\Security
    • HKCU\Environment

    There's nothing that jumps out at me here.

    Here's an extract from the installation log, the SecurityException is emboldened by me.

    1. MSI (s) (1C:B8) [09:38:12:699]: Note: 1: 2235 2:  3: ExtendedType 4: SELECT `Action`,`Type`,`Source`,`Target`, NULL, `ExtendedType` FROM `CustomAction` WHERE `Action` = '_Importrunbooks'
    2. MSI (s) (1C:3C) [09:38:12:700]: Invoking remote custom action. DLL: C:\Windows\Installer\MSI40F9.tmp, Entrypoint: ImportRunbooks
    3. Action start 09:38:12: _Importrunbooks.
    4. CAPACK: Extracting custom action to temporary directory: C:\Windows\Installer\MSI40F9.tmp-\
    5. CAPACK: Binding to CLR version v2.0.50727
    6. Calling custom action CAIaaSRequestMPB!Microsoft.SystemCenter.CloudServices.Setup.CustomActionLibrary.CAIaaSRequestMPB.ImportRunbooks
    7. System.Security.SecurityException: Requested registry access is not allowed.
    8.    at Microsoft.Win32.RegistryKey.OpenSubKey(String name, Boolean writable)
    9.    at System.Environment.GetEnvironmentVariable(String variable, EnvironmentVariableTarget target)
    10.    at System.Management.Automation.ModuleIntrinsics.GetExpandedEnvironmentVariable(String name, EnvironmentVariableTarget target)
    11.    at System.Management.Automation.ModuleIntrinsics.SetModulePath()
    12.    at System.Management.Automation.ExecutionContext.InitializeCommon(AutomationEngine engine, PSHost hostInterface)
    13.    at System.Management.Automation.AutomationEngine..ctor(PSHost hostInterface, RunspaceConfiguration runspaceConfiguration, InitialSessionState iss)
    14.    at System.Management.Automation.Runspaces.LocalRunspace.DoOpenHelper()
    15.    at System.Management.Automation.Runspaces.RunspaceBase.CoreOpen(Boolean syncCall)
    16.    at Microsoft.SystemCenter.CloudServices.Setup.CustomActionLibrary.CAIaaSRequestMPB.ImportRunbooks(Session session)
    17. The Zone of the assembly that failed was:
    18. MyComputer
    19. MSI (s) (1C:3C) [09:38:13:674]: NOTE: custom action _Importrunbooks unexpectedly closed the hInstall handle (type MSIHANDLE) provided to it. The custom action should be fixed to not close that handle.
    20. CustomAction _Importrunbooks returned actual error code 1603 (note this may not be 100% accurate if translation happened inside sandbox)
    21. MSI (s) (1C:B8) [09:38:13:675]: User policy value 'DisableRollback' is 0
    22. MSI (s) (1C:B8) [09:38:13:675]: Machine policy value 'DisableRollback' is 0
    23. Action ended 09:38:13: _Importrunbooks. Return value 3.

    Matt


    Matt White
    ( http://systemcenterblog.hardac.co.uk/ - @matthewwhite )



    • Edited by Matt White Tuesday, February 14, 2012 9:59 AM
    Tuesday, February 14, 2012 9:58 AM
  • Just a quick update.

    I read more into that exception and realised that it had been caused by the System.Environment.GetEnvironmentVariable method.  I therefore granted everyone Full Control of the HKCU\Environment key and the installation has got further.  It now fails when trying to run the ProcessSCORunbook.ps1 file!

    Action start 10:08:26: _Importrunbooks.
    CAPACK: Extracting custom action to temporary directory: C:\Windows\Installer\MSIED59.tmp-\
    CAPACK: Binding to CLR version v2.0.50727
    Calling custom action CAIaaSRequestMPB!Microsoft.SystemCenter.CloudServices.Setup.CustomActionLibrary.CAIaaSRequestMPB.ImportRunbooks
    System.Management.Automation.CommandNotFoundException: The term 'C:\Users\matt\Desktop\extract\Setup\SCORunbooks\ProcessSCORunbook.ps1' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
       at System.Management.Automation.CommandDiscovery.LookupCommandInfo(String commandName, CommandOrigin commandOrigin)
       at System.Management.Automation.CommandDiscovery.LookupCommandProcessor(String commandName, CommandOrigin commandOrigin, Nullable`1 useLocalScope)
       at System.Management.Automation.Runspaces.Command.CreateCommandProcessor(ExecutionContext executionContext, CommandFactory commandFactory, Boolean addToHistory)
       at System.Management.Automation.Runspaces.LocalPipeline.CreatePipelineProcessor()
       at System.Management.Automation.Runspaces.LocalPipeline.InvokeHelper()
       at System.Management.Automation.Runspaces.LocalPipeline.InvokeThreadProc()
    MSI (s) (E4:94) [10:08:29:039]: NOTE: custom action _Importrunbooks unexpectedly closed the hInstall handle (type MSIHANDLE) provided to it. The custom action should be fixed to not close that handle.
    CustomAction _Importrunbooks returned actual error code 1603 (note this may not be 100% accurate if translation happened inside sandbox)
    MSI (s) (E4:60) [10:08:29:039]: User policy value 'DisableRollback' is 0
    MSI (s) (E4:60) [10:08:29:040]: Machine policy value 'DisableRollback' is 0
    Action ended 10:08:29: _Importrunbooks. Return value 3.

    I will try to determine why this isn't working, it might be because there is no default handler of ps1 files.  I don't know.

    Matt


    Matt White
    ( http://systemcenterblog.hardac.co.uk/ - @matthewwhite )


    • Edited by Matt White Tuesday, February 14, 2012 10:14 AM
    Tuesday, February 14, 2012 10:14 AM
  • The only line i see about the ps1 files is :

    MSI (s) (EC:BC) [21:38:55:264]: WIN64DUALFOLDERS: Substitution in 'C:\Program Files (x86)\Microsoft System Center 2012\Orchestrator\Cloud services runbooks\ProcessSCORunbook.ps1' folder had been blocked by the 1 mask argument (the folder pair's iSwapAttrib member = 0).

    still checking...

    Tuesday, February 14, 2012 5:33 PM
  • I think these errors connected to the Orchestrator & Cloud Pack builds which got changed... the version need to match.

    Checking.

    • Marked as answer by Sharon_A Wednesday, March 07, 2012 1:13 PM
    Wednesday, February 15, 2012 6:34 PM
  • I got a bit further...

    I now get an Authorization Manager error in the MSI logfile, search for value 3.. I will post the full log details later on.

    I have not managed to gleen anything from procmon.  :-(

    Matt


    Matt White
    ( http://systemcenterblog.hardac.co.uk/ - @matthewwhite )

    Wednesday, February 15, 2012 9:10 PM
  • Here's the extract from my MSI log:

    MSI (s) (94:A0) [21:43:15:166]: Invoking remote custom action. DLL: C:\Windows\Installer\MSI68AC.tmp, Entrypoint: ImportRunbooks
    CAPACK: Extracting custom action to temporary directory: C:\Windows\Installer\MSI68AC.tmp-\
    CAPACK: Binding to CLR version v2.0.50727
    Calling custom action CAIaaSRequestMPB!Microsoft.SystemCenter.CloudServices.Setup.CustomActionLibrary.CAIaaSRequestMPB.ImportRunbooks
    System.Management.Automation.PSSecurityException: AuthorizationManager check failed.
       at System.Management.Automation.AuthorizationManager.ShouldRunInternal(CommandInfo commandInfo, CommandOrigin origin, PSHost host)
       at System.Management.Automation.CommandDiscovery.ShouldRun(ExecutionContext context, PSHost host, CommandInfo commandInfo, CommandOrigin commandOrigin)
       at System.Management.Automation.CommandDiscovery.LookupCommandProcessor(CommandInfo commandInfo, CommandOrigin commandOrigin, Nullable`1 useLocalScope)
       at System.Management.Automation.CommandDiscovery.LookupCommandProcessor(String commandName, CommandOrigin commandOrigin, Nullable`1 useLocalScope)
       at System.Management.Automation.Runspaces.Command.CreateCommandProcessor(ExecutionContext executionContext, CommandFactory commandFactory, Boolean addToHistory)
       at System.Management.Automation.Runspaces.LocalPipeline.CreatePipelineProcessor()
       at System.Management.Automation.Runspaces.LocalPipeline.InvokeHelper()
       at System.Management.Automation.Runspaces.LocalPipeline.InvokeThreadProc()
    CustomAction _Importrunbooks returned actual error code 1603 (note this may not be 100% accurate if translation happened inside sandbox)
    MSI (s) (94:A0) [21:43:17:947]: NOTE: custom action _Importrunbooks unexpectedly closed the hInstall handle (type MSIHANDLE) provided to it. The custom action should be fixed to not close that handle.
    Action ended 21:43:17: _Importrunbooks. Return value 3.


    Matt White
    ( http://systemcenterblog.hardac.co.uk/ - @matthewwhite )

    Wednesday, February 15, 2012 9:46 PM
  • By the way, if you are having to repeatedly install this, I have worked out how to do it using a command line - no need to run through the pesky wizard again!

    Change to suit:

    C:\source\cloudsvcs\Setup>msiexec /l*vx setup.log /i SCORunbooks.msi SCO_SERVER_NAME=sc2012sql SCO_USER_ACCOUNT="yourAccount" SCO_USER_DOMAIN=YourDomain SCO_USER_PASSWORD="YourPW" SM_CONNECTION=YourSMConnection SCO_DB_NAME=Orchestrator FOLDER_NAME=CloudSvcs ROOTFOLDER="C:\source\cloudsvcs\Setup\SCORunbooks"


    Matt White
    ( http://systemcenterblog.hardac.co.uk/ - @matthewwhite )


    • Edited by Matt White Wednesday, February 15, 2012 9:50 PM
    Wednesday, February 15, 2012 9:50 PM
  • System.Management.Automation.PSSecurityException: AuthorizationManager check failed

    This error is usually down to the PowerShell execution policy check failing. However both my x64 and x86 executionpolicies are set to unrestricted, there are no GPOs in place forcing this, I have checked with get-executionpolicy -List.

    Matt


    Matt White
    ( http://systemcenterblog.hardac.co.uk/ - @matthewwhite )

    Wednesday, February 15, 2012 10:00 PM
  • I'm confused now - after checking the executionpolicy was unrestricted, I removed the digital signature from the ProcessSCORunbook.ps1 file.

    The install failed because the digital signature check failed, so the installer must mandate signature checking.

    I then checked the signature of the ProcessSCORunbook.ps1 file (freshly downloaded) using Get-AuthenticodeSignature and it is valid.

    Really odd.


    Matt White
    ( http://systemcenterblog.hardac.co.uk/ - @matthewwhite )

    Wednesday, February 15, 2012 10:13 PM
  •  

    Hi Sharon,

    I had the exact same error message as you have, error 1603, I checked al my logs and found no PowerShell or registry access issues. unfortunately I cannot say exactly how I solved it because it did three steps:

    First step: add my own account (installation account) to the local OrchestratorSystemGroup;

    Second step: add the service account running the SC Orchestrator services to the local OrchestratorUsersGroup;

    Third step (I strongly sense this might be the issue): I had in Orchestrator 2012 - Runbook designer a checked out runbook (just for fooling around), this runbook I deleted.

     

    Ran the setup again and voila! it installed without issues, I hope this works for you too.

    I can say this specific issue is definitely not a version issues as i run the same setup at home where the install of the CloudService runbooks went fine, and that is using the same versions of Orchestrator, IP's and Service Manager.

    Monday, March 19, 2012 4:03 PM
  • Hi,

    I hadthe same issue today.... you have to "unblock" the 2 powershell file in the Setup\SCORunbooks folder as described at the bottom of this article: http://blogs.technet.com/b/servicemanager/archive/2011/11/10/announcing-system-center-cloud-service-process-pack-beta.aspx

    Kurt


    MCSE: Private Cloud MCITP: Enterprise Administrator 2008 MCITP: Virtualization Administrator 2008 R2 MCSA: Server 2008 MCTS: Configuration Manager 2007, Configuration

    Tuesday, March 12, 2013 5:45 PM
  • Third Step is the key, I just created a runbook checked it out then deleted it and the setup finished with out any errors. I also had done step 1 and 2 in troubleshooting this issue before finding this post.


    • Edited by Rob Plank Wednesday, March 27, 2013 9:20 PM
    Wednesday, March 27, 2013 9:19 PM