?
Solved

DNS Scavenging

Posted on 2011-05-12
10
Medium Priority
?
920 Views
Last Modified: 2012-05-11
Guys

if I want to just mark with timestamp all the records for a zone, without let the server to remove stale resource records. what I want to do is mark all the records with timestamp, wait around 3 weeks (21 days) and then when all the records are marked, enable scavenging.

Which would be the correct proceddure (REAL WORLD) to achieve this?

Thanks very much.
0
Comment
Question by:M7K
  • 3
  • 2
  • 2
  • +2
10 Comments
 

Author Comment

by:M7K
ID: 35745336
Hi MinoDC

Thanks for that but unfortunately it does not answer my question.
0
 
LVL 26

Expert Comment

by:Leon Fester
ID: 35745363
dnscmd /ageallrecords

Usage: DnsCmd <ServerName> /AgeAllRecords <ZoneName> [<NodeName>] [/Tree] [/f]
    <Zone>     -- <ZoneName>
    <ZoneName> -- FQDN of a zone
    <NodeName> -- name or node or subtree in which to enable aging
                   - "@" for zone root OR
                   - FQDN of a node (name with a '.' at the end) OR
                   - single label for name relative to zone root
    /Tree      -- force aging on entire subtree of node
                    or entire zone if node not given
    /f         -- execute without asking for confirmation
Command failed:  ERROR_INVALID_PARAMETER     87    0x57

Just be aware that even static and CNAME records will be aged.
0
Free Backup Tool for VMware and Hyper-V

Restore full virtual machine or individual guest files from 19 common file systems directly from the backup file. Schedule VM backups with PowerShell scripts. Set desired time, lean back and let the script to notify you via email upon completion.  

 
LVL 39

Accepted Solution

by:
ChiefIT earned 2000 total points
ID: 35745375
There's no need to mark a record with a time stamp. Clients do this as they register within DNS.

There are two intervals within DNS scavaging. There is a no-refresh and a refresh interval. By default, they are set to 7 and 7. This means that the DNS record will scavage (or be deleted) on the 15th day.

You want DNS scavaging to be a day or two longer than your DHCP lease duration. Then, a client with a new lease will not get the DNS record delted before getting a lease update.

Just enable scavaging. That's really all you have to do, if your DHCP lease duration is the default duration of (I believe 9 days).
0
 

Author Comment

by:M7K
ID: 35745399
Chief

Thanks for that, but as far as I understand, if I enable scavenging without aging all the records, records that are older than the timestamp when enable scavenging (today) will be removed, even static. so we need to age all the records first.
0
 
LVL 9

Expert Comment

by:MinoDC
ID: 35745420
0
 
LVL 26

Expert Comment

by:Leon Fester
ID: 35745425
You've seem to have missed my post....read the one above ChiefIT.
0
 
LVL 26

Expert Comment

by:Leon Fester
ID: 35745451
Ignore my previous post...I've re-read what you've just posted.
Sorry ChiefIT...earlier post wasn't aimed at you.

I don't think you understand what aging records do.
Aging a record will set the time stamp on a DNS entry, so that when scavenging is enabled it deletes all records older than the current date.

You cannot set the age of a DNS record to be newer than today. i.e. you cannot set the age of a record to be 05/15/2011 if today is 05/12/2011.

Aging a record, gives the time stamp of the current day/time.

If you want to set your records NOT to be deleted when scavenging then set a high Lease time on your DHCP server, and recreate your static entries.

Any manually created record A or CNAME will not have the timestamp set so it will not be removed by scavenging.

You can use the DNSCMD command to do bulk insert of any static entries, A or CNAME that you may need.
0
 
LVL 31

Expert Comment

by:Justin Owens
ID: 35746794
Enabling DNS Scavenging should not remove static DNS entries, only dynamic ones.  If you are worried about that, though, just export your DNS records.  If scavenging removes them, then you can import them again.

DrUltima
0
 
LVL 39

Assisted Solution

by:ChiefIT
ChiefIT earned 2000 total points
ID: 35749907
As long as you take into consideration the DHCP lease duration and do not scavage records before the DHCP lease duration ends, the dynamic entries will NOT be erased. Static entries will not be erased either.

Let's look at that another way. Static entries will not be erased, as Dr. Ultima stated. So, that leaves dynamic updates. These will not be deleted either because the DHCP address was renewed and the client registered during that time. So, these records will be TOO NEW to scavage.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article provides a convenient collection of links to Microsoft provided Security Patches for operating systems that have reached their End of Life support cycle. Included operating systems covered by this article are Windows XP,  Windows Server…
Let's recap what we learned from yesterday's Skyport Systems webinar.
This tutorial will walk an individual through the process of configuring their Windows Server 2012 domain controller to synchronize its time with a trusted, external resource. Use Google, Bing, or other preferred search engine to locate trusted NTP …
This video shows how to use Hyena, from SystemTools Software, to update 100 user accounts from an external text file. View in 1080p for best video quality.

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question