YugaByte YugaByte
Enterprise
Open Source
Customers
Use Cases
Globally Distributed Applications Real-Time Streaming & Analytics Transactional NoSQL Planet-Scale SQL Distributed Transactional Key-Value DB
Resources
All Resources Docs Blog
Get Started
latest v1.0
  • Introduction
  • Quick Start
    • 1. Install YugaByte DB
    • 2. Create Local Cluster
    • 3. Test YCQL API
    • 4. Test YEDIS API
    • 5. Test YSQL API
    • 6. Run Sample Apps
  • Explore Core Features
    • Cloud Native
      • 1. Linear Scalability
      • 2. Fault Tolerance
      • 3. Observability
      • 4. Orchestration Readiness
    • Transactional
      • 1. ACID Transactions
      • 2. Secondary Indexes
      • 3. JSON Documents
    • High Performance
      • Tunable Reads
    • Planet Scale
      • 1. Global Distribution
      • 2. Auto Sharding
      • 3. Auto Rebalancing
    • PostgreSQL (Beta)
      • 1. Linear Scalability
      • 2. Fault Tolerance
      • 3. JOINs
      • 4. Aggregations
      • 5. Expressions
      • 6. Views
  • Develop
    • Tools
      • cqlsh
      • TablePlus
    • Client Drivers
      • C/C++
      • C#
      • Go
      • Java
      • NodeJS
      • Python
    • Learn App Dev
      • 1. SQL vs NoSQL
      • 2. Data Modeling
      • 3. Data Types
      • 4. ACID Transactions
      • 5. Aggregations
      • 6. Batch Operations
    • Ecosystem Integrations
      • Apache Kafka
      • Apache Spark
      • JanusGraph
      • KairosDB
      • Presto
      • Metabase
    • Real World Examples
      • E-Commerce App
      • IoT Fleet Management
      • Retail Analytics
  • Deploy
    • Checklist
    • Manual Deployment
      • 1. System Configuration
      • 2. Install Software
      • 3. Start YB-Masters
      • 4. Start YB-TServers
      • 5. Verify Deployment
    • Kubernetes
      • Helm Chart
      • Local SSD
    • Docker Swarm
    • Public Clouds
      • Amazon Web Services
      • Google Cloud Platform
      • Microsoft Azure
    • Pivotal Cloud Foundry
    • Enterprise Edition
      • 1. Initial Setup
      • 2. Install Admin Console
      • 3. Configure Admin Console
      • 4. Configure Cloud Providers
  • Secure
    • Security Checklist
    • Authentication
    • Authorization
      • 1. RBAC Model
      • 2. Create Roles
      • 3. Grant Permissions
    • TLS Encryption
      • 1. Prepare Nodes
      • 2. Server-server encryption
      • 3. Client-server encryption
      • 4. Connect to cluster
  • Manage
    • Backup and Restore
      • Backing Up Data
      • Restoring Data
    • Data Migration
      • Bulk Import
      • Bulk Export
    • Change Cluster Config
    • Upgrade Deployment
    • Diagnostics Reporting
    • Enterprise Edition
      • Create Universe - Multi-Zone
      • Create Universe - Multi-Region
      • Edit Universe
      • Edit Config Flags
      • Health Checking and Alerts
      • Node Status & Actions
      • Read Replicas
      • Backup & Restore
      • Upgrade Universe
      • Delete Universe
  • Troubleshoot
    • Troubleshooting Overview
    • Cluster Level Issues
      • YCQL Connection Issues
      • YEDIS Connection Issues
    • Node Level Issues
      • Check Processes
      • Inspect Logs
      • System Stats
    • Enterprise Edition
      • Troubleshoot Universes
  • Architecture
    • Basic Concepts
      • Single Node
      • Universe, Cluster, YB-TServer, YB-Master
      • Sharding
      • Replication
      • Persistence
      • Query Layer
      • Acknowledgements
    • Core Functions
      • Universe Creation
      • Table Creation
      • Write IO Path
      • Read IO Path
      • High Availability
    • Transactions
      • Isolation Levels
      • Single Row Transactions
      • Distributed Transactions
      • Transactional IO Path
  • Comparisons
    • Apache Cassandra
    • MongoDB
    • Redis In-Memory Store
    • FoundationDB
    • Amazon DynamoDB
    • Azure Cosmos DB
    • Google Cloud Spanner
    • Apache HBase
  • API Reference
    • YCQL
      • ALTER KEYSPACE
      • ALTER ROLE
      • ALTER TABLE
      • CREATE INDEX
      • CREATE KEYSPACE
      • CREATE ROLE
      • CREATE TABLE
      • CREATE TYPE
      • DROP INDEX
      • DROP KEYSPACE
      • DROP ROLE
      • DROP TABLE
      • DROP TYPE
      • GRANT PERMISSION
      • GRANT ROLE
      • REVOKE PERMISSION
      • REVOKE ROLE
      • USE
      • INSERT
      • SELECT
      • UPDATE
      • DELETE
      • TRANSACTION
      • TRUNCATE
      • Simple Value
      • Subscript
      • Function Call
      • Operator Call
      • BLOB
      • BOOLEAN
      • MAP, SET, LIST
      • FROZEN
      • INET
      • Integer & Counter
      • Non-Integer
      • TEXT
      • Date & Time Types
      • UUID & TIMEUUID
      • JSONB
      • Date & Time Functions
    • YEDIS
      • APPEND
      • AUTH
      • CONFIG
      • CREATEDB
      • DELETEDB
      • LISTDB
      • SELECT
      • DEL
      • ECHO
      • EXISTS
      • EXPIRE
      • EXPIREAT
      • FLUSHALL
      • FLUSHDB
      • GET
      • GETRANGE
      • GETSET
      • HDEL
      • HEXISTS
      • HGET
      • HGETALL
      • HINCRBY
      • HKEYS
      • HLEN
      • HMGET
      • HMSET
      • HSET
      • HSTRLEN
      • HVALS
      • INCR
      • INCRBY
      • KEYS
      • MONITOR
      • PEXPIRE
      • PEXPIREAT
      • PTTL
      • ROLE
      • SADD
      • SCARD
      • SET
      • SETRANGE
      • SISMEMBER
      • SMEMBERS
      • SREM
      • STRLEN
      • ZRANGE
      • TSADD
      • TSCARD
      • TSGET
      • TSLASTN
      • TSRANGEBYTIME
      • TSREM
      • TSREVRANGEBYTIME
      • TTL
      • ZADD
      • ZCARD
      • ZRANGEBYSCORE
      • ZREM
      • ZREVRANGE
      • PUBSUB
      • PUBLISH
      • SUBSCRIBE
      • UNSUBSCRIBE
      • PSUBSCRIBE
      • PUNSUBSCRIBE
    • YSQL (Beta)
      • DDL Statements
        • CREATE DATABASE
        • CREATE TABLE
        • CREATE VIEW
        • DROP DATABASE
        • DROP TABLE
      • DML Statements
        • INSERT
        • SELECT
      • Datatypes
        • FLOAT
        • INTEGER
        • TEXT
      • Transactions
      • Roles and Permissions
      • Prepared Statements
      • Explain Statement
  • Admin Reference
    • yb-ctl
    • yb-docker-ctl
    • docker-compose
    • yb-master
    • yb-tserver
  • FAQs
    • Product
    • Architecture
    • Enterprise Edition
    • Cassandra Compatibility
