Go Back   TechArena Community > Technical Support > Computer Help > Windows Server > Active Directory
Become a Member!
Forgot your username/password?
Register Tags Active Topics RSS Search Mark Forums Read SiteMap

Tags: , , , ,

Sponsored Links



LDIF Export of All user email addresses for individual Exchange server

Active Directory


Reply
 
Thread Tools Search this Thread
  #1  
Old 07-08-2009
Paul
 
Posts: n/a
LDIF Export of All user email addresses for individual Exchangeserver

I'm trying to do a LDIF export of all the users in a particular domain
for a particular mail server. I can get the actual users in a domain:

ldifde -f ADoutput.txt -s {dcname} -t 3268 -d "dc=
{myrootdomain},dc=com" -p subtree -r "(&(objectclass=user)
(mailnickname=*)(samaccountname=*))" -l
"dn,proxyaddresses,samaccountname"

How would I get it to only list the users on one of my mail servers?
Any correction to my LDIF would be appreciated too. It's a tool I
don't have to use too often. Thanks.

Paul
Reply With Quote
  #2  
Old 08-08-2009
Richard Mueller [MVP]
 
Posts: n/a
Re: LDIF Export of All user email addresses for individual Exchange server


"Paul" <pauldi@iona.com> wrote in message
news:041f35f7-4ccb-4172-9a30-73621556ff42@d4g2000vbm.googlegroups.com...
> I'm trying to do a LDIF export of all the users in a particular domain
> for a particular mail server. I can get the actual users in a domain:
>
> ldifde -f ADoutput.txt -s {dcname} -t 3268 -d "dc=
> {myrootdomain},dc=com" -p subtree -r "(&(objectclass=user)
> (mailnickname=*)(samaccountname=*))" -l
> "dn,proxyaddresses,samaccountname"
>
> How would I get it to only list the users on one of my mail servers?
> Any correction to my LDIF would be appreciated too. It's a tool I
> don't have to use too often. Thanks.
>
> Paul


Perhaps add the clause below to your filter:

(msExchHomeServerName={mailservername})

or possibly:

(homeMDB={DN of home MBD})

You can use ADSI Edit or ldp tools to check correct values for a typical
user. Instead of:

(&(objectClass=user)(sAMAccountName=*))

I would use:

(&(objectCategory=person)(objectClass=user))

but maybe that's a matter of style. Both eliminate contact objects, which
have no sAMAccountName.

--
Richard Mueller
MVP Directory Services
Hilltop Lab - http://www.rlmueller.net
--


Reply With Quote
  #3  
Old 08-08-2009
Paul
 
Posts: n/a
LDIF Export of All user email addresses for individual Exchange server

Thanks. That did the trick. The msExchHomeServerName has a big long
attribute, but using a wildcard worked perfectly. This is what I
ended up with:

Ldifde –f ADExport.txt –s {dcname} –t 3268 –d “dc=
{myrootdomain},dc=com” –p subtree –r (&(objectCategory=person)
(objectClass=user)(msExchHomeServerName=*{mailserver})) –l
“dn,proxyaddresses,samaccountname”

Paul
Reply With Quote
Reply

  TechArena Community > Technical Support > Computer Help > Windows Server > Active Directory


Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "LDIF Export of All user email addresses for individual Exchange server"
Thread Thread Starter Forum Replies Last Post
Export Names and Email Addresses from Thunderbird Mustafa k Technology & Internet 5 13-01-2011 07:40 AM
Export email addresses from mail? The!Winston Technology & Internet 5 21-10-2010 10:01 AM
filter out domain user accounts without email addresses inenewbl Active Directory 2 11-07-2009 12:06 AM
Using Two Reply-to Addresses with Exchange Server Dave Davis Small Business Server 4 16-02-2008 12:29 AM
Export Usernames and Email Addresses Dave B Active Directory 3 11-02-2005 03:28 AM


All times are GMT +5.5. The time now is 07:03 PM.