Skip to main content
Version: Archive

DxCLI Admin Guide

Introduction

This document contains the list of DxCLI commands used for DxOdyssey administration.

Commands

activate-server

Description

Activates the server via internet using the provided license key. See get-license-request for offline gateway activation.

Syntax

dxcli activate-server <license_key> [gateway][,...]

Parameters

NameDescriptionTypeRequired
license_keyThe license key.StringTrue
gateway_nameThe name of the gateway. Leaving this parameter blank will activate the current gateway.StringFalse
,...Comma-delimited list of gateway names for multiple activations.False

Example 1: Activate the current gateway

dxcli activate-server AAAA-BBBB-CCCC-DDDD

Example 2: Activate multiple gateways

dxcli activate-server AAAA-BBBB-CCCC-DDDD gateway1,gateway2,gateway4

add-addressfilter

Description

Adds an address filter for accepting or denying connections from specific IP addresses or subnets.

Syntax

dxcli add-addressfilter <filter_name> <address>,<action>[|...] <default_action>

Parameters

NameDescriptionTypeRequired
filter_nameThe name of the filter.StringTrue
addressThe IP address or subnet.StringTrue
actionWhether or not to accept or deny the IP address or subnet. Must be accept or deny.StringTrue
|...Pipe-delimited list of additional address filters.False
default_actionSets the default action for the address filter to accept all or deny all connections outside of the specified IP or subnet from the previous parameter. Must be accept or deny.StringTrue

Example

dxcli add-addressfilter filter1 "10.1.1.0,accept|10.1.2.0,accept" deny

add-client

Description

Adds a DxConnect client to the gateway group.

Syntax

add-client <client_name> <client_password> [client_description] [max_session_count] [group_name]

Parameters

NameDescriptionTypeRequired
client_nameThe name of the client.StringTrue
client_passwordThe password for the client.StringTrue
client_desciptionThe description for the client.StringFalse
max_session_countThe maximum number of active sessions for the client.IntFalse
group_nameThe name of the client group to add the client to.StringFalse

Example

dxcli add-client client1 passw0rd "Accounting admins" 25 group1

add-client-group

Description

Adds a client group consisting of one or more clients.

Syntax

dxcli add-client-group <group_name> [client_name][,...] [group_description]

Parameters

NameDescriptionTypeRequired
group_nameThe name of the group.StringTrue
client_nameThe name of the client to add to the client group. Running the command without a client will create an empty client group.StringFalse
,...Comma-delimited list of additional clients to add to the client group.False
group_descriptionThe description for the group.StringFalse

Example

dxcli add-client-group group1 client1,client2,client3

add-gateway

Description

Adds the specified gateway to a tunnel group.

Syntax

dxcli add-gateway <tunnel_group> <gateway_name>

Parameters

NameDescriptionRequired
tunnel_groupThe name of the tunnel group.True
gateway_nameThe name of the gateway.True

Example

dxcli add-gateway tunnel_group1 gateway1

add-tunnel

Description

Add a tunnel to the gateway group.

Syntax

dxcli add-tunnel <tunnel_name> <enabled> <destination_gateway_name> <target_address>:<target_port> <origin_gateway>,<origin_address>:<origin_port>[/address_filter][|...] [tunnel_group_name]

Parameters

NameDescriptionTypeRequired
tunnel_nameThe name of the tunnel.StringTrue
enabledEnable the tunnel.BoolTrue
destination_gateway_nameThe name of the destination gateway.StringTrue
target_addressThe target IP address or hostname of the tunnel destination.StringTrue
target_portThe port number for the target.IntTrue
origin_gatewayThe name of the origin gateway. This is the gateway where the tunnel listener will be active.StringTrue
origin_addressThe IP address the origin will bind to. Can be set to 0.0.0.0 to allow connections from any IP address with network access, or 127.0.0.1 to only allow connections from the gateway itself.StringTrue
origin_portThe port number for the origin address.IntTrue
address_filterThe name of the address filter to associate with the tunnel. See dxcli add-addressfilter for more information.StringFalse
|...Pipe-delimited list of additional origins.False
tunnel_group_nameThe name of the tunnel group to associate with the tunnel.StringFalse

Example