> Manage > Enterprise Edition >

Read Replicas Beta

    • Create the universe
    • Examine the universe
      • Universe nodes
    • Add, remove, edit a read replica cluster

This section will describe how to create a universe with both a primary and read replica cluster in a hybrid cloud deployment, as well as dynamically add, edit, and remove, a read replica cluster. In this example, we are first going to deploy a universe with primary cluster in Oregon (US-West) and read replica cluster in Northern Virginia (US-East).

Create the universe

First, we are going to enter the following values to create a primary cluster on GCP cloud provider. Click on Create Universe and enter the following intent.

  • Enter a universe name: helloworld3
  • Enter the set of regions: Oregon
  • Enter the replication factor: 3
  • Change instance type: n1-standard-8
  • Add the following GFlag for Master and T-Server: leader_failure_max_missed_heartbeat_periods = 10. Since the the data is globally replicated, RPC latencies are higher. We use this flag to increase the failure detection interval in such a higher RPC latency deployment.

Create Primary Cluster on GCP

Then, click on Configure Read Replica and enter the following intent to create a read replica cluster on AWS.

  • Enter the set of regions: US East
  • Enter the replication factor: 3
  • Change the instance type: c4.large

Create Read Replica Cluster on AWS

Since we do not need to a establish a quorum for read replica clusters, the replication factor can be either even or odd.Click Create.

Examine the universe

While waiting for the universe to get created, it should look like this:

Universe Waiting to Create

Once the universe is created, you should see something like this in the universe overview.

Universe Overview

Note how we have a distinguished primary and read replica cluster defined, designated by the yellow and green groups respectively.

Universe nodes

You can browse to the Nodes tab of the universe to see a list of nodes. Note that the nodes are grouped by primary or read replica, and read replica nodes have a readonly1 identifier associated with the name.

Read Replica Node Names

Go to the cloud providers’ instances page. In GCP, browse to Compute Engine->VM Instances and search for instances that have helloworld3 in their name. You should see something as follows, corresponding to our primary cluster.

Primary Cluster Instances

In AWS, browse to Instances and do the same search, you should see 3 nodes corresponding to our read replica cluster.

Read Replica Instances

We have successfully created a hybrid cloud deployment with the primary cluster in GCP and the read replica cluster in AWS!

Add, remove, edit a read replica cluster

In this section, we cover dynamically adding, editing, and removing a read replica cluster from an existing universe. Let’s create a new universe helloworld4 with a primary cluster exactly as helloworld3 but without any read replica cluster. Click Create and wait for the universe to be ready. Once this is done, navigate to the Overview tab, and find the More dropdown in the top right corner. There you should find a Configure Read Replica selection - click on that.

Configure Read Replica Dropdown

You will see a page to configure the read replica cluster. Enter the same intent we used for the read replica cluster in helloworld3 and click Add Read Replica.

Configure Read Replica Page

Once this is done, go to the Nodes tab and verify that you have 3 new read replica nodes all in AWS. To edit our read replica cluster, we go back to the More dropdown and select Configure Read Replica. Add a node to the cluster (it will automatically select a Availability Zone to select from) and click on Edit Read Replica.

Edit Read Replica

Once the universe is ready, go to the Nodes tab and you can see the new read replica node for a total of 4 new nodes.

Edit Read Replica Nodes

Finally, to delete the read replica cluster, go back to the Configure Read Replica page and click Delete this configuration. You will be prompted to enter the universe name for safety purposes. Do this and press Yes.

Delete Read Replica

Once this is done, go back to the Nodes page and verify that you only see the 3 primary nodes from our initial universe creation. You have dynamically added, edited, and removed a read replica cluster from an existing universe.

Manage
Node Status & Actions
Manage
Backup & Restore
Have a technical question?
Slack StackOverflow
Found a bug or have an enchancement request?
GitHub
    • Create the universe
    • Examine the universe
      • Universe nodes
    • Add, remove, edit a read replica cluster
YugaByte
Contact Us
Copyright © 2017-2019 YugaByte, Inc. All rights reserved.