Skip to content

.NET 7 - Process terminated. Error while reaping child. errno = 10 #79540

@JaroslavMajera

Description

@JaroslavMajera

Description

Hello. We have a cloud docker microservice which runs headless chromium in process. When we switch to .NET 7 we have encountered Process terminated. Error while reaping child. errno = 10 during killing chromium process. We cannot reproduce this behavior with .NET 6. I have prepared repro https://github.com/JaroslavMajera/DotNetReaper.

Thanks

Reproduction Steps

  1. Prepare Dockerfile which periodically runs chromium or maybe something else which spawns child processes.
  2. Start chromium process
  3. Call Process.Kill a Process.WaitForExit()
  4. Repeat

Source code: DotNetReaper-main.zip

Expected behavior

No Exception and chromium is successfully killed

Actual behavior

Sometimes we get

Process terminated. Error while reaping child. errno = 10 at System.Environment.FailFast(System.String) at System.Diagnostics.ProcessWaitState.TryReapChild(Boolean) at System.Diagnostics.ProcessWaitState.CheckChildren(Boolean, Boolean) at System.Diagnostics.Process.OnSigChild(Int32, Int32)

Regression?

Cannot reproduce on .NET 6

Known Workarounds

No response

Configuration

  • .NET 7
  • Docker image mcr.microsoft.com/dotnet/aspnet:7.0-bullseye-slim
  • Chromium 108

Other information

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions