none
get-dnsserverresourcerecord Type field info RRS feed

  • Question

  • Greetings,

       When retrieving all our DNS records using get-dnsserverresourcerecord , I notice that the returned field 'Type' (the integer one) has many different values. I've looked at https://docs.microsoft.com/en-us/previous-versions/windows/desktop/dnsserverpsprov/dnsserverresourcerecord and it doesnt explain what all the values mean. I thought it may have a one to one relationship with the field recordtype but that is not the case as I have noticed records with the same RecordType value but different Type values over time.

    Is there another reference for this field?

    Thanks

    David Zemdegs

    • Moved by Bill_Stewart Wednesday, September 4, 2019 2:36 PM Move to more appropriate forum
    Tuesday, September 3, 2019 11:46 PM

Answers

  • What prompted my question was I started doing a dump of all DNS records every day. I noticed one 'A' record for the same computer and IP address - on one day it was type 0 and the next day it was type 1. So this is not the case where the recordtype is unknown as the recordtype shows clearly an 'A' record.

    But when it is NOT unknown the type field is meaningless.  TYe docs clearly say it is only used for the "unknown" record type.


    \_(ツ)_/

    • Marked as answer by David Zemdegs Friday, September 6, 2019 12:20 AM
    Wednesday, September 4, 2019 11:46 PM

All replies

  • Just read the doc on this. It clearly explains what it is used for:

    Type
    
    Data type: uint16
    Access type: Read-only
    Type for Unknown record.
    
    Windows Server 2012 R2 and Windows Server 2012: Not supported.
    
    Requirements
    
    Minimum supported client: None supported
    Minimum supported server: Windows Server 2012
    Namespace: Root\Microsoft\Windows\Dns
     
    MOF: DnsServerPSProvider.mof 
    DLL: DnsServerPSProvider.dll 
    


    \_(ツ)_/

    Wednesday, September 4, 2019 12:35 AM
  • Thanks - but what do the numbers mean? What is type 0 or 1 or 28 etc?
    Wednesday, September 4, 2019 10:37 PM
  • Nothing.  They are only used when the RecordType is set to "Unknown".  FOr all other types the number is not used.  It is likely filled with the ordinal of the RecordType.  It should be ignored if you are not managing "Unknown" records.  

    Here are the type ids of defined records. https://en.wikipedia.org/wiki/List_of_DNS_record_types


    \_(ツ)_/

    Wednesday, September 4, 2019 10:46 PM
  • 0 is OFF 28 is Wide Open
    Wednesday, September 4, 2019 11:32 PM
  • What prompted my question was I started doing a dump of all DNS records every day. I noticed one 'A' record for the same computer and IP address - on one day it was type 0 and the next day it was type 1. So this is not the case where the recordtype is unknown as the recordtype shows clearly an 'A' record.
    Wednesday, September 4, 2019 11:39 PM
  • What prompted my question was I started doing a dump of all DNS records every day. I noticed one 'A' record for the same computer and IP address - on one day it was type 0 and the next day it was type 1. So this is not the case where the recordtype is unknown as the recordtype shows clearly an 'A' record.

    But when it is NOT unknown the type field is meaningless.  TYe docs clearly say it is only used for the "unknown" record type.


    \_(ツ)_/

    • Marked as answer by David Zemdegs Friday, September 6, 2019 12:20 AM
    Wednesday, September 4, 2019 11:46 PM
  • 0 is OFF 28 is Wide Open

    Please stop adding nonsense responses to posts.  We see you are doing this every couple of minutes.  Your account will be restricted if you continue.


    \_(ツ)_/

    Wednesday, September 4, 2019 11:48 PM
  • Thanks. Dont know why they bother populating that field with a number when it is not relevant for valid rrtypes. I suspect that its just a bit of lazy code. Personally I would have coded zero for known record types.
    Friday, September 6, 2019 12:20 AM