Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
platform
active.directory
adsi
adsi.iis-admin
base
com_ole
complus_mts
component_svcs
database
directx
gdi
graphics_mm
internet.client
internet.server
internet.server.isapi-dev
localization
mapi
messaging
msi
mslayerforunicode
multimedia
networking
networking.ipv6
sdk_install
security
shell
telephony.tapi_2
telephony.tapi_3
telephony.tsp
telephony.wte
tools
ui
ui_shell
win_base_svcs
win16
  
 
date: 23 May 2005 13:50:33 -0700,    group: microsoft.public.platformsdk.adsi        back       


Get server DNS names via Exchange 5.5 csvde query   
Hi, I'm trying to create a csvde query or any query for that matter
that will return all servers dns names in the Exchange 5.5 directory.

Currently I get DN items like
cn=EXCHANGE55,cn=Servers,cn=Configuration,ou=exchange55,o=company

Yet I really need a DNS column like
server.company.com

Does anyone know how to get this?  Or an api that can convert the DN?
I tried DsCrackName, but I can't rely on AD being available.

Thanks
date: 23 May 2005 13:50:33 -0700   author:   unknown

Re: Get server DNS names via Exchange 5.5 csvde query   
Hi,

Instead of distinguishedName, I believe you want to retrieve the
dNSHostName.

Also, you can use the NameTranslate object to convert the DN to many other
forms.
See: http://www.rlmueller.net/NameTranslateFAQ.htm
You perhaps could use ADS_NAME_TYPE_CANONICAL or ADS_NAME_TYPE_CANONICAL_EX.

-- 
Richard
Microsoft MVP Scripting and ADSI
Hilltop Lab web site - http://www.rlmueller.net
--
"cehupper@naaahhhhh.com"  wrote in message
news:1116881433.539803.128970@o13g2000cwo.googlegroups.com...
> Hi, I'm trying to create a csvde query or any query for that matter
> that will return all servers dns names in the Exchange 5.5 directory.
>
> Currently I get DN items like
> cn=EXCHANGE55,cn=Servers,cn=Configuration,ou=exchange55,o=company
>
> Yet I really need a DNS column like
> server.company.com
>
> Does anyone know how to get this?  Or an api that can convert the DN?
> I tried DsCrackName, but I can't rely on AD being available.
>
> Thanks
>
date: Mon, 23 May 2005 19:01:27 -0500   author:   Richard Mueller [MVP]

Re: Get server DNS names via Exchange 5.5 csvde query   
Unfortunately that query returns no entries for me.  And I don't see
dnshostname anywhere in the schema.

csvde -f tmp.csv -s Exchange55.dev.company.com -l dnshostname

I used dscrackname and got

DsCrackNames success Code: 0
cItems:         1
rItems.status:  0
rItems.pDomain: dev.company.com
rItems.pName:   EXCHANGE55$
The operation was successful.
FormatMessage: 0013D188

What's with the "$" ?  But why should I need this when a csvde query
against the DC does produce the dns name?
date: 24 May 2005 10:15:58 -0700   author:   unknown

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us