Creating a Schema
Prerequisites
- You have logged in to the DDM console.
- The DDM instance is in the Running state.
- Do not modify or delete the internal accounts (DDMRW*, DDMR*, and DDMREP*) created on data nodes. Otherwise, services will be affected.
- The internal account name is in the format: Fixed prefix (such as DDMRW, DDMR, or DDMREP) + Hash value of the data node ID.
- A random password is generated, which contains 16 to 32 characters.
- All DB instances associated with one schema must have the same major MySQL version.
- Multiple schemas can be created in a DDM instance and associated with the same data node. One DDM instance can be associated with either RDS for MySQL or GaussDB(for MySQL) instances, but not both.
- One data node cannot be associated with schemas in different DDM instances.
- If you select Sharded for Sharding when you create a schema, the shard name follows the rule: schema+xxxx. xxxx indicates the digit increased from 0000. For example, if a schema name is db_cbb5 and the total number of shards is 2, the shard names are db_cbb5_0000 and db_cbb5_0001.
You can create a schema in two ways: on the Instances page or on the Schemas page. This section uses the Instances page as an example to describe how to create a schema.
Procedure
- In the navigation pane, choose Instances. In the instance list, locate the DDM instance that you want to create a schema for and click Create Schema in the Operation column.
- On the displayed page, specify a sharding mode, enter a schema name, set the number of shards, select the required DDM accounts, and click Next.
- Enter the database password and click Test Connection.
- After the test becomes successful, click Finish.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.