cache-policy¶
The following operations can be performed on "cache-policy":
rename| stat| show| rm| add| set| unset|
rename cache policy¶
Renames an existing cache policy.
Synopsis¶
rename cache policy
Arguments¶
policyName Existing name of the cache policy.
newName New name for the cache policy. Must begin with an ASCII alphabetic or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters.
Example¶
rename cache policy oldname newname
stat cache policy¶
Displays a summary of cache policy statistics.
Synopsis¶
stat cache policy [
Arguments¶
policyName Name of the cache policy for which to display statistics. If you do not set this parameter, statistics are shown for all cache policies.
detail Specifies detailed output (including more statistics). The output can be quite voluminous. Without this argument, the output will show only a summary.
fullValues Specifies that numbers and strings should be displayed in their full form. Without this option, long strings are shortened and large numbers are abbreviated
ntimes The number of times, in intervals of seven seconds, the statistics should be displayed. Default value: 1 Minimum value: 0
logFile The name of the log file to be used as input.
clearstats Clear the statsistics / counters
Possible values: basic, full
Output¶
count devno stateflag
Counters¶
Policy hits (Hits) Number of hits on the policy
Policy undef hits (Undefhits) Number of undef hits on the policy
Example¶
stat cache policy
Related Commands¶
show cache policy¶
Displays all configured cache policies. To display details about a particular cache policy, specify the name of the policy. When all caching policies are displayed, the order of the displayed policies within each group is the same as the evaluation order of the policies. There are three groups: request policies, response policies, and dynamic invalidation policies.
Synopsis¶
show cache policy [
Arguments¶
policyName Name of the cache policy about which to display details.
Output¶
stateflag rule The request/response rule that will trigger the specified action.
action The integrated cache action to be applied when the system sees content that matches the rules.
storeInGroup The content group that will store the object when the action directive is CACHE.
invalGroups The content group(s) to be invalidated when the action directive is INVAL.
invalObjects The content group(s) whose objects will be invalidated when the action directive is INVAL.
priority Priority.
hits Hits.
undefAction A CACHE action, to be used by the policy when the rule evaluation turns out to be undefined.
undefHits Number of Undef hits.
flags Flag.
precedeDefRules Override default request/response cacheability rules.
activePolicy Indicates whether policy is bound or not.
boundTo Location where policy is bound
gotoPriorityExpression Expression specifying the priority of the next policy which will get evaluated if the current policy rule evaluates to TRUE.
labelType Type of policy label invocation.
labelName Name of the label to invoke if the current policy rule evaluates to TRUE.
bindPolicyType vserverType builtin feature The feature to be checked while applying this config
type devno count
rm cache policy¶
Removes the specified caching policy. Make sure that the policy is not bound globally or to a virtual server. A bound policy cannot be removed.
Synopsis¶
rm cache policy
Arguments¶
policyName Name of the cache policy to be removed.
add cache policy¶
Creates an integrated caching policy. The newly created policy is in inactive state. To activate the policy, use the bind cache global command.
Synopsis¶
add cache policy
Arguments¶
policyName Name for the policy. Must begin with an ASCII alphabetic or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Can be changed after the policy is created.
rule Expression against which the traffic is evaluated. The following requirements apply only to the Citrix ADC CLI: * If the expression includes one or more spaces, enclose the entire expression in double quotation marks. * If the expression itself includes double quotation marks, escape the quotations by using the \ character. * Alternatively, you can use single quotation marks to enclose the rule, in which case you do not have to escape the double quotation marks.
action Action to apply to content that matches the policy. * CACHE or MAY_CACHE action - positive cachability policy * NOCACHE or MAY_NOCACHE action - negative cachability policy * INVAL action - Dynamic Invalidation Policy
Possible values: CACHE, NOCACHE, MAY_CACHE, MAY_NOCACHE, INVAL
storeInGroup Name of the content group in which to store the object when the final result of policy evaluation is CACHE. The content group must exist before being mentioned here. Use the "show cache contentgroup" command to view the list of existing content groups.
invalGroups Content group(s) to be invalidated when the INVAL action is applied. Maximum number of content groups that can be specified is 16.
invalObjects Content groups(s) in which the objects will be invalidated if the action is INVAL.
undefAction Action to be performed when the result of rule evaluation is undefined.
Possible values: NOCACHE, RESET
set cache policy¶
Modifies the specified attributes of an existing cache policy. The rule, flow type, can be changed only if action and undefAction (if present) are of NEUTRAL flow type.
Synopsis¶
set cache policy
Arguments¶
policyName Name for the policy. Must begin with an ASCII alphabetic or underscore (_) character, and must contain only ASCII alphanumeric, underscore, hash (#), period (.), space, colon (:), at (@), equals (=), and hyphen (-) characters. Can be changed after the policy is created.
rule Expression against which the traffic is evaluated. The following requirements apply only to the Citrix ADC CLI: * If the expression includes one or more spaces, enclose the entire expression in double quotation marks. * If the expression itself includes double quotation marks, escape the quotations by using the \ character. * Alternatively, you can use single quotation marks to enclose the rule, in which case you do not have to escape the double quotation marks.
action Action to apply to content that matches the policy. * CACHE or MAY_CACHE action - positive cachability policy * NOCACHE or MAY_NOCACHE action - negative cachability policy * INVAL action - Dynamic Invalidation Policy
Possible values: CACHE, NOCACHE, MAY_CACHE, MAY_NOCACHE, INVAL
storeInGroup Name of the content group in which to store the object when the final result of policy evaluation is CACHE. The content group must exist before being mentioned here. Use the "show cache contentgroup" command to view the list of existing content groups.
invalGroups Content group(s) to be invalidated when the INVAL action is applied. Maximum number of content groups that can be specified is 16.
invalObjects Content groups(s) in which the objects will be invalidated if the action is INVAL.
undefAction Action to be performed when the result of rule evaluation is undefined.
Possible values: NOCACHE, RESET
Example¶
set cache policy pol9 -rule "http.req.HEADER(\"header\").CONTAINS(\"qh2\")"
unset cache policy¶
Use this command to remove cache policy settings.Refer to the set cache policy command for meanings of the arguments.
Synopsis¶
unset cache policy