Solved

dumping all email addresses for exchange 2007 mailboxes

Posted on 2010-09-08
5
343 Views
Last Modified: 2012-06-27
I need to dump the email addresses for my exchange users.  Some have more than one address and I need all of them in the dump.  I have tried:  
    get-user jane.Doe | select name, proxyaddresses and get-user jane.Doe | select name, emailaddresses
   The name field dumps as expected, but no email addresses get dumped.  

I need this to include mailboxes and contacts.

Thanks for any help!

Susan
0
Comment
Question by:suelizy
  • 2
  • 2
5 Comments
 
LVL 15

Expert Comment

by:Dave_AND
ID: 33627862
Have a look at this: http://www.exchangepedia.com/2005/09/how-to-export-all-email-addresses-from-a-domain.html

Just tested it on my Exchange 2010 and it worked correctly
0
 

Author Comment

by:suelizy
ID: 33628162
I did find that, but there is a lot of code in that one.  We have about 67,000 objects that will have to be queried.  How long did it take you to run it?  How many objects did it have to query?

I have gotten closer, I can dump it to the powershell screen with:  Get-Mailbox | fl Name, PrimarySMTPaddress, Emailaddresses

I cannot get it to dump to file.  I have tried adding these, but the data does not dump.
     | Export-CSV "c:\proxy.csv" and
     | >c:\proxy.txt

Thanks!

Susan
0
 
LVL 13

Expert Comment

by:soostibi
ID: 33628272
I think this will do what you want:
(Get-Mailbox),(get-mailcontact)| %{$_} | Select-Object -ExpandProperty emailaddresses | Select-object -expandproperty smtpaddress

Open in new window

0
 
LVL 13

Accepted Solution

by:
soostibi earned 500 total points
ID: 33628297
Sorry, I forgot about the name. Here is the corrected one:
(Get-Mailbox),(get-mailcontact)| %{$_} | Select-Object -property name -ExpandProperty emailaddresses | Select-Object -Property name, smtpaddress

Open in new window

0
 
LVL 15

Expert Comment

by:Dave_AND
ID: 33628462
Took about 10 secs on 1000 objects
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This script can help you clean up your user profile database by comparing profiles to Active Directory users in a particular OU, and removing the profiles that don't match.
In-place Upgrading Dirsync to Azure AD Connect
In this video we show how to create an Accepted Domain in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Mail Flow >> Ac…
To show how to create a transport rule in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Mail Flow >> Rules tab.:  To cr…

790 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question