Connect to a KCS instance

Last updated:2021-06-08 16:02:16

By default, you can access a KCS instance only by using its private IP address over the internal network. To access a KCS instance from the Internet, you must apply for a public IP address for the instance on the instance details page. For more information, see Enable public access.

This topic describes how to connect to a KCS instance from a Kingsoft Cloud Elastic Compute (KEC) instance on which Ubuntu or CentOS is installed.

Usage notes

  • Before you connect to a KCS instance from a KEC instance, you must add the private or public IP address of the KEC instance to a security group of the KCS instance. Otherwise, the connection fails. For more information, see Use security groups.
  • If you have enabled password-free access for the KCS instance, you do not need to provide a password when you connect to the KCS instance.
  • The KEC instance must be in the same VPC as the KCS instance. Otherwise, the connection fails.


  1. Log in to the KCS console. Obtain the IP address of the KCS instance to which you want to connect.


  1. Log in to the KEC instance. Download and install Redis by using one of the following methods:

Method 1: Download and install Redis from the Redis official website.

Method 2: Install Redis on the command line.

  • Ubuntu
sudo apt install redis-tools

Command line tool.png

  • CentOS
yum install redis -y

Redis is installed when the message “Complete!” appears.

  1. On the KEC instance, connect to the KCS instance by using redis-cli.
redis-cli -h Instance IP address -a Password

redis cli.png

Did you find the above information helpful?

Mostly Unhelpful
A little helpful
Very helpful

What might be the problems?

Unclear or awkward
Redundant or clumsy
Lack of context for the complex system or functionality

More suggestions


Please give us your feedback.


Thank you for your feedback.