Remove-SPManagedAccount failing after user was removed from Active Directory, in SharePoint 2013

Today I did a small mistake, I deleted an AD user before removing it first from the list of Managed accounts in SharePoint 2013. To be more specific about my case, the managed account was not used for anything, but still I was not able to delete it from the list of managed accounts after I deleted the AD account.

I was lucky to find a comment on one blog about a way to solve this  so I am sharing this with you. The person who posted the comment is called Jonathan Manley so all credits go to him. 

The solution is to use:

Get-SPManagedAccount -identity “domain\accountname” |Remove-SPManagedAccount


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s