如何修复Azure云外壳上的核心转储错误



每当我启动Azure Cloud shell时,它都会崩溃,并出现以下错误。知道如何消除这个错误吗。感谢您的帮助。

Requesting a Cloud Shell.Succeeded.
Connecting terminal...
Unhandled exception. System.TypeInitializationException: The type initializer for 'System.Management.Automation.Configuration.PowerShellConfig' threw an exception.
---> System.TypeInitializationException: The type initializer for 'System.Management.Automation.Platform' threw an exception.
---> System.IO.IOException: Bad message
at System.IO.FileSystem.CreateDirectory(String fullPath)
at System.IO.Directory.CreateDirectory(String path)
at System.Management.Automation.Platform.SelectProductNameForDirectory(XDG_Type dirpath) in /PowerShell/src/System.Management.Automation/CoreCLR/CorePsPlatform.cs:line 343
at System.Management.Automation.Platform..cctor() in /PowerShell/src/System.Management.Automation/CoreCLR/CorePsPlatform.cs:line 145
--- End of inner exception stack trace ---
at System.Management.Automation.Configuration.PowerShellConfig..ctor() in /PowerShell/src/System.Management.Automation/engine/PSConfiguration.cs:line 91
at System.Management.Automation.Configuration.PowerShellConfig..cctor() in /PowerShell/src/System.Management.Automation/engine/PSConfiguration.cs:line 57
--- End of inner exception stack trace ---
at System.Management.Automation.Utils.GetPolicySettingFromConfigFile[T](ConfigScope[] preferenceOrder) in /PowerShell/src/System.Management.Automation/engine/Utils.cs:line 784
at System.Management.Automation.Utils.GetPolicySetting[T](ConfigScope[] preferenceOrder) in /PowerShell/src/System.Management.Automation/engine/Utils.cs:line 760
at Microsoft.PowerShell.CommandLineParameterParser.GetConfigurationNameFromGroupPolicy() in /PowerShell/src/Microsoft.PowerShell.ConsoleHost/host/msh/CommandLineParameterParser.cs:line 578
at Microsoft.PowerShell.ConsoleHost.ParseCommandLine(String[] args) in /PowerShell/src/Microsoft.PowerShell.ConsoleHost/host/msh/ConsoleHost.cs:line 289
at Microsoft.PowerShell.UnmanagedPSEntry.Start(String[] args, Int32 argc) in /PowerShell/src/Microsoft.PowerShell.ConsoleHost/host/msh/ManagedEntrance.cs:line 82
at Microsoft.PowerShell.ManagedPSEntry.Main(String[] args) in /PowerShell/src/powershell/Program.cs:line 71
Aborted (core dumped)

这可能是您的配置文件中的内容或损坏的clouddrive映像。致";工厂复位";您的cloudshell执行以下操作:

  • 导航到用于cloudshell存储的资源组
  • 导航到此资源组中的存储帐户
  • 导航到";"文件共享";,你应该看到一个名为";cloudshellshare">
  • 删除此共享
  • 重新启动/启动cloudshell。这应该会给工厂带来新鲜感

最新更新