Hey everyone, I'm dealing with a frustrating issue across several Server 2022 machines. When I try to launch Powershell, I keep getting the error message: `One or more errors occurred.` along with another saying, `Cannot load PSReadline module. Console is running without PSReadline.` Additionally, Server Manager either doesn't launch or is super sluggish when it does. The Event Viewer indicates that there's a problem with Type Accelerators, showing a `TypeInitializationException`. I can install and run Powershell Core without any issues, but the native Powershell is completely broken, affecting various modules. If anyone has insights or can point me towards a better community for help, I'd really appreciate it!
3 Answers
This may relate to the .NET framework on those machines. I found a helpful tool that could assist in repairing it: [Repair .NET Framework](https://learn.microsoft.com/en-us/dotnet/framework/install/repair). That could potentially fix the underlying issue.
This is a strange situation! Have you tried launching Powershell from the command prompt using `powershell.exe -noprofile`? Sometimes it helps bypass any profile issues that could be causing this problem. Beyond that, don't forget the typical OS repair steps: run `dism /online /cleanup-image /restorehealth` followed by `sfc /scannow` to fix any corrupt files. Make sure to reboot your system afterwards!
You should check if your execution policy is set to 'Restricted'. If it is, try changing it to `AllSigned`. That might resolve issues with loading certain modules.
Related Questions
Can't Load PhpMyadmin On After Server Update
Redirect www to non-www in Apache Conf
How To Check If Your SSL Cert Is SHA 1
Windows TrackPad Gestures