Werbung: SecurityConsole.de verwaltet Ihre Computer mit Security Essentails aus der Cloud!
30 Tage kostenfrei testen und 20% Rabatt für Ihre Bestellung mit Promocode: WBF2685582
(Promocode gültig bis 31.12.2011)

Group:  English: Windows Server » microsoft.public.windows.server.dns
Thread: Filter on DNS Record Type

HTVi
TV Discussion Newsgroups

Filter on DNS Record Type
Bob Smith 10/22/2008 3:29:04 PM
I am querying DNS records in a zone, but would like to filter on A records
only. Is there a way I can determaine this based on the AD attribtes of a
resource record? I can't seem to determaine what value holds this
information. I suspect dnsrecord but I'm nor sure what part relates to the
record type.

Set objDNS =
GetObject("LDAP://mydomain.com/DC=mytestzone.com,CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=com")


For Each objRecord in objDNS
wscript.echo objRecord.Get("dc")
Next
Re: Filter on DNS Record Type
"A, Deji" <deji[ at ]akomolafe.com> 10/23/2008 6:46:40 AM
dnscmd DNS-Server-Name /enumrecords myzone.TLD [ at ] /Type A

Deji

"Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
news:1923FCEB-BCF8-4634-BEB6-481722CDB0F5[ at ]microsoft.com...
[Quoted Text]
>I am querying DNS records in a zone, but would like to filter on A records
> only. Is there a way I can determaine this based on the AD attribtes of a
> resource record? I can't seem to determaine what value holds this
> information. I suspect dnsrecord but I'm nor sure what part relates to the
> record type.
>
> Set objDNS =
> GetObject("LDAP://mydomain.com/DC=mytestzone.com,CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=com")
>
>
> For Each objRecord in objDNS
> wscript.echo objRecord.Get("dc")
> Next

Re: Filter on DNS Record Type
Bob Smith 10/23/2008 2:22:01 PM
I wold like to determain this from the AD object, not be using the external
tool dnscmd.

Thanks

"A, Deji" wrote:

[Quoted Text]
> dnscmd DNS-Server-Name /enumrecords myzone.TLD [ at ] /Type A
>
> Deji
>
> "Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
> news:1923FCEB-BCF8-4634-BEB6-481722CDB0F5[ at ]microsoft.com...
> >I am querying DNS records in a zone, but would like to filter on A records
> > only. Is there a way I can determaine this based on the AD attribtes of a
> > resource record? I can't seem to determaine what value holds this
> > information. I suspect dnsrecord but I'm nor sure what part relates to the
> > record type.
> >
> > Set objDNS =
> > GetObject("LDAP://mydomain.com/DC=mytestzone.com,CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=com")
> >
> >
> > For Each objRecord in objDNS
> > wscript.echo objRecord.Get("dc")
> > Next
>
>
Re: Filter on DNS Record Type
"A, Deji" <deji[ at ]akomolafe.com> 10/23/2008 5:47:34 PM
what external tool? DNSCMD is the commandline DNS management interface for
Windows. It's built-in and you can script it, too.

Deji
"Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
news:CE4B00DE-25D7-4DB5-A704-E2A485C1B4FB[ at ]microsoft.com...
[Quoted Text]
>I wold like to determain this from the AD object, not be using the external
> tool dnscmd.
>
> Thanks
>
> "A, Deji" wrote:
>
>> dnscmd DNS-Server-Name /enumrecords myzone.TLD [ at ] /Type A
>>
>> Deji
>>
>> "Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
>> news:1923FCEB-BCF8-4634-BEB6-481722CDB0F5[ at ]microsoft.com...
>> >I am querying DNS records in a zone, but would like to filter on A
>> >records
>> > only. Is there a way I can determaine this based on the AD attribtes of
>> > a
>> > resource record? I can't seem to determaine what value holds this
>> > information. I suspect dnsrecord but I'm nor sure what part relates to
>> > the
>> > record type.
>> >
>> > Set objDNS =
>> > GetObject("LDAP://mydomain.com/DC=mytestzone.com,CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=com")
>> >
>> >
>> > For Each objRecord in objDNS
>> > wscript.echo objRecord.Get("dc")
>> > Next
>>
>>

Re: Filter on DNS Record Type
Bob Smith 10/24/2008 4:52:07 PM
External of my script. I want to grab the information directly from Active
Directory and not reply on the output of some other function or program.

"A, Deji" wrote:

[Quoted Text]
> what external tool? DNSCMD is the commandline DNS management interface for
> Windows. It's built-in and you can script it, too.
>
> Deji
> "Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
> news:CE4B00DE-25D7-4DB5-A704-E2A485C1B4FB[ at ]microsoft.com...
> >I wold like to determain this from the AD object, not be using the external
> > tool dnscmd.
> >
> > Thanks
> >
> > "A, Deji" wrote:
> >
> >> dnscmd DNS-Server-Name /enumrecords myzone.TLD [ at ] /Type A
> >>
> >> Deji
> >>
> >> "Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
> >> news:1923FCEB-BCF8-4634-BEB6-481722CDB0F5[ at ]microsoft.com...
> >> >I am querying DNS records in a zone, but would like to filter on A
> >> >records
> >> > only. Is there a way I can determaine this based on the AD attribtes of
> >> > a
> >> > resource record? I can't seem to determaine what value holds this
> >> > information. I suspect dnsrecord but I'm nor sure what part relates to
> >> > the
> >> > record type.
> >> >
> >> > Set objDNS =
> >> > GetObject("LDAP://mydomain.com/DC=mytestzone.com,CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=com")
> >> >
> >> >
> >> > For Each objRecord in objDNS
> >> > wscript.echo objRecord.Get("dc")
> >> > Next
> >>
> >>
>
>
Re: Filter on DNS Record Type
"A, Deji" <deji[ at ]akomolafe.com> 10/25/2008 6:35:59 AM
I see....

Can you use WMI? If so, then what you are looking for is
"MicrosoftDNS_AType". For example:

MyDNSServer = "name-of-a-DNS-server"
Set objAction = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & _
"\root\MicrosoftDNS")

Set myCollections = objAction.ExecQuery("Select * from MicrosoftDNS_AType")

For each Collection in myCollections
Wscript.Echo Collection.DomainName & ": " & Collection.OwnerName & ": " &
Collection.IPAddress
Next
Set myCollections = Nothing
Set objAction = Nothing

Depends on exactly what you are looking for after getting this far.

Deji

"Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
news:8672976B-B06D-4D00-9CE0-70307C62E3BC[ at ]microsoft.com...
[Quoted Text]
> External of my script. I want to grab the information directly from Active
> Directory and not reply on the output of some other function or program.
>
> "A, Deji" wrote:
>
>> what external tool? DNSCMD is the commandline DNS management interface
>> for
>> Windows. It's built-in and you can script it, too.
>>
>> Deji
>> "Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
>> news:CE4B00DE-25D7-4DB5-A704-E2A485C1B4FB[ at ]microsoft.com...
>> >I wold like to determain this from the AD object, not be using the
>> >external
>> > tool dnscmd.
>> >
>> > Thanks
>> >
>> > "A, Deji" wrote:
>> >
>> >> dnscmd DNS-Server-Name /enumrecords myzone.TLD [ at ] /Type A
>> >>
>> >> Deji
>> >>
>> >> "Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
>> >> news:1923FCEB-BCF8-4634-BEB6-481722CDB0F5[ at ]microsoft.com...
>> >> >I am querying DNS records in a zone, but would like to filter on A
>> >> >records
>> >> > only. Is there a way I can determaine this based on the AD attribtes
>> >> > of
>> >> > a
>> >> > resource record? I can't seem to determaine what value holds this
>> >> > information. I suspect dnsrecord but I'm nor sure what part relates
>> >> > to
>> >> > the
>> >> > record type.
>> >> >
>> >> > Set objDNS =
>> >> > GetObject("LDAP://mydomain.com/DC=mytestzone.com,CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=com")
>> >> >
>> >> >
>> >> > For Each objRecord in objDNS
>> >> > wscript.echo objRecord.Get("dc")
>> >> > Next
>> >>
>> >>
>>
>>

Re: Filter on DNS Record Type
"A, Deji" <deji[ at ]akomolafe.com> 10/25/2008 6:37:14 AM
I see...

"Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
news:8672976B-B06D-4D00-9CE0-70307C62E3BC[ at ]microsoft.com...
[Quoted Text]
> External of my script. I want to grab the information directly from Active
> Directory and not reply on the output of some other function or program.
>
> "A, Deji" wrote:
>
>> what external tool? DNSCMD is the commandline DNS management interface
>> for
>> Windows. It's built-in and you can script it, too.
>>
>> Deji
>> "Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
>> news:CE4B00DE-25D7-4DB5-A704-E2A485C1B4FB[ at ]microsoft.com...
>> >I wold like to determain this from the AD object, not be using the
>> >external
>> > tool dnscmd.
>> >
>> > Thanks
>> >
>> > "A, Deji" wrote:
>> >
>> >> dnscmd DNS-Server-Name /enumrecords myzone.TLD [ at ] /Type A
>> >>
>> >> Deji
>> >>
>> >> "Bob Smith" <BobSmith[ at ]discussions.microsoft.com> wrote in message
>> >> news:1923FCEB-BCF8-4634-BEB6-481722CDB0F5[ at ]microsoft.com...
>> >> >I am querying DNS records in a zone, but would like to filter on A
>> >> >records
>> >> > only. Is there a way I can determaine this based on the AD attribtes
>> >> > of
>> >> > a
>> >> > resource record? I can't seem to determaine what value holds this
>> >> > information. I suspect dnsrecord but I'm nor sure what part relates
>> >> > to
>> >> > the
>> >> > record type.
>> >> >
>> >> > Set objDNS =
>> >> > GetObject("LDAP://mydomain.com/DC=mytestzone.com,CN=MicrosoftDNS,DC=DomainDnsZones,DC=mydomain,DC=com")
>> >> >
>> >> >
>> >> > For Each objRecord in objDNS
>> >> > wscript.echo objRecord.Get("dc")
>> >> > Next
>> >>
>> >>
>>
>>

Home | Search | Terms | Imprint Contact
Newsgroups Reader - provided by WiredBox.Net
Suche nach Orten, Städten, Postleitzahlen, Vorwahlen, Kfz-Kennzeichen