Setup and Activate Store Commerce on D365 F&O VHD 10.0.41 on-prem

Hello F&O Commerce Community!

With latest release of 10.0.41 VHD Microsoft has removed the pre installed commerce components from the VM.

It is now required to install the self hosted CSU (IIS) on VHD. Although there is a Microsoft document explaining step by step setup but @Valery Plotnik created a powershell script to simplify the setup that saves lot of time. But Valery is using Cloud hosted VM which has some differences to the on-prem VHD. So we will follow all of the Valery’s steps but I’ll point out the things that are to be done differently for on-prem VHD.

Link to Valery’s blog and Youtube Video:

https://www.linkedin.com/pulse/install-commerce-scale-unit-development-environment-valery-plotnik-mgjcc

Dzmitry Alabin highlighted some of the points that are required for VHD to be done but he is using 10.0.37 VHD which has preinstalled commerce components, so I took few points that are applicable to us from his blog: 

https://www.linkedin.com/pulse/adjustments-required-install-commerce-scale-unit-vhd-dzmitry-alabin-3mz7f

Here are some of the things that are done differently on on-prem VHD:

1. Export the AADCLIENT certificate and import on Azure Portal

Export Certificate “aadclient-onebox-locator1-dynamics-com” under trusted root certificates (manage computer certificates) and import under the App in Microsoft Entra ID on Azure Portal with which you activated the VM (ie with which you Ran “Generate Self Signed Certificates”)

2. Run the Graph Install a bit differently.

Install-Module Microsoft.Graph -RequiredVersion 2.9.0 -Force -AllowClobber

3. Add these registry entries with Powershell

# Setting SystemDefaultTlsVersions and SchUseStrongCrypto for .NET Framework v2.0.50727

New-ItemProperty -Path "HKLM:SOFTWARE\Microsoft.NETFramework\v2.0.50727" -Name "SystemDefaultTlsVersions" -Value "0000001" -PropertyType "dword"
New-ItemProperty -Path "HKLM:SOFTWARE\Microsoft.NETFramework\v2.0.50727" -Name "SchUseStrongCrypto" -Value "0000001" -PropertyType "dword"
New-ItemProperty -Path "HKLM:SOFTWARE\Wow6432Node\Microsoft.NETFramework\v2.0.50727" -Name "SystemDefaultTlsVersions" -Value "0000001" -PropertyType "dword"
New-ItemProperty -Path "HKLM:SOFTWARE\Wow6432Node\Microsoft.NETFramework\v2.0.50727" -Name "SchUseStrongCrypto" -Value "0000001" -PropertyType "dword"

4. Edit the web.config in C:\AOSService\webroot\web.config This will help you download the Channel Database Setup File

Now you should be able to Download the Configuration File for Channel Database

5. After installation of CSU perform these steps:

You might face an error on Running 9999 Distribution Schedule. Run it after below initialize steps.

Run Init From Commerece Parameters
Run Intialize Commerce Scheduler
Run 9999 Distribution Schedule

Let me know if there are any questions or if there’s anything missing while you try to setup, appreciate your feedback.

Thank You for reading!

Leave a Comment

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

Scroll to Top