Skip to content

Powershell 7.5.1 crashes upon startup #25530

@JohnicBoom

Description

@JohnicBoom

Prerequisites

Steps to reproduce

PowerShell crashes upon startup. I get some text in the window:
Image
and then the window closes.

Two events are created in Event Viewer. The first: The Source is .NET Runtime:

Application: pwsh.exe
CoreCLR Version: 9.0.425.16305
.NET Version: 9.0.4
Description: The process was terminated due to an internal error in the .NET Runtime at IP 0x00007FFBE1572E28 (0x00007FFBE14F0000) with exit code 0x80131506.

Right after that one, there is this one with the source: Application Error:

Faulting application name: pwsh.exe, version: 7.5.1.500, time stamp: 0x67d30000
Faulting module name: coreclr.dll, version: 9.0.425.16305, time stamp: 0x67d355a6
Exception code: 0xc0000005
Fault offset: 0x0000000000082e28
Faulting process id: 0x60D8
Faulting application start time: 0x1DBC060E564EFCE
Faulting application path: C:\Program Files\WindowsApps\Microsoft.PowerShell_7.5.1.0_x64__8wekyb3d8bbwe\pwsh.exe
Faulting module path: C:\Program Files\WindowsApps\Microsoft.PowerShell_7.5.1.0_x64__8wekyb3d8bbwe\coreclr.dll
Report Id: 9bb2c466-2ee9-4cb8-b37c-120144b65090
Faulting package full name: Microsoft.PowerShell_7.5.1.0_x64__8wekyb3d8bbwe
Faulting package-relative application ID: App

I uninstalled and reinstalled from the Microsoft Store and had the same experience. Uninstalled and tried again using the MSI from here (GitHub - PowerShell-7.5.1-win-x64.msi) and had the same experience.

