检测到您已登录华为云国际站账号,为了您更好的体验,建议您访问国际站服务网站 https://www.huaweicloud.com/intl/zh-cn
不再显示此消息
Master/Standby, read/write splitting, and Redis Cluster instances Scaling out/in (replica quantity change) Before adding or removing replicas for a Redis Cluster instance, ensure that automated cluster topology refresh is enabled.
Metric ID Metric Name Description Value Range Monitored Object and Dimension Monitoring Period (Raw Data) bandwidth_usage Bandwidth Usage Percentage of the used bandwidth to the maximum bandwidth limit 0–200% Monitored object: Master/standby DCS Redis 4.0 or 5.0 instances Redis Server
Is the Read-only Address of a Master/Standby Instance Connected to the Master or Standby Node?
Master/Standby, read/write splitting, and cluster (except single-replica cluster) instances: Data persistence is supported by default. Read/Write splitting Read/Write splitting instances: Read/Write splitting is implemented on the server by default.
High availability is achieved by having a standby node take over in the event that a failure occurs on the master node.
Value range: master: master node slave: standby node. replication_ip String Parameter description: Replica IP address. Value range: N/A. is_replication Boolean Parameter description: Whether the replica is newly added.
Scenarios Where Redis Operations Fail Scenario Description Master/standby switchover triggered by a fault If the master node is faulty due to Redis underlying hardware or other reasons, a master/standby switchover is triggered to ensure that the instance is still available.
DCS Best Practices This section summarizes best practices of Distributed Cache Service (DCS) in common scenarios. Each practice is given a description and procedure.
Range: N/A node_type String Definition: Node type. Range: master: master node slave: standby node analysis_type String Definition: Analysis type.
For single-node, master/standby, and Redis Cluster instances, connections to Redis Server nodes are displayed. On the page, you can specify a Redis Server or proxy node to query, enter an address, update the query results, and set columns to display.
The following operations are based on an example of accessing a Redis instance on a client on an elastic cloud server (ECS). To access a Redis 3.0 instance over a public network, see Connecting to Redis 3.0 over a Public Network on redis-cli.
v2" "github.com/huaweicloud/huaweicloud-sdk-go-v3/services/dcs/v2/model" region "github.com/huaweicloud/huaweicloud-sdk-go-v3/services/dcs/v2/region" ) func main() { // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great security
failed_sum Integer Total number of failed diagnosis items. role String Node roles: master and slave. diagnosis_dimension_list Array of DiagnosisDimension objects Diagnosis dimension list. command_time_taken_list CommandTimeTakenList object Command execution duration list.
If they are in the same VPC, check the security group rules (for DCS Redis 3.0 instances) or whitelists (for DCS Redis 4.0 or 5.0 instances) to ensure that the IP addresses and ports of the Redis instances are accessible.
When the cluster topology changes (for example after a master/standby switchover or scaling), new nodes cannot be identified, causing service failures.
Keys to Iterate set to 100: The scanning takes 12.5 minutes (15 million/20,000/60 seconds) and the CPU usage is about 20%. Keys to Iterate set to 1000: The scanning takes 1.25 minutes (15 million/200,000/60 seconds) and the CPU usage is about 25%.
Options: read (read-only) and write (read/write). account_read_policy No String Definition: Read requests are routed to master or replica nodes.
Import the RDB file (or files) to the cloud server. The cloud server must be connected to the target DCS instance.
When creating a node pool, set Node Type to Elastic Cloud Server (VM), Container Engine to Docker, OS to CentOS 7.6, and bind an existing EIP or create one. Procedure Creating a Client Image Download a Redis client. Log in to the CCE cluster node.
When you set Scope to Region-specific projects and select the specified projects (for example, ap-southeast-2) in the specified regions (for example, AP-Bangkok), the users only have permissions for DCS instances in the selected projects.