az network watcher connection-monitor
Manage connection monitoring between an Azure Virtual Machine and any IP resource.
Connection monitor can be used to monitor network connectivity between an Azure virtual machine and an IP address. The IP address can be assigned to another Azure resource or a resource on the Internet or on-premises. To learn more visit https://aka.ms/connectionmonitordoc.
Commands
az network watcher connection-monitor create
Create a connection monitor.
This extension allow to create V1 and V2 version of connection monitor. V1 connection monitor supports single source and destination endpoint which comes with V1 argument groups as usual. V2 connection monitor supports multiple endpoints and several test protocol which comes with V2 argument groups.
az network watcher connection-monitor create --name
[--dest-address]
[--dest-port]
[--dest-resource]
[--do-not-start]
[--endpoint-dest-address]
[--endpoint-dest-coverage-level {AboveAverage, Average, BelowAverage, Default, Full, Low}]
[--endpoint-dest-name]
[--endpoint-dest-resource-id]
[--endpoint-dest-type {AzureSubnet, AzureVM, AzureVNet, ExternalAddress, MMAWorkspaceMachine, MMAWorkspaceNetwork}]
[--endpoint-source-address]
[--endpoint-source-coverage-level {AboveAverage, Average, BelowAverage, Default, Full, Low}]
[--endpoint-source-name]
[--endpoint-source-resource-id]
[--endpoint-source-type {AzureSubnet, AzureVM, AzureVNet, ExternalAddress, MMAWorkspaceMachine, MMAWorkspaceNetwork}]
[--frequency]
[--http-method {Get, Post}]
[--http-path]
[--http-port]
[--http-valid-status-codes]
[--https-prefer {false, true}]
[--icmp-disable-trace-route {false, true}]
[--location]
[--monitoring-interval]
[--notes]
[--output-type {Workspace}]
[--preferred-ip-version {IPv4, IPv6}]
[--protocol {Http, Icmp, Tcp}]
[--resource-group]
[--source-port]
[--source-resource]
[--subscription]
[--tags]
[--tcp-disable-trace-route {false, true}]
[--tcp-port]
[--tcp-port-behavior {ListenIfAvailable, None}]
[--test-config-name]
[--test-group-disable {false, true}]
[--test-group-name]
[--threshold-failed-percent]
[--threshold-round-trip-time]
[--workspace-ids]
Examples
Create a connection monitor for a virtual machine.
az network watcher connection-monitor create -g MyResourceGroup -n MyConnectionMonitorName \
--source-resource MyVM
Create a V2 connection monitor
az network watcher connection-monitor create --name MyV2ConnectionMonitor --endpoint-source-name "vm01" --endpoint-source-resource-id MyVM01ResourceID --endpoint-dest-name bing --endpoint-dest-address bing.com --test-config-name TCPTestConfig --protocol Tcp --tcp-port 2048
Create a connection monitor. (autogenerated)
az network watcher connection-monitor create --endpoint-dest-address bing.com --endpoint-dest-name bing --endpoint-source-name "vm01" --endpoint-source-resource-id MyVM01ResourceID --location westus2 --name MyConnectionMonitorName --protocol Tcp --tcp-port 2048 --test-config-name TCPTestConfig
Required Parameters
Connection monitor name.
Optional Parameters
The IP address or URI at which to receive traffic.
Port number on which to receive traffic.
Currently only Virtual Machines are supported.
Create the connection monitor but do not start it immediately.
Address of the destination of connection monitor endpoint (IP or domain name).
Test coverage for the endpoint.
The name of the destination of connection monitor endpoint. If you are creating a V2 Connection Monitor, it's required.
Resource ID of the destination of connection monitor endpoint.
The endpoint type.
Address of the source of connection monitor endpoint (IP or domain name).
Test coverage for the endpoint.
The name of the source of connection monitor endpoint. If you are creating a V2 Connection Monitor, it's required.
Resource ID of the source of connection monitor endpoint. If endpoint is intended to used as source, this option is required.
The endpoint type.
The frequency of test evaluation, in seconds.
The HTTP method to use.
The path component of the URI. For instance, "/dir1/dir2".
The port to connect to.
Space-separated list of HTTP status codes to consider successful. For instance, "2xx 301-304 418".
Value indicating whether HTTPS is preferred over HTTP in cases where the choice is not explicit.
Value indicating whether path evaluation with trace route should be disabled. false is default.
Location. Values from: az account list-locations
. You can configure the default location using az configure --defaults location=<location>
.
Monitoring interval in seconds.
Optional notes to be associated with the connection monitor.
Connection monitor output destination type. Currently, only "Workspace" is supported.
The preferred IP version to use in test evaluation. The connection monitor may choose to use a different version depending on other parameters.
The protocol to use in test evaluation.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Port number from which to originate traffic.
Currently only Virtual Machines are supported.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Space-separated tags: key[=value] [key[=value] ...]. Use "" to clear existing tags.
Value indicating whether path evaluation with trace route should be disabled. false is default.
The port to connect to.
Destination port behavior.
The name of the connection monitor test configuration. If you are creating a V2 Connection Monitor, it's required.
Value indicating whether test group is disabled. false is default.
The name of the connection monitor test group.
The maximum percentage of failed checks permitted for a test to evaluate as successful.
The maximum round-trip time in milliseconds permitted for a test to evaluate as successful.
Space-separated list of ids of log analytics workspace.
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.
Increase logging verbosity. Use --debug for full debug logs.
az network watcher connection-monitor delete
Delete a connection monitor for the given region.
az network watcher connection-monitor delete --location
--name
[--subscription]
Examples
Delete a connection monitor for the given region.
az network watcher connection-monitor delete -l westus -n MyConnectionMonitorName
Required Parameters
Location. Values from: az account list-locations
. You can configure the default location using az configure --defaults location=<location>
.
Connection monitor name.
Optional Parameters
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
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.
Increase logging verbosity. Use --debug for full debug logs.
az network watcher connection-monitor list
List connection monitors for the given region.
az network watcher connection-monitor list --location
[--query-examples]
[--subscription]
Examples
List a connection monitor for the given region.
az network watcher connection-monitor list -l westus
List connection monitors for the given region. (autogenerated)
az network watcher connection-monitor list --location westus --subscription MySubscription
Required Parameters
Location. Values from: az account list-locations
. You can configure the default location using az configure --defaults location=<location>
.
Optional Parameters
Recommend JMESPath string for you. You can copy one of the query and paste it after --query parameter within double quotation marks to see the results. You can add one or more positional keywords so that we can give suggestions based on these key words.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
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.
Increase logging verbosity. Use --debug for full debug logs.
az network watcher connection-monitor query
Query a snapshot of the most recent connection state of a connection monitor.
az network watcher connection-monitor query --location
--name
[--subscription]
Examples
List a connection monitor for the given region.
az network watcher connection-monitor query -l westus -n MyConnectionMonitorName
Required Parameters
Location. Values from: az account list-locations
. You can configure the default location using az configure --defaults location=<location>
.
Connection monitor name.
Optional Parameters
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
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.
Increase logging verbosity. Use --debug for full debug logs.
az network watcher connection-monitor show
Shows a connection monitor by name.
az network watcher connection-monitor show --location
--name
[--query-examples]
[--subscription]
Examples
Show a connection monitor for the given name.
az network watcher connection-monitor show -l westus -n MyConnectionMonitorName
Required Parameters
Location. Values from: az account list-locations
. You can configure the default location using az configure --defaults location=<location>
.
Connection monitor name.
Optional Parameters
Recommend JMESPath string for you. You can copy one of the query and paste it after --query parameter within double quotation marks to see the results. You can add one or more positional keywords so that we can give suggestions based on these key words.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
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.
Increase logging verbosity. Use --debug for full debug logs.
az network watcher connection-monitor start
Start the specified connection monitor.
az network watcher connection-monitor start --location
--name
[--subscription]
Examples
Start the specified connection monitor.
az network watcher connection-monitor start -l westus -n MyConnectionMonitorName
Required Parameters
Location. Values from: az account list-locations
. You can configure the default location using az configure --defaults location=<location>
.
Connection monitor name.
Optional Parameters
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
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.
Increase logging verbosity. Use --debug for full debug logs.
az network watcher connection-monitor stop
Stop the specified connection monitor.
az network watcher connection-monitor stop --location
--name
[--subscription]
Examples
Stop the specified connection monitor.
az network watcher connection-monitor stop -l westus -n MyConnectionMonitorName
Required Parameters
Location. Values from: az account list-locations
. You can configure the default location using az configure --defaults location=<location>
.
Connection monitor name.
Optional Parameters
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
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.
Increase logging verbosity. Use --debug for full debug logs.