This Blog series will take you to the installation and deployment of the D365 (AX) on premises. Once, you have provisioned the On premises Project in LCS , you are good to go with the rest of the things. Microsoft has provided a comprehensive Document on the setup and deployment of  On-Premises  Environments  here .


Before you start the setup, the following prerequisites must be in place. The setup of these prerequisites is out of scope here  .

  1. Active Directory Domain Services (AD DS) must be installed and configured in your network.
  2. AD FS must be deployed.
  3. SQL Server 2016 SP1 must be installed on the Power BI machines.
  4. SQL Server Reporting Services 2016 must be installed in Native mode on the BI machines
  5. SQL server Integrations Services on AOS machines

To help improve the on-prem , deployment a number of power-shell scripts has been provided by the Microsoft ,  go through the pre-reqs sections of the document mentioned above and you will find the list of the software that are installed on the machines by the scripts , in addition to that, scripts will also  add some firewall rules, SSL certificates and other necessary stuff  according the machine types.

Download Scripts

  1.  Sign in to LCS.
  2. On the dashboard, select the Shared asset library tile.
  3. On the Model tab, in the grid, select the Dynamics 365 for Operations on-premises, Enterprise edition – Deployment scripts – Latest row.
  4. Select Versions, and then download the latest version of the zip file for the scripts.
  5. Right-click the zip file, and then select Properties. In the dialog box, select the Unblock check box.
  6. Copy the zip file to the machine that will be used to execute the scripts.
  7. Unzip the files into a folder that is named infrastructure.
  8. Describe configurations

The infrastructure setup scripts use the following configuration files to drive the setup.

  1. infrastructure\ConfigTemplate.xml
  2. infrastructure\D365FO-OP\NodeTopologyDefintion.xml
  3. infrastructure\D365FO-OP\DatabaseTopologyDefintion.xml

infrastructure\ConfigTemplate.xml describes:

  1. Service Accounts that are needed for the application to operate
  2. Certificates necessary for securing communications
  3. Database configuration
  4. Service Fabric cluster configuration

Define your machine configurations in  ConfigTemplate

Altleast three primary Orchestrator Nodes are a must, rest of the node types can be adjusted accordingly


Define gSMA accounts

GSMA Accounts

Create A Records For all AOS and Orch Nodes in DNS , as prescribed in the setup and Deployment Page mentioned above

Scripts for Domain Controller

Create GSMA accounts

Import-Module .\D365FO-OP\D365FO-OP.psd1

New-D365FOGMSAAccounts -ConfigurationFilePath .\ConfigTemplate.xml

Create AXServiceUser user in ADDS


Configure certificates 

Generate self-sign certificates or copy thumbprint of CA generated certificates .

# Create self-signed certs

.\New-SelfSignedCertificates.ps1 -ConfigurationFilePath .\ConfigTemplate.xml



Use these Power Shell Scripts for Copying Thumbprint, don’t use GUI

  1. dir cert:\CurrentUser\My
  2. dir cert:\LocalMachine\My
  3. dir cert:\LocalMachine\Root

Set the generateSelfSignedCert tag to false if not using self-signed certificates


Setup VMs

# Exports the script files to be execute on each VM into a directory VMs\<VMName>.

.\Export-Scripts.ps1 -ConfigurationFilePath .\ConfigTemplate.xml.

at this point you will get vm folder in your infrastructure  directory with all the necessary scripts and SSL certificates categorized in to folders according to the configurations described in the configTemplate.


Download the following Microsoft Windows Installers (MSIs) into a file share that is accessible by all VMs.

  1. SNAC – ODBC driver 
  2. SQL Server Management Studio      
  3. Visual C++ Redistributable Packages for Microsoft Visual Studio 2013   
  4. Access Database Engine 2010 Redistributable

Copy the contents of each infrastructure\VMs<VMName> folder into the corresponding VM, and then run the following scripts.

  1. .\Configure-PreReqs.ps1 -MSIFilePath <path of the MSIs>
  2. .\Add-GMSAOnVM.ps1
  3. .\Import-PfxFiles.ps1
  4. .\Set-CertificateAcls.ps1
  5. .\Test-D365FOConfiguration.ps1

If  Test-D365FOConfiguration.ps1 gives no errors , you are set to install service fabric cluster, on your machines, we will discuss the service fabric cluster installation in our next post.

Leave a Reply

Recent Comments