Set method of the PS_DnsServerCache class

Updates the settings of a DNS server cache.


uint32 Set(
  [in]  boolean        StoreEmptyAuthenticationResponse,
  [in]  uint32         MaxKBSize,
  [in]  boolean        PollutionProtection,
  [in]  string         ComputerName,
  [in]  uint32         LockingPercent,
  [in]  datetime       MaxNegativeTtl,
  [in]  datetime       MaxTtl,
  [in]  boolean        PassThru,
  [in]  boolean        IgnorePolicies,
  [out] DnsServerCache cmdletOutput


StoreEmptyAuthenticationResponse [in]

A boolean value indicating if the DNS server will store empty authoritative responses [RFC2308] in the cache. The value should be limited to 0x00000000 and 0x00000001, but it may be any value. The default value must be 0x00000001, and the value zero must be allowed and treated literally.

MaxKBSize [in]

Specifies the maximum size, in kilobytes, of the DNS server's memory cache.

PollutionProtection [in]

Determines whether DNS filters records that are saved in a cache. Saves all responses to name queries to a cache. This is the default setting. Saves only the records that belong to the same DNS subtree to a cache.

ComputerName [in]

Specifies the remote computer on which to execute the command.

LockingPercent [in]

The percentage of the original time-to-live value for which all cache entries from non-authoritative responses must be locked and must not be overwritten by data found in subsequent non-authoritative responses. Locked cache entries must still be considered for removal from the cache if the soft limit of the maximum cache size is reached (see the MaxCacheSize property described previously in this section). The value must be limited to the range 0x00000000 to 0x00000064. The default value must be 0x00000064, and the value zero must be allowed and treated literally. The Validation range = 0 to 100.

MaxNegativeTtl [in]

Specifies how many seconds (0x1-0xFFFFFFFF) an entry that records a negative answer to a query remains stored in the DNS cache. The default setting is 0x384 (900) seconds. Validation range = 0 to 2592000.

MaxTtl [in]

Determines how many seconds (0x0-0xFFFFFFFF) a record is saved in cache. If the 0x0 setting is used, then the DNS server does not cache records. The default setting is 0x15180 (86,400 seconds or 1 day). Validation range = 0 to 2592000.

PassThru [in]

true to return the current instance in the CmdletOutput parameter. The default is false.

IgnorePolicies [in]

true if the policies of the cache are to be ignored; otherwise, false.

Windows Server 2012 R2 and Windows Server 2012:  Not supported.

cmdletOutput [out]

On return, contains an instance of the current object. This parameter returns a value only if PassThru is set to true.


Minimum supported client

None supported

Minimum supported server

Windows Server 2012







See also