Had a server recently that needed to have Power shell re-installed onto the server. After performing the re-install a heap of strange errors starting to occur on the server. The main one that triggered the alert of is that the Exchange Management Console wouldn’t start and would present an error like

The type initalizer for ‘Microsoft.Exchange.Configuration.MonadDataProvider.ConnectionPool’ threw an exception

After the initial troubleshooting I attempted to load Power Shell which gave the following error.

NoPowerShellThe shell cannot be started. A failure occurred during initialization: Object reference not set an instanace of an object.

After trying the usually troubleshooting issues I found some information that says this issue can occur if theĀ HKEY_CURRENT_USER\Environment key is missing from the registry. So I check for that key and sure enough it is missing.

Re-created the key and Power shell started successfully.

Once Power Shell was working all of the other services started working with no trouble.