Configuring and Troubleshooting DNS Flashcards
How do you install DNS using PowerShell?
Install-WindowsFeature -Name DNSServer -IncludeManagementTools
- Iterative Query
- Recursive Query
- Iterative Query - Server returns the best answer, it never sends out an additional query. It may refer you to another server through a referral
- Recursive Query - client asks server to respond either with the requested answer or with an error
What is the difference between a Forwarder and a Conditional Forwarder?
- Forwarder: If the name query cannot be resolved using its local zone data or cache, then it will forward the query to the DNS server designated as a forwarder
- Conditional Forwarder: Conditional forwarders are DNS servers that only forward queries for specific domain names
How do you configure a DNS forwarder?
- Open DNS Manager
- Right-Click the Server, and select Properties
- Select the Forwarders tab
- Select Edit
- Add the IP Address or DNS Name
- Add the number of seconds before the forward query times out
How do you configure a conditional forward?
- Open DNS Manager
- Expand the Server
- Right-Click Conditional Forwarders, Select New Conditional Forwarder
- Add the IP Address
- Select if you want to store the conditional forwarder in AD
What is the following DNS record?
SOA
Start of Authority Record
What is the following DNS record?
A
Host Address Record (IPv4)
What is the following DNS record?
CNAME
Alias Record
What is the following DNS record?
MX
Mail Exchanger Record
What is the following DNS record?
SRV
Service Locator Record
What is the following DNS record?
NS
Name Server Record
What is the following DNS record?
AAAA
IPv6 host address record
What is the following DNS record?
PTR
Pointer resource record
How would you create a DNS Record in PowerShell?
- A
- AAAA
- CName
- MX
- PTR
- How would you create an other type of record?
- Add-DnsServerResourceRecordA
- Add-DnsServerResourceRecordAAAA
- Add-DnsServerResourceRecordCName
- Add-DnsServerResourceRecordMX
- Add-DnsServerResourceRecordPtr
- Add-DnsServerResourceRecord
- Follow-up Question: Can it create the records mentioned before and how?
- Answer: Yes, just append a dash record type to the cmdlet
- Follow-up Question: Can it create the records mentioned before and how?
What are the following types of zones?
- Primary
- Secondary
- Stub
- Active-Direcotry integrated
- Read/Write copy of a DNS Database
- Read-Only copy of a DNS database
- Copy of a zone that contains only records used to locate name servers
- Zone data is storead in AD rather than in Zone Files
Where would you configure Zone Transfers?
What are your options?
- The Zone Properties and the Zone Transfer Tab
- Options:
- Any Server
- Name Server
- Only the following Servers:
- Options:
How would you configure Zone Tranfers via PowerShell?
Set-DnsServerPrimaryZone -Name <zone> -SecureSecondaries </zone>
- NoTransfer - No transfers are allowed for this zone from this server.
- TransferAnyServer - Any server can request a zone transfer, including servers that you know nothing about and don’t manage or control.
- TransferToZoneNameServer - Only servers in the NS records for this zone are allowed to request transfers.
- TransferToSecureServers - Only servers specified with the -SecondaryServers
parameter are allowed to request a zone transfer.- ex. Set-DnsServerPrimaryZone -Name <zone> -SecureSecondaries -SecondaryServers <ipv4></ipv4></zone>
Where would you configure notifications so that Name Servers are up to date?
What are the options?
The Zone Properties, Zone Transfers Tab, select the Notify Button
- Servers listed on the name servers tab
- The Following Servers
How would you configure notification settings via PowerShell?
What are the three options?
How do you use them?
Set-DnsServerPrimaryZone -Notify
The equivalent Set-DnsServerPrimaryZone parameter is the -Notify parameter, which accepts the following strings:
- NoNotify - No notifications are sent, and secondary servers need to manually request a zone transfer or update.
- Set-DnsServerPrimaryZone -Name <zone> -Notify NoNotify</zone>
- Notify - All servers for whom there are NS records in the zone are automatically notified whenever a change is made to the zone.
- Set-DnsServerPrimaryZone -Name <zone> -Notify Notify</zone>
- NotifyServers - Only servers specified by the -NotifyServers parameter are automatically notified of changes to the domain. Any other servers that are allowed to request zone transfers must request the transfer manually.
- Set-DnsServerPrimaryZone -Name <zone> -Notify NotifyServers -NotifyServers <ipv4></ipv4></zone>
How would you have a DNS Server re-regester all services?
net stop netlogon
net start netlogon
What Zones can be stored in Active Directory?
- Primary
- Stub
When would you want to set up a Stub Zone?
When you want to set up a dynamic link between two companies. (Partner Companies)
This would allow clients to use the stub zone to find the server to resolve the DNS request to. Contains only Start Of Authority and Name Servers
When would you use a conditional fowarder?
How do you configure zone delegation via GUI?
PowerShell?
- Open DNS Manager:
- Select the Zone
- Right-Click, New Delgation
- Enter the Delegated Domain
- Add the IP Address for the Name Server
- Add-DnsServerZoneDelegation -Name “<parent>" -ChildZoneName "<child>" -NameServer "<name>" -IPAddress <ip></ip></name></child></parent>
If you create an Active Directory Integrated Primary Zone, what are the different replication options and what do they mean?
- Forest Wide - All DNS Servers in the forest get a copy of the zone
- Domain Wide - All DNS Servers in the Domain get a copy of the zone
What is a conditional forwarder?
Sends a query to a name server based on domain name
What is a server level forwarder?
Short Answer: a recursive query to another DNS Server that is used to get either a positive or negative response but not a referal.
Long Answer: Forwarders, on the other hand, use recursive queries. If forwarders are configured, when the local DNS server can’t resolve a query, it sends a recursive query to one of the forwarders in its list. This type of query tells the forwarder that the local server will accept either a positive or negative response, but not a referral. Essentially, the forwarder does the work of tracking down the record in the query, which may involve the referral process above, and the local server simply waits for the response, which it then sends to the querying client.
What is DNS Round Robin?
Is it fault tolerant if a server drops?
It switches which resource record is being given (ie for a website).
This is not fault tolerance
What is the SOA record responsible for?
What is it for?
It is for every forward look up zone created
- Incrementing the Serial Number
- Identifying the primary Server - Identify the DNS server that is authoritative for all information within the domain.
- Identifying the Responsible person - List the email address of the person in charge of the domain.
- The refresh interval - Control how often secondary servers check for changes to the zone file.
- The retry interval - Control how often secondary servers will retry to check for changes to the zone file if it fails.
- The Expires after - Control how long secondary servers keep the zone file active when the primary server cannot be contacted.
- The default TTL - Control how long a negative response is cached by a DNS resolver (but for some DNS servers, this is also how long a DNS resolver should cache any response).
- TTL for SOA
The purpose of the SOA record is:
- Control how long a negative response is cached by a DNS resolver (but for some DNS servers, this is also how long a DNS resolver should cache any response).
What is a NS record responsible for?
List all the name servers for the zone
How do you create a Reverse Lookup Zone?
- Open DNS Manager
- Expand the Server
- Select Reverse Lookup Zone, Right-Click select New Zone
- Select a Primary, Secondary, Stub, or Primary AD-integrated
- Select Replication Scope
- Forest, Domain
- Select Address type - IPv4 or IPv6
- Enter the network ID - IP Subnet
- Dynamic Update
- Secure (AD only)
- Nonsecure and Secure
- Do not allow updates
8.
How do you store Conditional Forwarder’s in Active Directory?
When creating them check the box to store the conditional forwarder in AD. You can also specify the number of seconds before forward queries time out
How would you change a single DNS Records TTL?
Edit the Record on the Time to Live.
To view this you will have to:
- Click View
- Select Advanced
How would you change the default TTL for all new records?
Open the Start of Authority (SOA) record and change the minimum (default) TTL
If a record is…
- Created by Hand
- Created by Dynamic DNS
What is the default TTL?
- 1 hour
- 20 minutes
How do you configure DNS Round Robin?
You create resource records (A or AAAA) witht he same name pointing to each server in the round robin.
Note: It is turned on by default in Windows Server 2012R2
- How might you speed up the turn over of returned records in a DNS Round robin?
- How might you return better random returns in a DNS Round robin?
- Reduce the TTL for the Records
- Turn off netmasking ordering
When configuring a DNS records priority which will be returned more?
The one with the lowest number
When configuring a DNS Records weight, given that the servers have the same priority which will be returned more?
The one with the higher value
Please indicate what the numbers in the photo refer to?
- Priority
- Weight
- Port Number
How would you change the Weight for a record using powershell?
- $Variable = $Variable2 = Get-DnsServerResourceRecord -Name <record> -ZoneName <zone> -RRType <record></record></zone></record>
- $Variable .RecordData.Weight = 20
- Set-DnsServerResourceRecord -NewInputObject $Variable -OldInputObject $Variable2 -ZoneName <zone></zone>
Example:
- $NewRRObj = $OrigRRObj = Get-DnsServerResourceRecord -Name trey-wds-11 -ZoneName TreyResearch.net -RRType A
- $NewRRObj.RecordData.Weight = 20
- Set-DnsServerResourceRecord -NewInputObject $NewRRObj -OldInputObject $OrigRRObj -ZoneName treyresearch.net
How would you change the TTL for a record using powershell?
- $Variable = $Variable2 = Get-DnsServerResourceRecord -Name <record> -ZoneName <zone> -RRType <record></record></zone></record>
- $Variable.TimeToLive = [System.TimeSpan]::FromHours(2)
- Set-DnsServerResourceRecord -NewInputObject $Variable -OldInputObject $Variable2 -ZoneName <zone></zone>
Example:
- $NewRRObj = $OrigRRObj = Get-DnsServerResourceRecord -Name trey-wds-11 -ZoneName TreyResearch.net -RRType A
- $NewRRObj.TimeToLive = [System.TimeSpan]::FromHours(2)
- Set-DnsServerResourceRecord -NewInputObject $NewRRObj -OldInputObject $OrigRRObj -ZoneName treyresearch.net
What are the requirements for Secure Updates?
How do you configure secure dynamic updates?
- The zone must be AD Integrated
- Do the following:
- Expand the Server
- Expand the Forward lookup Zones
- Select and Right-Click on the Zone
- Select Properties
- On the General Tab select Dynamic Updates: Secure only
Can you convert a file-base zone to an AD integrated zone by using PowerShell?
Yes using:
ConvertTo-DnsServerPrimaryZone -Name <name> -ReplicationScope <domain> -Force</domain></name>
- How would you configure all Zones to use scavenging?
- How would you configure just one Zones to use scavenging?
- The following Steps:
- Right Click the Server, Select Set Aging/Scavening for All Zones
- Check Scavenge stale resource records, Click ok
- Check Apply These Settings To The Existing Active Directory-Integrated Zones
- Right-Click the Server, Select Properties
- Click the Advanced Tab
- Select Enable Automatic Scavenging of stale records
- Right Click the Server, Select Set Aging/Scavening for All Zones
- The following Steps:
- Right Click the Server, Select Set Aging/Scavening for All Zones
- Check Scavenge stale resource records, Click ok
- Click Ok
- Right Click the Zone, Select Properties
- On the General Tab, select Aging
- Check Scavenge stale resource records
- Right Click the Server, Select Set Aging/Scavening for All Zones