-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Description
Description
A bug in the createdump tool which causes double crash dumps to be created for a single crash when running in a Linux container in Kubernetes.
Reproduction Steps
https://github.com/kristjanjogi-msft/createdump-doubledump-bug
Prerequites
- .NET 7 SDK
- Docker Desktop with Linux containers and Kubernetes support
Steps:
-
Clone the repository:
git clone https://github.com/kristjanjogi-msft/createdump-doubledump-bug.git -
cd createdump-doubledump-bug -
Build and publish the crashing application:
dotnet publish -c Release -o published CrashingApplication/CrashingApplication.csproj -
Build the Docker image:
docker build -t crashingapplication:1.0 . -
Run a Kubernetes pod in which the createdump tool creates two crash dumps for a single crash:
kubectl apply -f doubledump.yaml -
View the evidence, two crash dumps instead of one are created:
kubectl logs doubledump
Hello, World!
Unhandled exception. System.Exception: Crash
at Program.<Main>$(String[] args) in [redacted]\createdump-doubledump-bug\CrashingApplication\Program.cs:line 4
[createdump] Gathering state for process 1 dotnet
[createdump] Crashing thread 00000001 signal 00000006
[createdump] Writing full dump to file /tmp/crashdump.1.1669709005
[createdump] Written 220954624 bytes (53944 pages) to core file
[createdump] Target process is alive
[createdump] Dump successfully written in 186ms
[createdump] Gathering state for process 1 dotnet
[createdump] Crashing thread 00000001 signal 0000000b
[createdump] Writing full dump to file /tmp/crashdump.1.1669709006
[createdump] Written 220954624 bytes (53944 pages) to core file
[createdump] Target process is alive
[createdump] Dump successfully written in 222ms
Expected behavior
One crash dump is created for a single crash.
Actual behavior
Two crash dumps are created for a single crash.
Regression?
No response
Known Workarounds
No response
Configuration
root@doubledump:/app# dotnet --info
Host:
Version: 7.0.0
Architecture: x64
Commit: d099f075e4
.NET SDKs installed:
No SDKs were found.
.NET runtimes installed:
Microsoft.AspNetCore.App 7.0.0 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 7.0.0 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
Other architectures found:
None
Environment variables:
Not set
global.json file:
Not found
Learn more:
https://aka.ms/dotnet/info
Download .NET:
https://aka.ms/dotnet/download
Other information
No response