dxcli add-tunnel tunnel1 true gateway1 10.1.200.62:30004 "gateway2,0.0.0.0:30004/FILTER1|gateway3,127.0.0.1:30004/FILTER2" GATEWAYGROUP1

add-witness

Description

Add a network fileshare witness.

LEGACY

This command has been superseded by dxcli set-witness. Do not use this command for Azure Blob Storage.

Syntax

dxcli add-witness <share_path>[,...] <username> <password>

Parameters

NameDescriptionTypeRequired
share_pathThe UNC path of the network share.StringTrue
,...Comma-delimited list of additional UNC paths.False
usernameThe name of the user.StringTrue
passwordThe password of the user (recommended to encrypt using dxcli encrypt-text).StringTrue

Example 1: Add a Single Witness

dxcli add-witness "\\server1\myshare1" "user1" "6pnFaDrRS+W/F+dkRuPKAA=="

Example 2: Add Multiple Witnesses

dxcli add-witness "\\server1\myshare1,\\server2\myshare2" "user1" "6pnFaDrRS+W/F+dkRuPKAA=="

Example 3: Add an Azure File Share

dxcli add-witness "\\mystorage.file.core.windows.net\azshare1" "mystorage" "/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33=="

clear-otpk

Description

Clears and invalidates any generated One-Time PassKey for the gateway group.

Syntax

dxcli clear-otpk

Parameters

None

Example

dxcli clear-otpk

collect-log

Description

Generates logs on the specified gateway(s). Logs will be gathered from every gateway in the gateway group if collect log is run without a gateway_name parameter.

Log locations
Windows

The logs are created in the installation directory for DxOdyssey in the Support folder. By default this is C:\Program Files\DH2i\Support.

Linux

The logs are created in the /opt/dh2i/support folder.

Containers

collect-log is not supported in containers. Use docker logs or an equivalent command from the host to gather logs from DxOdyssey containers.

Syntax

dxcli collect-log [gateway_name][,...]

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringFalse
,...Comma-delimited list of additional nodes.False

Example

dxcli collect-log gateway1,gateway2,gateway3

deactivate-server

Description

Deactivates and clears the license on the specified gateway.

Syntax

dxcli deactivate-server <gateway_name>

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringTrue

Example

dxcli deactivate-server gateway1

encrypt-text

Description

Encrypts text for use in other DxCLI commands.

Syntax

dxcli encrypt-text <value>

Parameters

NameDescriptionTypeRequired
valueThe text to be encrypted.StringTrue

Example

dxcli encrypt-text p@ssw0rd

export-config

Description

Exports a client configuration file to be used on DxConnect client machines.

Syntax

dxcli export-config <file_name>

Parameters

NameDescriptionTypeRequired
file_nameThe name of the file, including the .dh2i extension. The file will be created in the working directory if no directory is included as part of the filename.StringTrue

Example

dxcli export-config dxe_client.dh2i

gateway-group-add-tunnel-group

Description

Adds a tunnel group to the gateway group.

Syntax

dxcli gateway-group-add-tunnel-group <tunnel_group> <virtual_ip>[,...] <gateway_name>[,...]

Parameters

NameDescriptionTypeRequired
tunnel_group_nameThe name of the tunnel group.StringTrue
virtual_ipThe virtual IP for the tunnel group.StringTrue
,...Comma-delimited list of additional virtual IPs for the tunnel group.False
gateway_nameThe name of the gateway to add to the tunnel group.StringTrue
,...Comma-delimited list of additional gateways to add to the tunnel group.False

Example

dxcli gateway-group-add-tunnel-group tunnel_group1 10.1.200.10,*127.0.0.1 gateway1,gateway2,gateway3

gateway-group-disable-gateway

Description

Disables the specified gateway.

Syntax

dxcli gateway-group-disable-gateway <gateway_name>

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringTrue

Example

dxcli gateway-group-disable-gateway gateway1

gateway-group-enable-gateway

Description

Enables the specified gateway.

Syntax

dxcli gateway-group-enable-gateway <gateway_name>

Parameters

NameDescriptionTypeRequired
gatewayThe name of the gateway.StringTrue

Example

dxcli gateway-group-enable-gateway gateway1

gateway-group-get-features

Description

Returns all gateway group members’ enabled features on a per-gateway basis, in XML.