Installing 7.5.0 also crashes, but gives me the following extra text (:

[process exited with code 3221225477 (0xc0000005)]
You can now close this terminal with Ctrl+D, or press Enter to restart.

Image

Installing 7.6.4-preview.4 crashes the same way:
Image

Installing 7.4.7 runs totally fine.

Here is the WinDbg analysis of the minidump that was created on a crash trying to open 7.5.1:

************* Preparing the environment for Debugger Extensions Gallery repositories **************
   ExtensionRepository : Implicit
   UseExperimentalFeatureForNugetShare : true
   AllowNugetExeUpdate : true
   NonInteractiveNuget : true
   AllowNugetMSCredentialProviderInstall : true
   AllowParallelInitializationOfLocalRepositories : true
   EnableRedirectToChakraJsProvider : false

   -- Configuring repositories
      ----> Repository : LocalInstalled, Enabled: true
      ----> Repository : UserExtensions, Enabled: true

>>>>>>>>>>>>> Preparing the environment for Debugger Extensions Gallery repositories completed, duration 0.000 seconds

************* Waiting for Debugger Extensions Gallery to Initialize **************

>>>>>>>>>>>>> Waiting for Debugger Extensions Gallery to Initialize completed, duration 0.031 seconds
   ----> Repository : UserExtensions, Enabled: true, Packages count: 0
   ----> Repository : LocalInstalled, Enabled: true, Packages count: 44

Microsoft (R) Windows Debugger Version 10.0.27829.1001 AMD64
Copyright (c) Microsoft Corporation. All rights reserved.


Loading Dump File [C:\Users\JohnPappas\AppData\Local\CrashDumps\pwsh.exe.24792.dmp]
User Mini Dump File: Only registers, stack and portions of memory are available

Symbol search path is: srv*
Executable search path is: 
Windows 10 Version 26100 MP (14 procs) Free x64
Product: WinNt, suite: SingleUserTS
Edition build lab: 26100.1.amd64fre.ge_release.240331-1435
Debug session time: Thu May  8 16:33:56.000 2025 (UTC - 5:00)
System Uptime: 0 days 8:23:40.559
Process Uptime: 0 days 0:00:03.000
................................................................
................................................................
.............................................
This dump file has an exception of interest stored in it.
The stored exception information can be accessed via .ecxr
(60d8.65f4): Access violation - code c0000005 (first/second chance not available)

+------------------------------------------------------------------------+
| This target supports Hardware-enforced Stack Protection. A HW based    |
| "Shadow Stack" may be available to assist in debugging and analysis.   |
| See aka.ms/userhsp for more info.                                      |
|                                                                        |
| dps @ssp                                                               |
|                                                                        |
+------------------------------------------------------------------------+

For analysis of this file, run !analyze -v
coreclr!isJumpRel64:
00007ffb`e1572e28 803948          cmp     byte ptr [rcx],48h ds:00000000`00000000=??
0:024> !analyze -v
................................................................
................................................................
....................
ClrmaManagedAnalysis::AssociateClient
Loading extension C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2504.15001.0_x64__8wekyb3d8bbwe\amd64\winext\sos\extensions\Microsoft.Diagnostics.DataContractReader.dll
Loading extension C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2504.15001.0_x64__8wekyb3d8bbwe\amd64\winext\sos\extensions\Microsoft.Diagnostics.DataContractReader.Extension.dll
Loading extension C:\Program Files\WindowsApps\Microsoft.WinDbg_1.2504.15001.0_x64__8wekyb3d8bbwe\amd64\winext\sos\extensions\Microsoft.Diagnostics.DebuggerCommands.dll
AssociateClient trying managed CLRMA
AssociateClient trying DAC CLRMA
*** WARNING: Unable to verify timestamp for ntd1l.dll
*** WARNING: Unable to verify timestamp for kern3l32.dll
*******************************************************************************
*                                                                             *
*                        Exception Analysis                                   *
*                                                                             *
*******************************************************************************

ClrmaManagedAnalysis::GetThread 65f4
ClrmaThread::Initialize 65f4
ClrmaThread::Initialize GetThreadStoreData FAILED 80131c49
~ClrmaThread
ClrmaManagedAnalysis::get_ProviderName
ClrmaManagedAnalysis::GetThread ffffffff
ClrmaThread::Initialize 65f4
ClrmaThread::Initialize GetThreadStoreData FAILED 80131c49
~ClrmaThread
Failed to request MethodData, not in JIT code range
Failed to request MethodData, not in JIT code range
Failed to request MethodData, not in JIT code range
Failed to request MethodData, not in JIT code range
Failed to request MethodData, not in JIT code range

KEY_VALUES_STRING: 1

    Key  : AV.Dereference
    Value: NullPtr

    Key  : AV.Type
    Value: Read

    Key  : Analysis.CPU.mSec
    Value: 6500

    Key  : Analysis.Elapsed.mSec
    Value: 101550

    Key  : Analysis.IO.Other.Mb
    Value: 68

    Key  : Analysis.IO.Read.Mb
    Value: 3

    Key  : Analysis.IO.Write.Mb
    Value: 207

    Key  : Analysis.Init.CPU.mSec
    Value: 1296

    Key  : Analysis.Init.Elapsed.mSec
    Value: 21233

    Key  : Analysis.Memory.CommitPeak.Mb
    Value: 330

    Key  : Analysis.Version.DbgEng
    Value: 10.0.27829.1001

    Key  : Analysis.Version.Description
    Value: 10.2503.24.01 amd64fre

    Key  : Analysis.Version.Ext
    Value: 1.2503.24.1

    Key  : CLR.Engine
    Value: CORECLR

    Key  : CLR.Version
    Value: 9.0.425.16305

    Key  : Failure.Bucket
    Value: INVALID_POINTER_READ_c0000005_coreclr.dll!isJumpRel64

    Key  : Failure.Exception.Code
    Value: 0xc0000005

    Key  : Failure.Exception.IP.Address
    Value: 0x7ffbe1572e28

    Key  : Failure.Exception.IP.Module
    Value: coreclr

    Key  : Failure.Exception.IP.Offset
    Value: 0x82e28

    Key  : Failure.Hash
    Value: {29b57f72-2faf-befd-645c-67aa12225b7f}

    Key  : Failure.ProblemClass.Primary
    Value: INVALID_POINTER_READ

    Key  : Timeline.OS.Boot.DeltaSec
    Value: 30220

    Key  : Timeline.Process.Start.DeltaSec
    Value: 3

    Key  : WER.OS.Branch
    Value: ge_release

    Key  : WER.OS.Version
    Value: 10.0.26100.1

    Key  : WER.Process.Version
    Value: 7.5.1.500


FILE_IN_CAB:  pwsh.exe.24792.dmp

NTGLOBALFLAG:  0

APPLICATION_VERIFIER_FLAGS:  0

CONTEXT:  (.ecxr)
rax=0000000000000000 rbx=0000009fa6b49870 rcx=0000000000000000
rdx=0000000000000000 rsi=0000009fa6b490e0 rdi=0000009fa6b49380
rip=00007ffbe1572e28 rsp=0000009fa6b49aa8 rbp=0000009fa6b49c40
 r8=00007ffbe1643fb0  r9=00007ffbe1888540 r10=00007ffb81babde0
r11=0000000000000000 r12=0000024a565eee50 r13=0000028ae8765950
r14=0000000000000000 r15=0000024a565ee250
iopl=0         nv up ei ng nz na po cy
cs=0033  ss=002b  ds=002b  es=002b  fs=0053  gs=002b             efl=00010285
coreclr!isJumpRel64:
00007ffb`e1572e28 803948          cmp     byte ptr [rcx],48h ds:00000000`00000000=??
Resetting default scope

EXCEPTION_RECORD:  (.exr -1)
ExceptionAddress: 00007ffbe1572e28 (coreclr!isJumpRel64)
   ExceptionCode: c0000005 (Access violation)
  ExceptionFlags: 00000001
NumberParameters: 2
   Parameter[0]: 0000000000000000
   Parameter[1]: 0000000000000000
Attempt to read from address 0000000000000000

PROCESS_NAME:  pwsh.exe

READ_ADDRESS:  0000000000000000 

ERROR_CODE: (NTSTATUS) 0xc0000005 - The instruction at 0x%p referenced memory at 0x%p. The memory could not be %s.

EXCEPTION_CODE_STR:  c0000005

EXCEPTION_PARAMETER1:  0000000000000000

EXCEPTION_PARAMETER2:  0000000000000000

STACK_TEXT:  
0000009f`a6b49aa8 00007ffb`e1572e11     : 0000024a`54021a08 00007ffb`81b52be0 0000028a`e8765950 00007ffb`81934000 : coreclr!isJumpRel64
0000009f`a6b49ab0 00007ffb`e1572ddb     : 00000000`00000003 00007ffb`dae5c363 0000024a`565ee250 00000000`00000000 : coreclr!Precode::IsPointingTo+0x11
0000009f`a6b49ae0 00007ffb`e177c90e     : 00007ffb`81b52be0 00000000`00000000 00007ffb`81b52be0 0000028a`e8765950 : coreclr!Precode::IsPointingToPrestub+0x13
0000009f`a6b49b10 00007ffb`e177d61f     : 00007ffb`81b52da0 00000000`00000000 00007ffb`e152f0b7 0000024a`565eeec8 : coreclr!PrepareMethodHelper+0x16
0000009f`a6b49b40 00007ffb`dae11842     : 00000000`00000000 0000024a`540352e0 00000000`00000000 00000000`00000000 : coreclr!ReflectionInvocation_PrepareMethod+0x1ef
0000009f`a6b49be0 00007ffb`81a73a69     : 0000024a`540352e0 00000000`00000000 00007ffb`81c41878 00007ffb`81c41008 : System_Private_CoreLib+0x421842
0000009f`a6b49d30 0000024a`540352e0     : 00000000`00000000 00007ffb`81c41878 00007ffb`81c41008 00000001`540164f0 : 0x00007ffb`81a73a69
0000009f`a6b49d38 00000000`00000000     : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : 0x0000024a`540352e0


FAULTING_SOURCE_LINE:  D:\a\_work\1\s\src\coreclr\vm\amd64\cgenamd64.cpp

FAULTING_SOURCE_FILE:  D:\a\_work\1\s\src\coreclr\vm\amd64\cgenamd64.cpp

FAULTING_SOURCE_LINE_NUMBER:  399

SYMBOL_NAME:  coreclr!isJumpRel64+0

MODULE_NAME: coreclr

IMAGE_NAME:  coreclr.dll

STACK_COMMAND: ~24s; .ecxr ; kb

FAILURE_BUCKET_ID:  INVALID_POINTER_READ_c0000005_coreclr.dll!isJumpRel64

OS_VERSION:  10.0.26100.1

BUILDLAB_STR:  ge_release

OSPLATFORM_TYPE:  x64

OSNAME:  Windows 10

IMAGE_VERSION:  9.0.425.16305

FAILURE_ID_HASH:  {29b57f72-2faf-befd-645c-67aa12225b7f}

Followup:     MachineOwner
---------

CLRMAReleaseInstance
~ClrmaManagedAnalysis

Expected behavior

PowerShell opens and lets me use it

Actual behavior

PowerShell crashes

Error details

Environment data

Can't open Powershell to get it

Visuals

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    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