tencent cloud

TencentDB for PostgreSQL

Release Notes and Announcements
Release Notes
Product Announcements
Product Introduction
Overview
Features
Strengths
Scenarios
Information Security
Regions and AZs
Product Feature List
Large version lifecycle description
MSSQL Compatible Version
Billing
Billing Overview
Instance Type and Specification
Purchase Methods
Refund
Overdue Payments
Backup Space Billing
Database Audit Billing Overview
Getting Started
Creating TencentDB for PostgreSQL Instance
Connecting to TencentDB for PostgreSQL Instance
Managing TencentDB for PostgreSQL Instance
Importing Data
Migrating Data with DTS
Kernel Version Introduction
Kernel Version Overview
Kernel Version Release Notes
Viewing Kernel Version
Proprietary Kernel Features
Database Audit
Audit Service Description
Activating Audit Service
View Audit Logs
Modify audit services
Audit Performance Description
User Guide
Instance Management
Upgrading Instance
CPU Elastic Scaling
Read-Only Instance
Account Management
Database Management
Parameter Management
Log Management and Analysis
Backup and Restoration
Data Migration
Extension Management
Network Management
Access Management
Data Security
Tenant and Resource Isolation
Security Groups
Monitoring and Alarms
Tag
AI Practice
Using the Tencentdb_ai Plug-In to Call Large Models
Building Ai Applications with the Tencentdb Ai Plug-In
Combining Supabase to Quickly Build Backend Service Based on TencentDB for PostgreSQL
Use Cases
postgres_fdw Extension for Cross-database Access
Automatically Creating Partition in PostgreSQL
Searching in High Numbers of Tags Based on pg_roaringbitmap
Querying People Nearby with One SQL Statement
Configuring TencentDB for PostgreSQL as GitLab's External Data Source
Supporting Tiered Storage Based on cos_fdw Extension
Implement Read/Write Separation via pgpool
Implementing Slow SQL Analysis Using the Auto_explain Plugin
Using pglogical for Logical Replication
Using Debezium to Collect PostgreSQL Data
Set Up a Remote Disaster Recovery Environment for PostgreSQL Locally on CVM
Read-Only Instance and Read-Only Group Practical Tutorial
How to Use SCF for Scheduled Database Operations
Fix Table Bloat
Performance White Paper
Test Methods
Test Results
API Documentation
History
Introduction
API Category
Making API Requests
Instance APIs
Read-Only Instance APIs
Backup and Recovery APIs
Parameter Management APIs
Security Group APIs
Performance Optimization APIs
Account APIs
Specification APIs
Network APIs
Data Types
Error Codes
FAQs
Service Agreement
Service Level Agreement
Terms of Service
Glossary
Contact Us

Incremental Migration Pre-Check

PDF
Modo Foco
Tamanho da Fonte
Última atualização: 2025-04-30 17:57:57

Check Detail

When the migration type is set to incremental migration, you need to check the following conditions. Otherwise, verification will fail.
The wal_level of the source database must be logical.
The parameters max_replication_slots and max_wal_senders of the source database must be greater than the total number of libraries to be migrated (reserved additional number of connections).
The persistence attribute of tables to be migrated in the source database must be p (permanent table). Otherwise, replication is not supported, and logical migration cannot be done.
unlogged tables cannot exist in tables to be migrated. Otherwise, they cannot be migrated.
Migrate tables with a primary key. Otherwise, inconsistent data results may occur. It is not recommended that users migrate tables without a primary key.
If the table to be migrated has no primary key and no copyable flag (i.e., the REPLICA IDENTITY attribute is set to NOTHING), the validation task will raise an alarm.
If the table to be migrated has no primary key and contains field types (json/point/polygon/txid_snapshot/xml) that cannot use the = operator, the verification will fail. You need to repair the table without a primary key according to the prompt or uncheck the primary key table. Otherwise, you cannot continue the task.

Remediation Method

Modifying wal_level/max_replication_slots/max_wal_senders Parameters

Follow these steps to modify parameters wal_level, max_replication_slots, and max_wal_senders.
1. Log in to the source database.
Note:
If the source database is a self-built database, you need to log in to the running server of the database and enter the main data directory of the database, which is generally $PGDATA.
If the source database is another CloudDB, please use the parameter modification method of the relevant cloud platform.
If modifications are needed for the parameters of the target instance, please handle it through online support.
2. Normally enter the postgresql.conf file, open this file, and modify the corresponding parameter.
wal_level = logical
max_replication_slots = 10 //Change according to actual conditions
max_wal_senders = 10 //Change according to actual conditions
3. After modification, restart the database instance.
4. Log in to the database instance and use the following command to check whether the parameter values are set correctly:
postgres=> select name,setting from pg_settings where name='wal_level';
name | setting
-----------+---------
wal_level | logical
(1 row)
postgres=> select name,setting from pg_settings where name='max_replication_slots';
name | setting
-----------------------+---------
max_replication_slots | 10
(1 row)
postgres=> select name,setting from pg_settings where name='max_wal_senders';
name | setting
-----------------+---------
max_wal_senders | 10
(1 row)
5. Re-run the verification task.

Modifying REPLICA IDENTITY Attribute of Table to Be Migrated

Generally, it is not recommended to migrate tables without a primary key, which may result in inconsistent data. If the table to be migrated has no primary key and does not contain a copyable identification (i.e., the REPLICA IDENTITY attribute is set to NOTHING), the validation task will raise an alarm.
A warning has occurred. It is recommended that users refer to the following method to modify the attribute parameters of the table.
ALTER TABLE schemaName.tableName REPLICA IDENTITY FULL;


Ajuda e Suporte

Esta página foi útil?

comentários