Syntax

dxcli gateway-group-get-features

Parameters

None

Example

dxcli gateway-group-get-features

gateway-group-get-licenses

Description

Returns a list of licenses.

Syntax

dxcli gateway-group-get-licenses

Parameters

None

Example

dxcli gateway-group-get-licenses

gateway-group-remove-tunnel-group

Description

Removes a tunnel group from the gateway group.

Syntax

dxcli gateway-group-remove-tunnel-group <tunnel_group_name>

Parameters

NameDescriptionTypeRequired
tunnel_group_nameThe name of the tunnel group.StringTrue

Example

dxcli gateway-group-remove-tunnel-group tunnel_group1

gateway-group-resync

Description

Forces a re-synchronization of the gateway group.

Syntax

dxcli gateway-group-resync

Parameters

None

Example

dxcli gateway-group-resync

gateway-group-set-secret

Description

Begins interactive process of setting the gateway group passkey. This command cannot be run remotely.

Syntax

dxcli gateway-group-set-secret

Parameters

Interactive only.

Example

dxcli gateway-group-set-secret

gateway-group-set-secret-ex

Description

Sets the gateway group passkey non-interactively. This command cannot be run remotely.

Syntax

dxcli gateway-group-set-secret-ex <passkey>

Parameters

NameDescriptionTypeRequired
passkeyThe passkey of for the gateway group.StringTrue

Example

dxcli gateway-group-set-secret-ex PassKey

generate-otpk

Description

Generates a new One-Time PassKey to use with dxcli set-otpk.

Syntax

dxcli generate-otpk

Parameters

None

Example

dxcli generate-otpk

get-addressfilter

Description

Returns details for the specified address filter.

Syntax

dxcli get-addressfilter <filter_name>

Parameters

NameDescriptionTypeRequired
filter_nameThe name of the address filter.StringTrue

Example

dxcli get-addressfilter filter1

get-alerts

Description

Returns any active alerts for the gateway group.

Syntax

dxcli get-alerts

Parameters

None

Example

dxcli get-alerts

get-client-connections

Description

Returns all active client connections.

Syntax

dxcli get-client-connections

Parameters

None

Example

dxcli get-client-connections

get-client-detail

Description

Returns the details for the specified client.

Syntax

dxcli get-client-detail <client_name>

Parameters

NameDescriptionTypeRequired
client_nameThe name of the client.StringTrue

Example

dxcli get-client-detail client1

get-coordinators

Description

Returns which gateway group member(s) are the gateway group and app coordinators.

Syntax

dxcli get-coordinators

Parameters

None

Example

dxcli get-coordinators

get-coordinator-status

Description

Returns detailed status information for the gateway group coordinator.

Syntax

dxcli get-coordinator-status

Parameters

None

Example

dxcli get-coordinator-status

get-dxversion

Description

Returns the version of DxOdyssey installed on the current gateway.

Syntax

dxcli get-dxversion

Parameters

None

Example

dxcli get-dxversion

get-features

Description

Returns a list of features enabled on the connected gateway.

Syntax

dxcli get-features

Parameters

None

Example

dxcli get-features

get-gateway-detail

Description

Returns detailed information about the gateway.

Syntax

dxcli get-gateway-detail [gateway_name]

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringFalse

Example

dxcli get-gateway-detail

get-gateway-detail-xml

Description

Returns detailed information about the gateway in XML format.

Syntax

dxcli get-gateway-detail-xml [gateway_name]

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringFalse

Example

dxcli get-gateway-detail-xml

get-gateway-group-gateways

Description

Returns the name, IP, pubkey hash, status, role, and operating system of each gateway in the gateway group.

Syntax

dxcli get-gateway-group-gateways

Parameters

None

Example

dxcli get-gateway-group-gateways

get-globalsettings

Description

Returns any non-default configurations of global settings.

Syntax

dxcli get-globalsettings

Parameters

None

Example

dxcli get-globalsettings

get-interfaces

Description

Returns an XML output of all interfaces available for connected gateway group, or a specified gateway if supplied.

Syntax

dxcli get-interfaces [gateway_name]

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringFalse
dxcli get-interfaces gateway1

Example

dxcli get-interfaces gateway1

get-license

Description

Returns the license key for the specified gateway.

