I need to extract a list of user names and email addresses. How can I do that? Rob
What do you mean by email addresses, just SMTP? You can do the following adfind -h 2k3dc02 -sc exchaddresses:smtp sAMAccountName -csv If you want all addresses adfind -h 2k3dc02 -sc exchaddresses sAMAccountName -csv joe -- Joe Richards Microsoft MVP Windows Server Directory Services Author of O'Reilly Active Directory Third Edition www.joeware.net ---O'Reilly Active Directory Third Edition now available--- http://www.joeware.net/win/ad3e.htm Rob wrote: > I need to extract a list of user names and email addresses. > How can I do that? > > Rob > >
I got that to work without using the servername, which is fine, but can't figure out how to get the data to a file. I understand the -csv is supposed to do that, but don't I need to give it a name and path? is there a default path? Yes I just need all names + smtp addresses. Thanks Joe, Rob "Joe Richards [MVP]" wrote in message news:uA1w7JriGHA.3408@TK2MSFTNGP05.phx.gbl... > What do you mean by email addresses, just SMTP? > > You can do the following > > adfind -h 2k3dc02 -sc exchaddresses:smtp sAMAccountName -csv > > If you want all addresses > > adfind -h 2k3dc02 -sc exchaddresses sAMAccountName -csv > > > joe > > > -- > Joe Richards Microsoft MVP Windows Server Directory Services > Author of O'Reilly Active Directory Third Edition > www.joeware.net > > > ---O'Reilly Active Directory Third Edition now available--- > > http://www.joeware.net/win/ad3e.htm > > > > Rob wrote: >> I need to extract a list of user names and email addresses. >> How can I do that? >> >> Rob
Adfind always writes to console, if you want the output sent to a file, redirect the output with standard command line redirection. -- Joe Richards Microsoft MVP Windows Server Directory Services Author of O'Reilly Active Directory Third Edition www.joeware.net ---O'Reilly Active Directory Third Edition now available--- http://www.joeware.net/win/ad3e.htm Rob wrote: > I got that to work without using the servername, which is fine, but can't > figure out how to get the data to a file. > I understand the -csv is supposed to do that, but don't I need to give it a > name and path? is there a default path? > Yes I just need all names + smtp addresses. > > Thanks Joe, > > Rob > > > "Joe Richards [MVP]" wrote in message > news:uA1w7JriGHA.3408@TK2MSFTNGP05.phx.gbl... >> What do you mean by email addresses, just SMTP? >> >> You can do the following >> >> adfind -h 2k3dc02 -sc exchaddresses:smtp sAMAccountName -csv >> >> If you want all addresses >> >> adfind -h 2k3dc02 -sc exchaddresses sAMAccountName -csv >> >> >> joe >> >> >> -- >> Joe Richards Microsoft MVP Windows Server Directory Services >> Author of O'Reilly Active Directory Third Edition >> www.joeware.net >> >> >> ---O'Reilly Active Directory Third Edition now available--- >> >> http://www.joeware.net/win/ad3e.htm >> >> >> >> Rob wrote: >>> I need to extract a list of user names and email addresses. >>> How can I do that? >>> >>> Rob > >