All Products
Search
Document Center

ApsaraDB for Redis:Perform diagnostics on connections

Last Updated:Apr 07, 2024

If your client cannot connect to an instance, you can use the Connection Diagnostics feature to check the IP address of the client and configure the relevant settings.

Procedure

  1. Log on to the ApsaraDB for Redis console and go to the Instances page. In the top navigation bar, select the region in which the instance that you want to manage resides. Then, find the instance and click the instance ID.

  2. In the Connection Information section, click Connection Diagnostics.

  3. In the Connection Diagnostics panel, specify your client IP address. The following table describes the related scenarios and instructions.

    Scenario

    Instruction

    • The client is an Elastic Compute Service (ECS) instance that resides within the same region as the ApsaraDB for Redis instance.

    The client can connect to the instance over the Internet or the virtual private cloud (VPC) in which the ECS instance is deployed.

    1. Set Client Type to ECS Instance.

    2. Select the ID of the ECS instance.

      • If the ECS instance ID is displayed in green, the ECS instance is deployed in the same VPC as the ApsaraDB for Redis instance. In this case, you can connect to the instance over the VPC or the Internet.

      • If the ECS instance ID is displayed in red, the ECS instance is not deployed in the same VPC as the ApsaraDB for Redis instance. In this case, you can connect to the instance only over the Internet.

    3. Select the endpoint of the ECS instance used to connect to the Tair instance.

    • The client is an on-premises device.

    • The client is an ECS instance that resides in a different region from the ApsaraDB for Redis instance.

    The client can connect to the instance only over the Internet.

    1. Set Client Type to IP address.

    2. Specify the client IP address.

  4. Click Start Diagnostics.

  5. View diagnostic results

    • Check failed: The client IP address has not been added to a whitelist of the ApsaraDB for Redis instance. You can click Add to add the IP address to the default whitelist of the ApsaraDB for Redis instance. Then, start diagnostics again.

      Note

      You can also click Whitelist Settings to manually add the IP address to a whitelist of the instance on the Whitelist Settings page.

    • Check passed: The IP address has been added to a whitelist of the ApsaraDB for Redis instance.

What to do next

After diagnostics are complete, use the passed IP address to connect to the ApsaraDB for Redis instance from the client. For more information, see the following topics:

References

The connection diagnostics feature checks only whether the client IP address is added to a whitelist of your ApsaraDB for Redis instance. If the client still fails to connect to the ApsaraDB for Redis instance after the IP address passes the check, one of the following issues may occur:

  • Network exception: Run the PING command to check the network connection between the client and your Tair instance. If the network connection is abnormal, check the client network environment.

  • Dynamic IP address: If your client has a dynamic IP address on the Internet, the connection fails. In this case, you can configure a static IP address for your client or add 0.0.0.0/0 to a whitelist of the instance to allow access from all IP addresses.

  • Incorrect password: Check the password of your ApsaraDB for Redis instance. For more information, see Logon methods.