az network-function traffic-collector collector-policy
Note
This reference is part of the traffic-collector extension for the Azure CLI (version 2.40.0 or higher). The extension will automatically install the first time you run an az network-function traffic-collector collector-policy command. Learn more about extensions.
Manage Collector Policy for Azure Traffic Collector resource.
Commands
Name | Description | Type | Status |
---|---|---|---|
az network-function traffic-collector collector-policy create |
Create a Collector Policy. |
Extension | GA |
az network-function traffic-collector collector-policy delete |
Delete a specified Collector Policy. |
Extension | GA |
az network-function traffic-collector collector-policy list |
List Collector policies. |
Extension | GA |
az network-function traffic-collector collector-policy show |
Get the specified Collector Policy. |
Extension | GA |
az network-function traffic-collector collector-policy update |
Update a specified Collector Policy. |
Extension | GA |
az network-function traffic-collector collector-policy wait |
Place the CLI in a waiting state until a condition is met. |
Extension | GA |
az network-function traffic-collector collector-policy create
Create a Collector Policy.
az network-function traffic-collector collector-policy create --collector-policy-name
--resource-group
--traffic-collector-name
[--emission-policies]
[--ingestion-policy]
[--location]
[--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
[--tags]
Examples
Create a new collector policy
az network-function traffic-collector collector-policy create --resource-group rg1 --traffic-collector-name atc1 --name cp1 --location eastus --ingestion-policy {ingestion-sources:[{resource-id:/subscriptions/<subscription_id>/resourceGroups/<resource_group>/providers/Microsoft.Network/expressRouteCircuits/<cp_name>,source-type:Resource}],ingestion-type:IPFIX}
Required Parameters
Collector Policy Name.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Azure Traffic Collector name.
Optional Parameters
Emission policies. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Ingestion policies. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Resource location. When not specified, the location of the resource group will be used.
Do not wait for the long-running operation to finish.
Resource tags. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az network-function traffic-collector collector-policy delete
Delete a specified Collector Policy.
az network-function traffic-collector collector-policy delete [--collector-policy-name]
[--ids]
[--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
[--resource-group]
[--subscription]
[--traffic-collector-name]
[--yes]
Examples
Delete a specified collector policy
az network-function traffic-collector collector-policy delete --resource-group rg1 --traffic-collector-name atc1 --name cp1
Optional Parameters
Collector Policy Name.
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Do not wait for the long-running operation to finish.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Azure Traffic Collector name.
Do not prompt for confirmation.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az network-function traffic-collector collector-policy list
List Collector policies.
az network-function traffic-collector collector-policy list --resource-group
--traffic-collector-name
Examples
Return a list of collector policies by resource group and traffic-collector name
az network-function traffic-collector collector-policy list --resource-group rg1 --traffic-collector-name atc1
Required Parameters
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Azure Traffic Collector name.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az network-function traffic-collector collector-policy show
Get the specified Collector Policy.
az network-function traffic-collector collector-policy show [--collector-policy-name]
[--ids]
[--resource-group]
[--subscription]
[--traffic-collector-name]
Examples
Get the specified collector policy
az network-function traffic-collector collector-policy show --resource-group rg1 --traffic-collector-name atc1 --name cp1
Optional Parameters
Collector Policy Name.
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Azure Traffic Collector name.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az network-function traffic-collector collector-policy update
Update a specified Collector Policy.
az network-function traffic-collector collector-policy update [--add]
[--collector-policy-name]
[--emission-policies]
[--force-string {0, 1, f, false, n, no, t, true, y, yes}]
[--ids]
[--ingestion-policy]
[--location]
[--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
[--remove]
[--resource-group]
[--set]
[--subscription]
[--tags]
[--traffic-collector-name]
Examples
Update a specified collector policy
az network-function traffic-collector collector-policy update --resource-group rg1 --traffic-collector-name atc1 --name cp1 --location eastus --emission-policies [0]={emission-destinations:[{destination-type:AzureMonitor}],emission-type:IPFIX}
Optional Parameters
Add an object to a list of objects by specifying a path and key value pairs. Example: --add property.listProperty <key=value, string or JSON string>
.
Collector Policy Name.
Emission policies. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
When using 'set' or 'add', preserve string literals instead of attempting to convert to JSON.
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Ingestion policies. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Resource location.
Do not wait for the long-running operation to finish.
Remove a property or an element from a list. Example: --remove property.list <indexToRemove>
OR --remove propertyToRemove
.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Update an object by specifying a property path and value to set. Example: --set property1.property2=<value>
.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Resource tags. Support shorthand-syntax, json-file and yaml-file. Try "??" to show more.
Azure Traffic Collector name.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
az network-function traffic-collector collector-policy wait
Place the CLI in a waiting state until a condition is met.
az network-function traffic-collector collector-policy wait [--collector-policy-name]
[--created]
[--custom]
[--deleted]
[--exists]
[--ids]
[--interval]
[--resource-group]
[--subscription]
[--timeout]
[--traffic-collector-name]
[--updated]
Optional Parameters
Collector Policy Name.
Wait until created with 'provisioningState' at 'Succeeded'.
Wait until the condition satisfies a custom JMESPath query. E.g. provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running'].
Wait until deleted.
Wait until the resource exists.
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Polling interval in seconds.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Maximum wait in seconds.
Azure Traffic Collector name.
Wait until updated with provisioningState at 'Succeeded'.
Global Parameters
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.