question

kondasaiprakash-4285 avatar image
0 Votes"
kondasaiprakash-4285 asked KondaSaiPrakash-1797 commented

'System.Management.Runspaces.InitialSessionState' Threw an exception

Hi

I face this issue when trying to execute powershell on remote client

type initializer for 'System.Management.Runspaces.InitialSessionState' Threw an exception


below is the details of powershell version I use:

105291-image.png

if any detalis required please mention it
I will provide as soon as possible

windows-server-powershell
image.png (42.0 KiB)
· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Maybe check the $error[0] to see if there are any clues.

0 Votes 0 ·

W i n d o w s P o w e r S h e l l t e r m i n a t e d w i t h t h e f o l l o w i n g e r r o r :
T h e t y p e i n i t i a l i z e r f o r ' S y s t e m . M a n a g e m e n t . A u t o m a t i o n . R u n s p a c e s . I n i t i a l S e s s i o n S t a t e ' t h r e w a n e x c e p t i o n .


This is the error I got @IanXue-MSFT

0 Votes 0 ·

this is the extra info regarding the issue

DevTools listening on ws://127.0.0.1:58322/devtools/browser/2a079225-a0ff-4a5a-81a2-4af87f18fd6d
[8960:7252:0630/220421.542:ERROR:device_event_log_impl.cc(214)] [22:04:21.543] Bluetooth: bluetooth_adapter_winrt.cc:1072 Getting Default Adapter failed.
[9868:9872:0630/220621.123:ERROR:gpu_init.cc(440)] Passthrough is not supported, GL is disabled
Windows PowerShell terminated with the following error:
 The type initializer for 'System.Management.Automation.Runspaces.InitialSessionState' threw an exception.
Windows PowerShell terminated with the following error:
 The type initializer for 'System.Management.Automation.Runspaces.InitialSessionState' threw an exception.

0 Votes 0 ·

0 Answers