All Products
Search
Document Center

Virtual Private Cloud:GetVpnGatewayDiagnoseResult

Last Updated:Nov 13, 2024

Queries the diagnostic result of a VPN gateway.

Operation description

When you call the GetVpnGatewayDiagnoseResult operation, you must specify one of DiagnoseId and VpnGatewayId.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The region ID of the VPN gateway.

You can call the DescribeRegions operation to query the most recent region list.

cn-qingdao
DiagnoseIdstringNo

The ID of the diagnostic operation.

When you call the DiagnoseVpnGateway operation, the system returns a corresponding ID.

vpndgn-uf6kuxbe3iv028k3s****
VpnGatewayIdstringNo

The ID of the VPN gateway.

vpn-uf6fzwp0ck3frwtbk****
ClientTokenstringNo

The client token that is used to ensure the idempotence of the request.

You can use the client to generate the token, but you must make sure that the token is unique among different requests. The client token can contain only ASCII characters.

**

Description If you do not specify this parameter, the system automatically uses the request ID as the client token. The request ID may be different for each request.

02fb3da4-130e-11e9-8e44-001****

Response parameters

ParameterTypeDescriptionExample
object

The returned data.

BeginTimestring

The time when the diagnostic started.

The time follows the ISO8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

2022-12-15T05:28:57Z
DiagnoseIdstring

The ID of the diagnostic.

vpndgn-uf6sgneym02lxyuv4****
DiagnoseResultarray<object>

The information about the diagnostic items.

DiagnoseResultobject
DiagnoseNamestring

The diagnostic item.

  • RouteEntryConflict: route conflicts.
  • VpnRouteQuota: the quota of destination-based routes for the VPN gateway.
  • VpnIPsecQuota: the quota of IPsec-VPN connections for the VPN gateway.
  • VpnPbrRouteQuota: the quota of policy-based routes for the VPN gateway.
  • VcoConfigConsistency: the consistency of the IPsec-VPN connection.
  • VcoUserInternetIpConnectivity: Internet connectivity of the customer gateway.
  • VcoPrivateConnectivity: private network connectivity.

For more information about the diagnostic items, see Background information about quick diagnostics.

RouteEntryConflict
DiagnoseResultDescriptionstring

The diagnostic result.

The system returns different results for each diagnostic item.

  • RouteEntryConflict: information about route conflicts.

  • VpnRouteQuota:

    • quotaName: the quota ID of destination-based routes.
    • quantity: the quota of destination-based routes for the VPN gateway.
    • used: the number of destination-based routes created for the VPN gateway.
  • VpnIPsecQuota:

    • quotaName: the quota ID of IPsec-VPN connections.
    • quantity: the quota of IPsec-VPN connections for the VPN gateway.
    • used: the number of IPsec-VPN connections created for the VPN gateway.
  • VpnPbrRouteQuota:

    • quotaName: the quota ID of policy-based routes.
    • quantity: the quota of policy-based routes for the VPN gateway.
    • used: the number of policy-based routes created for the VPN gateway.
  • VcoConfigConsistency:

    • vcoLackConf: The system cannot obtain the configuration of the peer of the IPsec-VPN connection.
    • vcoRunningConf: the configurations that have been added to the peer of the IPsec-VPN connection.
    • vcoDiffConf: the configurations that are inconsistent between the local end and the peer.
    • vcoConf: the configurations that have been added to the local end.
  • VcoUserInternetIpConnectivity:

    • targetIp: the public IP address of the customer gateway.
    • rtt: the latency when the system accesses the public IP address of the customer gateway. Unit: milliseconds.
    • lossRate: the packet loss when the system accesses the public IP address of the customer gateway.
  • VcoPrivateConnectivity:

    • targetIp: the source IP address.
    • srcIp: the destination IP address.
    • rtt: the latency when the source IP address accesses the destination IP address. Unit: milliseconds.
    • lossRate: the packet loss when the source IP address accesses the destination IP address.
{\"targetIp\":\"192.168.0.1\",\"srcIp\":\"192.168.1.1\",\"rtt\":-1.0,\"lossRate\":100.0}
DiagnoseResultLevelstring

The diagnostic result level.

  • normal
  • warning
  • error

For more information, see Background information about quick diagnostics.

normal
FinishTimestring

The timestamp when the system finishes diagnosing the item.

The time follows the ISO8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

2022-12-15T05:29:08Z
FinishedCountinteger

The number of diagnostic items that have been diagnosed.

7
RequestIdstring

The request ID.

312C4D5A-6563-5FC6-8C6E-A43A5A316FEB
ResourceInstanceIdstring

The ID of the resource that is diagnosed.

vco-uf6huqsu63azl7mdp****
ResourceTypestring

The type of the resource.

The value is set to IPsec, which indicates an IPsec-VPN connection.

IPsec
TotalCountinteger

The total number of diagnostic items.

7
VpnGatewayIdstring

The ID of the VPN gateway.

vpn-uf6fzwp0ck3frwtbk****

Examples

Sample success responses

JSONformat

{
  "BeginTime": "2022-12-15T05:28:57Z",
  "DiagnoseId": "vpndgn-uf6sgneym02lxyuv4****",
  "DiagnoseResult": [
    {
      "DiagnoseName": "RouteEntryConflict",
      "DiagnoseResultDescription": "{\\\"targetIp\\\":\\\"192.168.0.1\\\",\\\"srcIp\\\":\\\"192.168.1.1\\\",\\\"rtt\\\":-1.0,\\\"lossRate\\\":100.0}",
      "DiagnoseResultLevel": "normal"
    }
  ],
  "FinishTime": "2022-12-15T05:29:08Z",
  "FinishedCount": 7,
  "RequestId": "312C4D5A-6563-5FC6-8C6E-A43A5A316FEB",
  "ResourceInstanceId": "vco-uf6huqsu63azl7mdp****",
  "ResourceType": "IPsec",
  "TotalCount": 7,
  "VpnGatewayId": "vpn-uf6fzwp0ck3frwtbk****"
}

Error codes

HTTP status codeError codeError messageDescription
400param_errorThe param is must be in ...-
400MissingParam.DiagnoseInfoThe VPN gateway ID and diagnose ID cannot be empty at the same time.-
400VpnGateway.ConfiguringThe specified service is configuring.The service is being configured. Try again later.
400IncorrectStatus.DiagnoseTimeoutDiagnose failed because of timeout.-
400IncorrectStatus.VpnConnectionDeletedDiagnose failed because the VPN connection has been deleted.-
403ForbiddenUser not authorized to operate on the specified resource.You do not have the permissions to manage the specified resource. Apply for the permissions and try again.
404InvalidDiagnoseId.NotFoundThe specified diagnose ID [%s] does not exist.-
404InvalidVpnGatewayId.NotFoundThe specified VPN gateway [%s] does not have any diagnoses.-
404InvalidVpnGatewayInstanceId.NotFoundThe specified vpn gateway instance id does not exist.The specified VPN gateway does not exist. Check whether the specified VPN gateway is valid.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history