Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Issue] ExchangeLogCollector fails to collect Daily Performance Logs if the location was changed #2023

Open
lusassl-msft opened this issue Feb 23, 2024 · 0 comments
Labels
Exchange Log Collector Issue Triage Needs to be discussed to determine how to handle

Comments

@lusassl-msft
Copy link
Contributor

Describe the issue
ExchangeLogCollector fails to collect the DailyPerformanceLogs if a customer changes the path to a non-default one.

Expected behavior
Script should be able to collect the daily performance logs even if the path was changed.
We should decide if this is something we want to support or if we want to show a warning instead.

Additional context
This is, because we're using a static path:

        if ($PassedInfo.DailyPerformanceLogs) {
            #Daily Performance Logs are always by days worth
            $copyFrom = "$Script:localExInstall`Logging\Diagnostics\DailyPerformanceLogs"

            try {
                $logmanOutput = logman ExchangeDiagnosticsDailyPerformanceLog
                $logmanRootPath = $logmanOutput | Select-String "Root Path:"

                if (!$logmanRootPath.ToString().Contains($copyFrom)) {
                    $copyFrom = $logmanRootPath.ToString().Replace("Root Path:", "").Trim()
                    Write-Verbose "Changing the location to get the daily performance logs to '$copyFrom'"
                }
            } catch {
                Write-Verbose "Couldn't get logman info to verify Daily Performance Logs location"
                Invoke-CatchActions
            }
            Add-LogCopyBasedOffTimeTaskAction $copyFrom "Daily_Performance_Logs"
        }
@lusassl-msft lusassl-msft added Issue Exchange Log Collector Triage Needs to be discussed to determine how to handle labels Feb 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Exchange Log Collector Issue Triage Needs to be discussed to determine how to handle
Projects
None yet
Development

No branches or pull requests

1 participant