Skip to content

test(service-test): capture user-mode dumps on SCM-kill via SilentProcessExit#51168

Draft
clarkb7 wants to merge 1 commit into
mainfrom
branden.clark/startstop-silentprocessexit
Draft

test(service-test): capture user-mode dumps on SCM-kill via SilentProcessExit#51168
clarkb7 wants to merge 1 commit into
mainfrom
branden.clark/startstop-silentprocessexit

Conversation

@clarkb7
Copy link
Copy Markdown
Contributor

@clarkb7 clarkb7 commented May 21, 2026

What does this PR do?

Enables SilentProcessExit for the agent service binaries so SCM-kills (start/stop timeouts) produce a user-mode minidump. Extends ListWERDumps / parseWERDumpFilePath to also pick up the SilentProcessExit on-disk layout so the existing collection path works unchanged.

Motivation

WINA-2707: installer hung in early Go-runtime init and SCM killed it after 30 s. WER LocalDumps only fires on unhandled exceptions, DD_CRASH_ON_HARDSTOP_TIMEOUT requires the service handler to be registered, and the kernel LiveDump.dmp (#50964) is taken minutes after the user-mode process is gone. SilentProcessExit dumps from inside NtTerminateProcess while threads are still walkable.

Configure the agent service binaries (datadog-installer.exe, agent.exe,
trace-agent.exe, process-agent.exe, security-agent.exe, system-probe.exe)
for Windows SilentProcessExit monitoring so SCM start/stop timeouts produce
a user-mode minidump of the hung process. WER LocalDumps only covers
unhandled-exception crashes, leaving externally-initiated TerminateProcess
calls (which is how SCM kills hung services) without a dump.

IgnoreSelfExits=1 keeps normal Stop iterations quiet. DumpType=2 (full
memory) so Go runtime state is recoverable for early-startup hangs.

SilentProcessExit dumps land in <LocalDumpFolder>\<image>-(PID-<pid>)-<seq>\
rather than flat alongside WER dumps. Extend ListWERDumps to walk one level
deep and parseWERDumpFilePath to recognize the "<image>-(PID-<pid>).dmp"
filename format so the existing DownloadAllWERDumps collection picks them
up without changes at the call site.
@clarkb7 clarkb7 added changelog/no-changelog No changelog entry needed qa/no-code-change No code change in Agent code requiring validation team/windows-products labels May 21, 2026
@github-actions
Copy link
Copy Markdown
Contributor

@codex review

@dd-octo-sts dd-octo-sts Bot added the internal Identify a non-fork PR label May 21, 2026
@github-actions github-actions Bot added the short review PR is simple enough to be reviewed quickly label May 21, 2026
@datadog-datadog-prod-us1-2
Copy link
Copy Markdown
Contributor

datadog-datadog-prod-us1-2 Bot commented May 21, 2026

Pipelines

Fix all issues with BitsAI

⚠️ Warnings

🚦 3 Pipeline jobs failed

CLA Assistant | CLAAssistant   View in Datadog   GitHub Actions

🔄 Retry job. This looks flaky and may succeed on retry. GraphQL call to get committers details failed: HttpError. Received HTML response from GitHub instead of expected data.

DataDog/datadog-agent | oracle: [21.3.0-xe]   View in Datadog   GitLab

🛟 This job is unlikely to succeed on retry. Please review your pipeline configuration. Failed to ping Oracle instance: ORA-12514: TNS:listener does not currently know of service requested in connect descriptor.

DataDog/datadog-agent | unit_tests_notify   View in Datadog   GitLab

🛟 This job is unlikely to succeed on retry. Please review your pipeline configuration. Command 'ls junit-tests_*.tgz' failed: No such file or directory.

Useful? React with 👍 / 👎

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: c148b4e | Docs | Datadog PR Page | Give us feedback!

@chatgpt-codex-connector
Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Hooray!

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@dd-octo-sts
Copy link
Copy Markdown
Contributor

dd-octo-sts Bot commented May 21, 2026

Files inventory check summary

File checks results against ancestor 90df1df6:

Results for datadog-agent_7.81.0~devel.git.146.c148b4e.pipeline.114520302-1_amd64.deb:

No change detected

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/no-changelog No changelog entry needed internal Identify a non-fork PR qa/no-code-change No code change in Agent code requiring validation short review PR is simple enough to be reviewed quickly team/windows-products

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant