microsoft / microsoft/ProcDump-for-Linux

Make -s switch behavior consistent with Windows version

Open
#121 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
C
Stars
3.1k
Forks
327
Avg merge
3d 10h
Merged PRs (30d)
7

Description

The -s switch needs to behave as the Windows version. On Windows, the -s switch states to only generate a dump if the condition was true throughout the -s interval. On Linux version, we generate a core dump immediately when the condition triggers and then wait for -s interval.

Here is an example of Windows:

Write up to 3 mini dumps of a process named 'consume' when it exceeds 20% CPU usage for five seconds:

C:>procdump -c 20 -s 5 -n 3 consume

So, we need to pull the metrics multiple times throughout the -s time period and only generate if they all satisfied the threshold.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the Linux implementation of the -s switch and its metric-sampling path, then compare its timing with the Windows behavior described in the issue. The work is done when metrics are sampled throughout the -s interval and a dump is generated only if every sample satisfies the threshold, while the example command behaves consistently.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, linux
Domain
cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.