Syntax

dxcli get-license <gateway_name>

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringTrue

Example

dxcli get-license gateway1

get-license-detail

Description

Returns details for license including license key, product, expirations, etc. for the connected server, or for a specified gateway.

Syntax

dxcli get-license-detail [gateway_name]

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringFalse

Example

dxcli get-license-detail gateway1

get-license-request

Description

Returns a license request for a gateway; use in conjunction with set-license. Go to https://clients.dh2i.com/Data/Activation.aspx and paste the output of get-license-request to obtain an activation response. The response from the website is used in the set-license command to activate the server.

Syntax

dxcli get-license-request <license_key> [gateway_name]

Parameters

NameDescriptionTypeRequired
license_keyThe license of the gateway.StringTrue
gateway_nameThe name of the gateway.StringFalse

Example

dxcli get-license-request AAAA-BBBB-CCCC-DDDD gateway1

get-otpk

Description

Returns the current One-Time PassKey (OTPK) for the gateway group and its expiration date.

Syntax

dxcli get-otpk

Parameters

None

Example

dxcli get-otpk

get-producttype

Description

Returns the product name and license features. This command cannot be run remotely.

Syntax

dxcli get-producttype

Parameters

None

Example

dxcli get-producttype

get-tunnel-group

Description

Returns configuration information for the given tunnel group.

Syntax

dxcli get-tunnel-group <tunnel_group_name>

Parameters

NameDescriptionTypeRequired
tunnel_group_nameThe name of the tunnel group.StringTrue

Example

dxcli get-tunnel-group tunnel_group1

get-tunnel-groups

Description

Returns configuration information for all tunnel groups.

Syntax

dxcli get-tunnel-groups

Parameters

None

Example

dxcli get-tunnel-groups

get-witness

Description

Returns the current witness settings for the gateway group.

Syntax

dxcli get-witness

Parameters

None

Example

dxcli get-witness

join-gateway-group

Description

Begin the interactive process of joining a gateway group. This command cannot be run remotely.

Syntax

dxcli join-gateway-group

Parameters

Interactive only.

Example

dxcli join-gateway-group

join-gateway-group-ex

Description

Join a gateway group non-interactively. This command cannot be run remotely.

Syntax

dxcli join-gateway-group-ex <target> <passkey> <use_nat>

Parameters

NameDescriptionTypeRequired
targetThe IP of the target server.StringTrue
passkeyThe passkey of the target server.StringTrue
use_natSpecifies whether or not to use the DH2i Matchmaking Service. Use match.dh2i.com as the target and an OTPK instead of a passkey. Default value is false. See dxcli set-otpk for more information.BoolFalse

Example 1: Local Join

dxcli join-gateway-group-ex 10.2.2.29 passkey

Example 2: NAT Join

dxcli join-gateway-group-ex match.dh2i.com dxcli join-cluster-ex match.dh2i.com xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx true

list-globalsettings

Description

Returns a list of all available global settings in plain text, including their definitions and defaults.

Syntax

dxcli list-globalsettings

Parameters

None

Example

dxcli list-globalsettings

list-globalsettings-xml

Returns a list of all available global settings in XML, including their definitions and defaults.

Syntax

dxcli list-globalsettings-xml

Parameters

None

Example

dxcli list-globalsettings-xml

remove-addressfilter

Description

Removes an address filter from the gateway group.

Syntax

dxcli remove-addressfilter <filter_name>

Parameters

NameDescriptionTypeRequired
filter_nameThe name of the address filter.StringTrue

Example

dxcli remove-addressfilter FILTER1

remove-client

Description

Removes a DxConnect client from the gateway group.

Syntax

dxcli remove-client <client_name>

Parameters

NameDescriptionTypeRequired
client_nameThe name of the client.StringTrue

Example

dxcli remove-client client1

remove-client-group

Description

Removes a DxConnect client group from the gateway group.

Syntax

dxcli remove-client-group <group_name>

Parameters

NameDescriptionTypeRequired
group_nameThe name of the group.StringTrue

Example

dxcli remove-client-group group1

remove-gateway

Description

Removes a gateway from the specified tunnel group.

Syntax

dxcli remove-gateway <tunnel_group_name> <gateway_name>

Parameters

NameDescriptionTypeRequired
gateway_group_nameThe name of the gateway group.StringTrue
gateway_nameThe name of the gateway.StringTrue

Example

dxcli remove-gateway tunnel_group1 gateway1

remove-gateway-group-members

Description

Remove a gateway from the gateway group.

Syntax

dxcli remove-gateway-group-members <gateway_name>[,...]

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringTrue
,...Comma-delimited list of addtional gateways to remove from the gateway group.False

Example

dxcli remove-gateway-group-members gateway1

remove-globalsetting

Description

Resets a global setting to its default value.

Syntax

dxcli remove-globalsetting <setting_name>

Parameters

NameDescriptionTypeRequired
setting_nameThe name of the global setting. Run dxcli get-globalsettings to list any non-default global settings.StringTrue

Example

dxcli remove-globalsetting timeout.ping

remove-tunnel

Description

Remove a tunnel from the gateway group.

Syntax

dxcli remove-tunnel <tunnel_name>

Parameters

NameDescriptionTypeRequired
tunnel_nameThe name of the tunnel.StringTrue

Example

dxcli remove-tunnel tunnel1

remove-witness

Description

Remove current witness settings for the gateway group.

Syntax

dxcli remove-witness

Parameters

None

Example

dxcli remove-witness

set-appcoordinator

Description

Assigns the application coordinator role to the specified gateway.

Syntax

dxcli set-appcoordinator <gateway_name>

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringTrue

Example

dxcli set-appcoordinator gateway1

set-gateway-group-member-addresses

Description

Sets the gateway’s interface(s) and protocol(s) for gateway group communication.

Syntax

dxcli set-gateway-group-member-addresses <gateway_name> <ip>[,...]

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringTrue
ipIP Address, alias, or asterisk("*") to assign to the gateway. The asterisk (*) selection will cycle through the interfaces until a valid connection is established to the other gateway group members.StringTrue
,...Ordered, comma-delimited list for multiple IP addresses and/or aliases. The order in which the interfaces and/or protocols are ordered determine their priority, from highest to lowest.False

Example 1: Set the gateway IP address

dxcli set-gateway-group-member-addresses gateway1 1.2.3.4

Example 2: Set an interface and IP address

dxcli set-gateway-group-member-addresses gateway1 "{eth0:IPV4},172.16.1.1"

Example 3: Set to default bind all

dxcli set-gateway-group-member-addresses gateway1 "*"

set-coordinator

Description

Sets the gateway group coordinator.

Syntax

dxcli set-coordinator <gateway_name>

Parameters

NameDescriptionTypeRequired
gateway_nameThe name of the gateway.StringTrue

Example

dxcli set-coordinator gateway1

set-globalsetting

Description

Assigns a new value to a global setting. For more information on the available global settings, please see [DxCLI Global Settings for DxOdyssey].

Syntax

dxcli set-globalsetting <setting_key> <setting_value>

Parameters

NameDescriptionTypeRequired
setting_keyThe name of the global setting.StringTrue
setting_valueThe value for the global setting.String, Int, BoolTrue

Example

dxcli set-globalsetting timeout.ping 10

set-license

Description

Activates a gateway that has no internet connection; used in conjunction with get-license-request.

Syntax

dxcli set-license <license_key> <license_response> [gateway_name]

Parameters

NameDescriptionTypeRequired
license_keyThe license key for the gateway.StringTrue
license_responseThe activation response string given by the Client Portal.StringTrue
gateway_nameThe name of the gateway. If no gateway is specified, the command defaults to the currently connected gateway.StringFalse

Example

dxcli set-license AAAA-BBBB-CCCC-DDDD 2ki44uOaLK4gbfjSStNVUXNQsM4eMwjVRBNyAQrp6UABN0frE9ZiGwhP1oxLD+y6F5UDwfaZkTZqQF0JfoEpGhu8V8WAS/dkOGNkBqGv2Qi+Nuc21kV/d2p4elTZSdI2rGrL== gateway2

set-otpk

Description

Sets the One-Time PassKey (OTPK).

Syntax

dxcli set-otpk [expiration_date] [otpk]

Parameters

NameDescriptionTypeRequired
expiration_dateThe time and date the One-Time PassKey will expire. Should be formatted as YYYY-MM-DDTHH:MM:SS. Leaving this parameter empty will default the expiration to one hour.StringFalse
otpkThe One-Time Passkey in base64. A One-Time PassKey can be generated using dxcli generate-otpk.StringFalse

Example

dxcli set-otpk 2021-01-01T18:00:00 xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

set-server

Description

Interactively connect to a remote gateway for gateway group administration.

Syntax

dxcli set-server

Parameters

Interactive only.

Example

dxcli set-server

set-server-ex

Description

Non-interactively connect to a remote gateway for gateway group administration.

Syntax

dxcli set-server-ex <target> <passkey>

Parameters

NameDescriptionTypeRequired
targetThe target gateway.StringTrue
passkeyThe passkey of the target gateway. The gateway group passkey must be set using dxcli gateway-group-set-secret or dxcli gateway-group-set-secret-ex.StringTrue

Example

dxcli set-server-ex 10.2.2.29 passkey

set-witness

Description

Sets the gateway group witness settings.

Syntax

dxcli set-witness <witness_path>[|username|password] [...]

Parameters

NameDescriptionTypeRequired
witness_pathThe UNC path of the network share or Azure Blob Storage connection string or SAS URL. Prefix with az: if using Azure Blob Storage connection string or SAS URL. Empty to remove current gateway group witness settings.StringTrue
usernameThe name of the user. Not specified for Azure Blob Storage Access Key or SAS URL.StringFalse
passwordThe password of the user (encrypted using dxcli encrypt-text recommended). Not specified for Azure Blob Storage Access Key or SAS URL.StringFalse
...Space-delimited set of parameters for multiple witness configurations.False

Example 1: Local Share

dxcli set-witness "\\server1\myshare1|user1|6pnFaDrRS+W/F+dkRuPKAA=="

Example 2: Cloud Share

dxcli set-witness "\\mystorage.file.core.windows.net\azshare1|mystorage|/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33=="

Example 3: Azure Blob Storage via Access Key

dxcli set-witness "az:DefaultEndpointsProtocol=https;AccountName=mystorage;AccountKey=/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33==;EndpointSuffix=core.windows.net"

Example 4: Azure Blob Storage via SAS URL

dxcli set-witness "az:https://mystorage.blob.core.windows.net/?sv=2020-02-10&ss=b&srt=o&sp=rwdlactfx&se=2021-06-09T13:15:48Z&st=2021-06-09T05:15:48Z&spr=https&sig=cRDqOc25lpHfbP8X1hlkDnV4H1wJycCyuuqlgu8U1xg%3D"

Example 5: Set Multiple Witnesses

dxcli set-witness "\\server1\myshare1|user1|6pnFaDrRS+W/F+dkRuPKAA==" "\\mystorage.file.core.windows.net\azshare1|mystorage|/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33==" "az:DefaultEndpointsProtocol=https;AccountName=mystorage;AccountKey=/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33==;EndpointSuffix=core.windows.net"

test-connection

Description

Tests the connection between the gateway and the gateway group.

Syntax

dxcli test-connection

Parameters

None

Example

dxcli test-connection

test-nat

Description

Determines the NAT type for the connected server.

Syntax

dxcli test-nat [-v]

Parameters

NameDescriptionTypeRequired
-vEnables verbose output.SwitchFalse

Example

dxcli test-nat -v

test-witness

Description

Tests the availability and authentication to the UNC network share(s).

LEGACY

This command has been superseded by dxcli test-witness-ex. Do not use this command for Azure Blob Storage.

Syntax

dxcli test-witness <share_path>[,...] <username> <password>

Parameters

NameDescriptionTypeRequired
share_pathThe UNC path of the network share.StringTrue
,...Comma-delimited list of additional UNC paths.False
usernameThe name of the userStringTrue
passwordThe password of the user (encrypted using dxcli encrypt-text recommended).StringTrue

Example 1: Local Share

dxcli test-witness "\\server1\myshare1" "user1" "6pnFaDrRS+W/F+dkRuPKAA=="

Example 2: Cloud Share

dxcli test-witness "\\mystorage.file.core.windows.net\azshare1" "mystorage" "/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33=="

test-witness-ex

Description

Tests the availability and authentication to the UNC network share(s) and/or Azure Blob Storage acess key or SAS URL. Prefix with az: if using Azure Blob Storage access key or SAS URL.

Syntax

dxcli test-witness-ex <witness_path>[|username|password] [...]

Parameters

NameDescriptionTypeRequired
witness_pathThe UNC path of the network share, Azure Blob Storage connection string, or SAS URL. Prefix with az: if using Azure Blob Storage connection string or SAS URL. Empty to remove current cluster witness settings.StringTrue
usernameThe name of the user. Not specified for Azure Blob Storage Access Key or SAS URL.StringFalse
passwordThe password of the user (encrypted using dxcli encrypt-text recommended). Not specified for Azure Blob Storage Access Key or SAS URL.StringFalse
...Space-delimited set of parameters for multiple witness configurations.False

Example 1: Local Share

dxcli test-witness-ex "\\server1\myshare1|user1|6pnFaDrRS+W/F+dkRuPKAA=="

Example 2: Cloud Share

dxcli test-witness-ex "\\mystorage.file.core.windows.net\azshare1|mystorage|/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33=="

Example 3: Azure Blob Storage via Access Key

dxcli test-witness-ex "az:DefaultEndpointsProtocol=https;AccountName=mystorage;AccountKey=/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33==;EndpointSuffix=core.windows.net"

Example 4: Azure Blob Storage via SAS URL

dxcli test-witness-ex "az:https://mystorage.blob.core.windows.net/?sv=2020-02-10&ss=b&srt=o&sp=rwdlactfx&se=2021-06-09T13:15:48Z&st=2021-06-09T05:15:48Z&spr=https&sig=cRDqOc25lpHfbP8X1hlkDnV4H1wJycCyuuqlgu8U1xg%3D"

Example 5: Test Multiple Witnesses

dxcli test-witness-ex "\\server1\myshare1|user1|6pnFaDrRS+W/F+dkRuPKAA==" "\\mystorage.file.core.windows.net\azshare1|mystorage|/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33==" "az:DefaultEndpointsProtocol=https;AccountName=mystorage;AccountKey=/nbFVz1fOKH7b0RaY/5Ms8uytbY99PZsspZkcHvNtVRj//pUk4jUPV7owaUSuDd6eExv96sBvkCXsleATEsT33==;EndpointSuffix=core.windows.net"

tunnel-group-start-gateway

Description

Starts hosting the tunnel group on the specified gateway.

Syntax

dxcli tunnel_group_start_gateway <tunel_group_name> <gateway_name>

Parameters

NameDescriptionTypeRequired
tunnel_group_nameThe name of the tunnel group.
StringTrue
gateway_nameThe name of the gateway.StringTrue

Example

dxcli tunnel-group-start-gateway tunnel_group1 gateway1

tunnel-group-stop-gateway

Description

Stops the specified tunnel group.

Syntax

dxcli tunnel-group-stop-gateway <tunnel_group_name> [gateway_name] [disabled]

Parameters

NameDescriptionTypeRequired
tunnel_group_nameThe name of the tunnel group.StringTrue
gateway_nameThe name of the gateway.StringFalse
disabledOption to also disable the gateway. Leaving this parameter blank will leave the gateway in its current state.SwitchFalse

Example

dxcli tunnel-group-stop-gateway tunnel_group1

tunnel-group-update-vips

Description

Changes the virtual IPs used by the tunnel group.

Syntax

dxcli tunnel-group-update-vips <tunnel_group_name> <virtual_ip>[,...]

Parameters

NameDescriptionTypeRequired
tunnel_group_nameThe name of the tunnel group.StringTrue
virtual_ipVirtual IP to update on the tunnel group.StringTrue
,...Comma-delimited list of additional virtual IPs to update on the tunnel group.False

Example

dxcli tunnel-group-update-vips tunnel_group1 10.2.2.29

update-addressfilter

Description

Updates an address filter to accept or deny connections from specific IP addresses or subnets.

Syntax

dxcli update-addressfilter <filter_name> <address>,<action>[|...] <default_action>

Parameters

NameDescriptionTypeRequired
filter_nameThe name of the filter.StringTrue
addressThe IP address or subnet.StringTrue
actionWhether or not to accept or deny the IP address or subnet. Must be accept or deny.StringTrue
|...Pipe-delimited list of additional address filters.False
default_actionSets the default action for the address filter to accept all or deny all connections outside of the specified IP or subnet from the previous parameter. Must be accept or deny.StringTrue

Example

dxcli update-addressfilter filter1 "10.1.1.0,accept|10.1.2.0,accept" deny

update-client

Description

Updates the specified client.

Syntax

dxcli update-client <client_name> <client_password> [client_description] [max_session_count]

Parameters

NameDescriptionTypeRequired
client_nameThe name of the client.StringTrue
client_passwordThe password of the client.StringTrue
client_descriptionThe description for the client.StringFalse
max_session_countThe number of active client sessions allowed.IntFalse

Example

dxcli update-client client1 p@ssw0rd 10 "Accounting Admins"

update-client-group

Description

Updates an existing client group.

Syntax

dxcli update-client-group <group_name> [modifier]<client_name>[,...] [group_description]

Parameters

NameDescriptionTypeRequired
group_nameThe name of the group.StringTrue
modifierSpecifies whether to add or remove a client from the group. Use a plus (+) to add clients and minus (-) before the client name to remove clients. If no sign is given, the default action adds the client.StringFalse
client_nameThe name of the client.StringTrue
,...Comma-delimited list of additional clients to add or remove from the client group.False
group_descriptionThe description for the group.StringFalse

Example

dxcli update-client-group group1 client1,-client2

update-tunnel

Description

Update an existing tunnel.

Syntax

dxcli update-tunnel <tunnel_name> <enabled> <destination_gateway_name> <target_address>:<target_port> <origin_gateway>,<origin_address>:<origin_port>[/address_filter][|...] [tunnel_group_name]

Parameters

NameDescriptionTypeRequired
tunnel_nameThe name of the tunnel.StringTrue
enabledEnable the tunnel.BoolTrue
destination_gateway_nameThe name of the destination gateway.StringTrue
target_addressThe target IP address or hostname of the tunnel destination.StringTrue
target_portThe port number for the target.IntTrue
origin_gatewayThe name of the origin gateway. This is the gateway where the tunnel listener will be active.StringTrue
origin_addressThe IP address the origin will bind to. Can be set to 0.0.0.0 to allow connections from any IP address with network access, or 127.0.0.1 to only allow connections from the gateway itself.StringTrue
origin_portThe port number for the origin address.IntTrue
address_filterThe name of the address filter to associate with the tunnel. See dxcli add-addressfilter for more information.StringFalse
|...Pipe-delimited list of additional origins.False
tunnel_group_nameThe name of the tunnel group.StringFalse

Example

dxcli update-tunnel tunnel1 true gateway1 10.1.200.62:30004 "gateway2,0.0.0.0:30004/FILTER1|gateway3,127.0.0.1:30004/FILTER2" TUNNEL_GROUP1

update-tunnel-clients

Description

Updates the clients associated with a tunnel.

Syntax

dxcli update-tunnel-clients <tunnel_name> [modifier]<name>:<ip_address>:<port>,[...]

Parameters

NameDescriptionTypeRequired
tunnel_nameThe name of the tunnel.StringTrue
modifierAdd (+) or remove (-) a client or client group from the tunnel. If no sign is given, the default action is add.StringFalse
nameThe name of the client or client group to add or remove from the tunnel.StringTrue
ip_addressThe IP address the client or client group uses to connect to the tunnel.StringTrue
portThe port the client or client group uses to connect to the tunnel.StringTrue
,...Comma-delimited list of additional clients to update for the tunnel.False

Example

dxcli update-tunnel-clients tunnel1 client1:127.0.0.1:30001,client2:127.0.0.1:40001,-client3:127.0.0.1:40001 clientgroup1:127.0.0.1:40001

update-tunnel-group

Description

Updates the gateway list for an existing tunnel group.

Syntax

dxcli update-tunnel-group <tunnel_group_name> <gateway_name>[,...]

Parameters

NameDescriptionTypeRequired
tunnel_group_nameThe name of the tunnel group.StringTrue
gateway_nameThe name of the gateway.StringTrue
,...Comma-delimited list of additional gateways.False

Example

dxcli update-tunnel-group tunnel_group1 "gateway1,gateway3,gateway2"