Exchange 2010 Get Mailbox owner

I have a list of 64 shared mailboxes. Management wants to know the owner of each of these mailboxes. I run the command  "mailbox"  | get-mailbox | get-mailboxpermission -owner. I am assuming the only way to get a list of owners for all mailboxes would be to add the "mailbox" for each mailbox and then run the command. While this could take some time, i'm ok doing the work. The problem i have is some mailboxes return the following error . I am not sure how to decipher this error. I know the mailbox exists and i copy and past the alias to make sure i'm typing it correctly. If i could get this list to work i can pipe it to a csv file. But, this error comes up even if i run the command only on one of the problem mailboxes. Any ideas?

Some or all identity references could not be translated.
    + CategoryInfo          : NotSpecified: (:) [Get-MailboxPermission], IdentityNotMappedException
    + FullyQualifiedErrorId : System.Security.Principal.IdentityNotMappedException,Microsoft.Exchange.Management.Recip
Eddie CrosbyAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Jian An LimSolutions ArchitectCommented:
by a wild guess, it looks like these shared mailbox do not have a owner set in the beginning.
I think it more likely that these mailboxes have a reference to a deleted mailbox. Looking at MSDN I can see it says:-

"Represents an exception for a principal whose identity could not be mapped to a known identity."


and choose the ".net 3.5" version for more

So what has happened is that permissions have been granted to a user, that user has then been deleted from Active Directory, so you are left with a hanging SID.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.