# dotnet tool install -g dotnet-trace
You can invoke the tool using the following command: dotnet-trace
Tool 'dotnet-trace' (version '10.0.745401') was successfully installed.
# dotnet trace ps
System.IO.IOException: No such process : '/proc/2/environ'
at Interop.ThrowExceptionForIoErrno(ErrorInfo errorInfo, String path, Boolean isDirError)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String path, OpenFlags flags, Int32 mode, Boolean failForSymlink, Boolean& wasSymlink, Func`4 createOpenException)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, UnixFileMode openPermissions, Int64& fileLength, UnixFileMode& filePermissions, Boolean failForSymlink, Boolean& wasSymlink, Func`4 createOpenException)
at System.IO.File.OpenHandle(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
at System.IO.File.ReadAllBytes(String path)
at Microsoft.Diagnostics.NETCore.Client.PidIpcEndpoint.GetProcessTmpDir(Int32 hostPid, Boolean& environReadable) in /_/src/Microsoft.Diagnostics.NETCore.Client/DiagnosticsIpc/IpcTransport.cs:line 437
at Microsoft.Diagnostics.NETCore.Client.DiagnosticsClient.GetProcPublishedProcesses() in /_/src/Microsoft.Diagnostics.NETCore.Client/DiagnosticsClient/DiagnosticsClient.cs:line 512
at Microsoft.Diagnostics.NETCore.Client.DiagnosticsClient.GetPublishedProcesses() in /_/src/Microsoft.Diagnostics.NETCore.Client/DiagnosticsClient/DiagnosticsClient.cs:line 420
at Microsoft.Internal.Common.Commands.ProcessStatusCommandHandler.ProcessStatus(TextWriter stdOut, TextWriter stdError) in /_/src/Tools/Common/Commands/ProcessStatus.cs:line 123
# dotnet tool uninstall -g dotnet-trace
Tool 'dotnet-trace' (version '10.0.745401') was successfully uninstalled.
# dotnet tool install --global dotnet-trace --version 9.0.661903
You can invoke the tool using the following command: dotnet-trace
Tool 'dotnet-trace' (version '9.0.661903') was successfully installed.
# dotnet trace ps
12419 dotnet /usr/lib64/dotnet/dotnet dotnet trace ps
# dotnet --info
.NET SDK:
Version: 10.0.111
Commit: e2f47b0110
Workload version: 10.0.100-manifests.330ea142
MSBuild version: 18.0.11+e2f47b011
Runtime Environment:
OS Name: fedora
OS Version: 43
OS Platform: Linux
RID: fedora.43-x64
Base Path: /usr/lib64/dotnet/sdk/10.0.111/
.NET workloads installed:
There are no installed workloads to display.
Configured to use workload sets when installing new manifests.
No workload sets are installed. Run "dotnet workload restore" to install a workload set.
Host:
Version: 10.0.11
Architecture: x64
Commit: e2f47b0110
.NET SDKs installed:
10.0.111 [/usr/lib64/dotnet/sdk]
.NET runtimes installed:
Microsoft.AspNetCore.App 10.0.11 [/usr/lib64/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 10.0.11 [/usr/lib64/dotnet/shared/Microsoft.NETCore.App]
Other architectures found:
None
Environment variables:
DOTNET_BUNDLE_EXTRACT_BASE_DIR [/root/.cache/dotnet_bundle_extract]
DOTNET_ROOT [/usr/lib64/dotnet]
global.json file:
Not found
Learn more:
https://aka.ms/dotnet/info
Download .NET:
https://aka.ms/dotnet/download
Yes. 9.0.661903 worked.
Description
I sometimes run
dotnet traceas root (uid 0) under Linux. Recent versions ofdotnet tracefail to run in this setup. Older versions ofdotnet tracework fine.Configuration
dotnet trace. It may nor may not affect other tools.rootinside a VM.dotnet trace psby itself demostrates the problem.dotnet --infoI also see this with 10.0.112
Regression?
Yes. 9.0.661903 worked.
Other information