Download presentation
Presentation is loading. Please wait.
Published byDrusilla Patrick Modified over 6 years ago
1
Trenton Evenson Sr. Support Engineer Dynamics AX - Analytics
Management Reporter Trenton Evenson Sr. Support Engineer Dynamics AX - Analytics
2
Agenda Resetting the Management Reporter data mart
When a rebuild is appropriate How to rebuild Troubleshooting Issues
3
Resetting the data mart
When to rebuild Microsoft Dynamics ERP database is restored from a backup Copying your production ERP and MR databases into a test environment Changes to Dimensions or Calendars could cause need for rebuild Restore - Change Tracking is off and some transactions may not exist Copy – Integration may be configured to different servers
4
Resetting the data mart
How to rebuild - Pre CU15 Remove the Integration Stop the two MR services Delete the DM database Start the two MR services Recreate the Integration and Enable
5
Resetting the data mart
How to rebuild - Post CU15 Make a backup of the ManagementReporter and ManagementReporterDM databases Open PowerShell as an Administrator Navigate to Console folder: cd ‘.\Program Files\Microsoft Dynamics ERP\Management Reporter\2.1\Server\Console\’ 4. Import the module: Import-Module .\Microsoft.Dynamics.Performance.Deployment.Commands.Integration.dll User with dbo rights to MR databases. Deletes all data in MR tables, removes integration logs, removes DM connection information and fix the dates for previous generated reports to be able to properly include transaction detail with the ManagementReporter database.
6
Resetting the data mart
How to rebuild - Post CU15 5. Run the command. (If credentials aren’t supplied, you will be prompted) Reset-DatamartIntegration -Reason BADDATA -ReasonDetail “Restored database from backup” -DatamartDatabaseServer sqlservername -DatamartDatabaseName ManagementReporterDM -DatamartDatabaseUserName sa -DatamartDatabaseUserPassword (ConvertTo-SecureString -AsPlainText -Force) -MRDatabaseServer sqlservername -MRDatabaseName ManagementReporter -MRDatabaseUserName sa -MRDatabaseUserPassword (ConvertTo-SecureString -AsPlainText -Force) *You can run ‘get-help Reset-DatamartIntegration’ for more information 6. Confirm the warning SQL User with dbo rights to MR databases. Deletes all data in MR tables, removes integration logs, removes DM connection information and fixes the dates for previous generated reports to be able to properly include transaction detail.
7
Resetting the data mart
DEMO
8
Troubleshooting Issues
What version of MR are you running? (Help > About) Check for Hotfix installs? Are there any errors in the Event Viewer logs or MR Configuration Console logs on the MR server? MR Status scripts Task Status Data Mart Integration logs
9
Task Status Script select CIG.[Description], STK.[Name], STS.[Progress], CASE STS.[StateType] WHEN 3 THEN '3-Processing' WHEN 5 THEN '5-Complete' WHEN 7 THEN '7-Error' END AS StateType, DATEADD(minute, DATEDIFF(minute,GETUTCDATE(),GETDATE()), STS.[LastRunTime]) as LocalLastRunTime, DATEADD(minute, DATEDIFF(minute,GETUTCDATE(),GETDATE()), STS.[NextRunTime]) as LocalNextRunTime, STRG.[Interval], CASE STRG.[UnitOfMeasure] WHEN 1 THEN 'Seconds' WHEN 2 THEN 'Minutes' WHEN 3 THEN 'Hours' WHEN 4 THEN 'Days' END AS UnitOfMeasure, STRG.[IsEnabled] from [Scheduling].[Task] STK with (nolock) inner join [Scheduling].[TaskState] STS with (nolock) on STK.[Id] = STS.[TaskId] inner join [Connector].[IntegrationGroup] CIG with (nolock) on CIG.[IntegrationId] = STK.[CategoryId] inner join [Scheduling].[Trigger] STRG with (nolock) on STK.[TriggerId] = STRG.[Id] order by CIG.[Description], STK.[Name]
10
Data Mart Integration Status Script
select top(1000) b.Name, c.Text, DATEADD(minute, DATEDIFF(minute,GETUTCDATE(),GETDATE()), a.StartTime) as LocalStartTime, DATEADD(minute, DATEDIFF(minute,GETUTCDATE(),GETDATE()), a.EndTime) as LocalEndTime, a.TotalRetryNumber, a.IsFailed, d.Name as TaskType from [Scheduling].[Log] a inner join [Scheduling].[Task] b on a.TaskId = b.Id inner join [Scheduling].[Message] c on a.Id = c.LogId inner join [Scheduling].[TaskType] d on b.TypeId = d.Id where a.StartTime > (select DATEADD(DAY, -8, GETDATE())) --and c.Text like '%Error%' order by LocalStartTime desc
11
Questions? Trenton Evenson Microsoft
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.