All Products
Search
Document Center

Tair:Use a public endpoint to connect to a Tair instance

Last Updated:Sep 05, 2023

If you want to test or manage a Tair instance on your on-premises device, you can apply for a public endpoint for the instance and connect to the instance over the Internet.

Usage notes

  • You are not charged for traffic fees when you connect to your Tair instance over the Internet. However, this increases network latency, compromises service performance, and results in security risks. We recommend that you connect to Tair instances by using Virtual Private Cloud (VPC) for lower network latency and higher security.

    Note

    The Service Level Agreement (SLA) does not apply to client exceptions caused by the Internet conditions.

  • Public endpoints are not supported for Tair cluster instances in direct connection mode that use the cloud-native deployment mode. You can connect to these instances over a VPC.

Procedure

  1. Obtain the public IP address of your on-premises device.

    The method used to obtain the public IP address of an on-premises device may vary based on your network environment or operation. The following list provides reference methods for obtaining the public IP address of an on-premises device by using commands in different operating systems:
    • Linux: Open the CLI, enter the curl ifconfig.me command, and then press Enter.
    • Windows: Open Command Prompt, enter the curl ip.me command, and then press Enter.
    • macOS: Open the CLI, enter the curl ifconfig.me command, and then press Enter.
  2. Add the public IP address of your on-premises device to a whitelist of the Tair instance. For more information, see Configure whitelists.

    Note

    If your on-premises device uses dynamic IP addresses, you can add the CIDR block to a whitelist of the Tair instance to prevent access failures caused by IP address changes. This may compromise the security of the instance. Proceed with caution.

  3. Apply for a public endpoint for the Tair instance. For more information, see Apply for a public endpoint for a Tair instance.

  4. Use the redis-cli tool or a client program to connect to the Tair instance based on the obtained public endpoint.

    Note

    When you use a public endpoint to connect to your instance, you must specify the database account and the corresponding password. For more information, see Connect to a Tair instance.