"powershell has stopped working" on exit after creating IIS user - by MediaNick

Status : 

 


2
0
Sign in
to vote
ID 849635 Comments
Status Active Workarounds
Type Bug Repros 1
Opened 4/9/2014 9:57:02 AM
Access Restriction Public

Description

On a Windows Server 2012 box, I'm using PS to create a new IIS User (for automated deployments using MSDeploy). The command itself appears to work fine -- the user is created -- but as soon as I exit my PowerShell session (typing exit or just closing the command window), a dialog is displayed stating "powershell has stopped working", with the following details:

Problem signature:
  Problem Event Name:   PowerShell
  NameOfExe:    powershell.exe
  FileVersionOfSystemManagementAutomation:  6.2.9200.16628
  InnermostExceptionType:   Runtime.InteropServices.InvalidComObject
  OutermostExceptionType:   Runtime.InteropServices.InvalidComObject
  DeepestPowerShellFrame:   unknown
  DeepestFrame: System.StubHelpers.StubHelpers.GetCOMIPFromRCW
  ThreadName:   unknown
  OS Version:   6.2.9200.2.0.0.400.8
  Locale ID:    1033

The PS commands in question are:

[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.Web.Management")
[Microsoft.Web.Management.Server.ManagementAuthentication]::CreateUser("Foo", "Bar")

I upgraded the server from PowerShell 3.0 to 4.0 and confirmed that the same problem still occurs.

Also, I've posted this on ServerFault but have not received any answers there, which led me to posting it here: http://serverfault.com/questions/587305/powershell-has-stopped-working-on-ps-exit-after-creating-iis-user

EDIT: This does not appear to happen on Windows Server 2012 R2.
Sign in to post a comment.
Posted by Blackat.NET on 4/12/2014 at 1:48 AM
I have the same problem.