Edit

Share via


Microsoft Dynamics 365 Finance + Operations (on-premises) automated diagnostics collection

This article explains how to quickly collect information that's required to troubleshoot issues in your environment. Diagnostics collection uses a new set of PowerShell scripts that are available as of version 2.19.0 of the infrastructure scripts. For more information about how to update your scripts, see Update the infrastructure scripts.

The new scripts don't replace other scripts, such as Test-ADFSConfiguration.ps1 or Test-D365FOConfiguration.ps1. Instead, they're intended to complement those scripts. Eventually, those other scripts will be updated so that they generate output in a similar format to the new scripts.

The new scripts only collect information that's required to troubleshoot issues in your environment. They don't perform any troubleshooting or remediation steps.

Important

The scripts collect information from your environment and conveniently package it for analysis by Microsoft. However, the scripts don't send any information to Microsoft. You must manually provide the information to Microsoft by using a support ticket.

Collect node-specific diagnostics

To collect information from a specific node, you can use the following command.

.\Get-NodeSpecificDiagnostics.ps1

Note

This script requires machine-specific information to run. Therefore, it's part of the scripts that are exported as part of the Export-Scripts.ps1 script and pushed to the machine by using the remoting scripts.

By default, this script creates a directory at the same level as the script. This directory is named Diagnostics, and it contains the following information:

  • Event Tracing for Windows (ETW) events that have been exported. These events contain any publishers that are related to Microsoft Dynamics 365 Finance + Operations (on-premises). A subset of security and application logs is also exported.
  • For all Azure Service Fabric applications that are deployed on the node, any logs that have been generated by the applications. These logs are exported, as are the latest health events that each application has generated in the node.

If you don't use remoting to collect information from multiple nodes, and you must provide information from multiple nodes to Microsoft, make sure that you manually copy the Diagnostics directory from each node. Then zip the directories into a single file, and provide it to Microsoft.

Collect node-specific diagnostics by using remoting

To collect information from all nodes in your Service Fabric cluster, you can use the following command.

.\Get-NodeSpecificDiagnostics-AllVMs.ps1 -ConfigurationFilePath .\ConfigTemplate.xml

This script invokes the Get-NodeSpecificDiagnostics.ps1 script on each node in the cluster. The output that the script generates is collected from each node and put in a Diagnostics directory on that node. The Diagnostics directory is at the same level as the Get-NodeSpecificDiagnostics-AllVMs.ps1 script.

If you want to collect information from a subset of nodes, you can use the -MachinesToCollectFrom parameter. For example, to collect information from nodes Node1 and Node2, you can use the following command.

.\Get-NodeSpecificDiagnostics-AllVMs.ps1 -ConfigurationFilePath .\ConfigTemplate.xml -MachinesToCollectFrom @("Node1", "Node2")

Collect general diagnostics

To collect general diagnostics information, you can use the following command.

.\Get-GeneralDiagnostics.ps1 -ConfigurationFilePath .\ConfigTemplate.xml

This script isn't node-specific, and it doesn't have to be run on each node or exported to each node. To collect as much information as possible, you should invoke this script on a node that belongs to the Service Fabric cluster. The account that you use to run the script should have privileges to connect to your SQL Server instance and your FileShare server. The output of this script is put in a Diagnostics directory at the same level as the script.

The following information is collected:

  • Information about your Service Fabric cluster.
  • Information about your SQL Server version.
  • Information from your SQL Server database that's related to deployment operations. No customer data is collected.
  • Information from your file shares that's related to deployment operations. No customer data is collected.
  • Information about your infrastructure scripts.

Provide the diagnostics information to Microsoft

After you've collected the diagnostics information, follow these steps to provide it to Microsoft.

  1. Create a new support request through Microsoft Dynamics Lifecycle Services.
  2. Find the Diagnostics directory that the scripts created. Then zip the directory.
  3. When a support engineer prompts you to provide logs, upload the zip file to the secure file upload location that the support engineer provides.