Scripting Agent Initialization Failed: “File is not found” Error During Exchange 2016 Setup

Scripting Agent Initialization Failed: "File is not found" error came up during an Exchange 2016 Setup into an existing Exchange 2010 environment. 

More...

The error message is descriptive enough to make us understand that it is something to do with scripting agent within the Exchange environment. The scripting agent is not one of those features that every organization uses either. 

Preparing Setup COMPLETED
Stopping Services COMPLETED
Copying Exchange Files COMPLETED
Language Files COMPLETED
Restoring Services COMPLETED
Language Configuration COMPLETED
Exchange Management Tools FAILED
The following error was generated when "$error.Clear();
Set-WERRegistryMarkers;
" was run: "Microsoft.Exchange.Provisioning.ProvisioningBrokerException: Provisioning layer
initialization failed: '"Scripting Agent initialization failed: "File is not found: 'C:\Program File
s\Microsoft\Exchange Server\V15\Bin\CmdletExtensionAgents\ScriptingAgentConfig.xml'.""' ---> Microso
ft.Exchange.Provisioning.ProvisioningException: "Scripting Agent initialization failed: "File is not
found: 'C:\Program Files\Microsoft\Exchange Server\V15\Bin\CmdletExtensionAgents\ScriptingAgentConf
ig.xml'."" ---> System.IO.FileNotFoundException: "File is not found: 'C:\Program Files\Microsoft\Exc
hange Server\V15\Bin\CmdletExtensionAgents\ScriptingAgentConfig.xml'."
at Microsoft.Exchange.ProvisioningAgent.ScriptingAgentConfiguration.Initialize(String xmlConfigPa
th)
at Microsoft.Exchange.ProvisioningAgent.ScriptingAgentConfiguration..ctor(String xmlConfigPath)
--- End of inner exception stack trace ---

The issue here is that the Exchange 2010 has scripting agent enabled and while running the 2016 setup, it is expecting the "ScriptingAgentConfig.xml" file within the folder structure of the Exchange 2016 server.

There are two ways we can go about solving the issue.

First solution is to :

  • check
    Disable the scripting agent temporarily using the Exchange 2010 Shell (run Disable-CmdletExtensionAgent "Scripting Agent").
  • check
    Re-run Exchange 2016 setup.
  • check
    Enable the scripting agent back by running Enable-CmdletExtensionAgent "Scripting Agent" from the Shell. 

Second solution is to :

  • check
    Copy the "ScriptingAgentConfig.xml" file from one of the Exchange 2010 servers. The location is C:\Program Files\Microsoft\Exchange Server\V14\Bin\CmdletExtensionAgents, assuming that Exchange 2010 is installed on the C drive. 
  • check
    Paste it into the Exchange 2016 server that is giving the error, the location is C:\Program Files\Microsoft\Exchange Server\V15\Bin\CmdletExtensionAgents, assuming that Exchange 2016 is getting installed on the C drive.
  • check
    Re-run the Exchange 2016 setup.

Have you come across this error at all? Any other workarounds to get past the error?

Leave a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.