Updated on 2024-06-20 GMT+08:00

Step 1: Check Whether Public Access Is Supported

You can access a DCS Redis 3.0 instance over public networks. In comparison with intra-VPC access, public access may bring packet loss, jitter, and higher latency. Therefore, you are advised to enable public access only during the service development and testing phases.

Before connecting to a DCS instance over public networks, check whether the instance supports public access.

  • Redis 3.0

    Currently, only DCS Redis 3.0 instances support public access. You can enable or disable public access.

  • Redis 4.0/5.0/6.0

    Public access is not supported by DCS Redis 4.0/5.0/6.0 instances. If public access is required for a single-node, master/standby, or Proxy Cluster instance, use Nginx to redirect connections through an ECS configured with the same VPC and security group as the DCS instance. For details, see Using Nginx for Public Access to Single-node, Master/Standby, or Proxy Cluster DCS Redis Instances.

    Redis Cluster instances cannot be accessed over public networks.

  • Memcached

    Public access is not supported by DCS Memcached instances. The ECS that serves as a client and the DCS instance that the client will access must belong to the same VPC. In the application development and debugging phase, you can also use an SSH agent to access DCS Memcached instances in the local environment.

Procedure

On the Basic Information page of the instance, check the following parameter settings:

  • Cache Engine: Must be Redis 3.0. If not, public network access is not supported.
  • Password Protected: Must be Yes. If not, enable password protection for the instance by referring to FAQs.
  • Public Access: Must be On. If not, enable public access by referring to Step 2: Enable Public Access for a DCS Redis Instance.
Figure 1 Checking the cache engine version, password protection, and public access

FAQs

  • What can I do if the public access button is grayed out when the instance is not password-protected?

    In the upper right corner of the Basic Information page, choose More > Reset Password. After the password is reset, the Password Protected parameter changes to Yes. The public access button can be clicked now.

  • How do I disable SSL encryption when public access has been enabled?

    SSL encryption is enabled by default when you enable public access. To disable SSL encryption, perform the following steps:

    1. Open the page for configuring public access.

    2. Disable SSL encryption, and click OK.

    3. In the Connection area on the instance details page, SSL is disabled.