Help Center/
Data Replication Service/
User Guide (Kuala Lumpur Region)/
Real-Time Migration/
To the Cloud/
PostgreSQL->PostgreSQL
Updated on 2022-08-16 GMT+08:00
PostgreSQL->PostgreSQL
Operation Constraints
DRS has the following constraints on common operations in the case of migration failures caused by unpredictable errors or sudden environment changes.
Type |
Constraint |
---|---|
Notes |
|
Precautions |
|
Environment Constraints
- Ensure that the environment configuration meets the following constraints. DRS automatically checks the following items and provides handling suggestions.
Table 2 Environment constraints Type
Constraint
Database permissions
- Full migration (minimum permissions):
- The source database user must have the CONNECT permission for databases, the USAGE permission for schemas, the SELECT permission for tables, the SELECT and USAGE permissions for sequences, and the UPDATE, DELETE, and TRUNCATE permissions for tables without primary keys (only for locking tables without primary keys for a short period of time).
- During a database-level migration, the destination database account must have the CREATEDB permission.
- During table-level migration, if the database does not exist, the destination database account must have the CREATEDB permission. If the database exists, the destination database account must have the CREATE and CONNECT permissions. If a schema exists, the CREATE and USAGE permissions are required.
Migration objects
- Supported objects: tables, indexes, foreign keys, stored procedures, functions, views, constraints, triggers, modes, sorting rules, code conversion information, data types, aggregate functions, operators, sequences, materialized views, statistical extensions, rules, event triggers, type conversion, conversion information, text search parsers, text search dictionaries, text search template, and text search configurations.
- Supports the following field types: digit, currency, character, binary, date/time, Boolean, enumeration, geometry, network address, bit, text search, UUID, XML, JSON, array, compound, and range.
- Plugins cannot be migrated. If the source contains plugins other than plpgsql, install the plugins in the destination in advance. The version of the plugins in the destination must be the same or newer than those in the source. If you can relocate the plugin to a schema in the destination database, specify the schema the same as that in the source database.
- Temporary tables in the source database cannot be migrated.
- Data cannot be migrated from the database of a later major version to the database of an earlier major version.
- System schemas that are not migrated include: schemas starting with pg_ and information_schema. For RDS PostgreSQL Enhanced Edition, the following schemas are not migrated: sys, utl_raw, dbms_lob, dbms_output, and dbms_random.
Source database
- The source database name cannot contain the following characters: + % "\ '>< . The schema name and table name cannot contain double quotation marks (") and periods (.).
- The trigger name in the source database must be unique.
- The block_size value of the source database cannot be greater than that of the destination database.
- The source database version cannot be earlier than PostgreSQL 9.4.
- If the source database type is RDS PostgreSQL Enhanced Edition, the destination database type must be the same.
- To ensure the security of the source database connection, set the ssl parameter of the source database to on and ensure that the source database uses the password authentication mode. To change the authentication mode, add host all <src_user_name> <drs_instance_ip>/32 md5 to the first line of all configurations in the pg_hba.conf file of the source database, and then run the select pg_reload_conf(); statement as the superuser in the source database or restart the DB instance for the change to take effect.
Destination database
- The destination database version cannot be older than the source database version.
- The destination DB instance is running properly.
- During a database-level migration, if the source does not contain plugins other than plpgsql, the destination cannot contain databases with the same name as the source databases to be migrated. If a plugin other than plpgsql is installed in the source database, ensure that only the plugin is installed in the destination database and no other self-built objects are created.
- During a table-level migration, the destination database cannot contain objects with the same names as the objects to be migrated in the source database.
- The destination DB instance must have sufficient storage space.
- The lc_monetary values of the source and destination databases must be the same.
- The block_size value of the destination database must be greater than that of the source database.
- Full migration (minimum permissions):
Parent topic: To the Cloud
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
The system is busy. Please try again later.
For any further questions, feel free to contact us through the chatbot.
Chatbot