First use of PolarDB

1 Introduction

PolarDB is a next-generation relational cloud database developed by Alibaba Cloud. It has three independent engines, which are 100% compatible with MySQL, 100% compatible with PostgreSQL, and highly compatible with Oracle syntax. PolarDB not only integrates the stable, reliable, high-performance, and scalable characteristics of commercial databases, but also has the advantages of simple, open, and self-iterative open source cloud databases. For example, PolarDB MySQL can be up to 6 times higher than MySQL in performance, while the cost is only 1% of commercial databases. /10.
Insert picture description here
Features :

  • Compatibility: It can be 100% compatible with MySQL, 100% compatible with PostgreSQL, and highly compatible with Oracle syntax. The storage capacity can be up to 100TB, and a single database can be expanded to up to 16 nodes. It is suitable for diverse database application scenarios in enterprises.
  • Storage and computing separation architecture: All computing nodes share a piece of data, providing minute-level configuration upgrades, second-level failure recovery, global data consistency, and free data backup and disaster recovery services.
  • Multi-node cluster architecture: There is a Writer node (master node) and multiple Reader nodes (read nodes) in the cluster, and each node shares the underlying storage (PolarStore) through the distributed file system (PolarFileSystem).
  • Read and write separation: When the application uses the cluster address, PolarDB MySQL/PostgreSQL provides services to the outside through the internal proxy layer (Proxy), and the requests of the application go through the proxy before accessing the database node. The proxy layer can not only perform security authentication and protection, but also parse SQL, send write operations (such as transactions, UPDATE, INSERT, DELETE, DDL, etc.) to the master node, and distribute read operations (such as SELECT) to multiple clients in a balanced manner. The read node realizes automatic read-write separation. For applications, it is as simple as using a single-point MySQL database. The internal proxy layer (Proxy) will support PolarDB to be compatible with the Oracle syntax engine in the future.
  • POLARDB provides two database addresses by default, one is the cluster address (Cluster) and the other is the primary address (Primary). It is recommended to use the cluster address because it has the function of reading and writing separation, which can integrate the resources of all nodes together to provide services to the outside world. . The primary address always points to the primary node, and the SQL to access the primary address is sent to the primary node. When the primary-standby switchover (Failover) occurs, the primary address will automatically drift to the new primary node within 30 seconds to ensure the application The master node that is always connected is writable and readable.

2 Connect to PolarDB

  • 1) Configure the public network address.
    As shown in the figure, click according to the serial number to enter the cluster information page.
    Insert picture description here
    Insert picture description here
    As shown in the figure, if you want to use a third-party tool, such as Navicat, to connect to the database through code, you need to locate the public network address. Click "Apply" in the red box in the figure to set the public network address of a node.

  • 2) Create a user who logs in to the database.
    Also on the cluster information page, click "Account Management", as shown in the figure. Just click Create account, you can choose to create a high-privilege account and a normal account.
    Insert picture description here

  • 3) Use a third party to log in to the database
    For example, use Navicat to log in, as shown in the figure, fill in the public network address configured in 1) for the host name or IP address, and fill in the username and password applied for in 2) for the user name and password.
    Insert picture description here

Welcome to my personal blog ~~~

Guess you like

Origin blog.csdn.net/Miha_Singh/article/details/108226402