Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
Help Center/ Server Migration Service/ FAQs/ Data Consistency/ How Do I Verify Data Consistency Between the Source and Target Servers?

How Do I Verify Data Consistency Between the Source and Target Servers?

Updated on 2025-01-24 GMT+08:00

SMS gives you the capability to verify data consistency before and after the migration. You can enable the verification option when you configure the target server or initiate an incremental synchronization.

Notes

  • Before enabling the verification option, you are advised to stop services (and databases if any) on the source server. If they are not stopped, data on the source server keeps changing, which will affect the consistency.
    NOTE:

    It is normal for some directories on the source and target servers to have slight differences. For instance, there are directories on the source server where data is always changing, such as the directory where SMS-Agent was installed and the /var/log directory where stores system logs.

  • The time required for consistency verification depends on the number and size of files to be verified. If consistency verification takes a long time during the final incremental synchronization, the time required for service cutover will also increase. Evaluate the impacts on your services.
  • Consistency verification occupies significant source disk I/O resources. Evaluate the potential impacts on your source services.
  • You can specify which paths should be included in the verification. If a parent and its child paths are included, only the parent path and its contents will be verified. The system will not re-verify the child paths.

    For example, if you specify the following paths for consistency verification:

    /path,/path/test

    The system will verify all contents of /path and will not verify /path/test separately.

Constraints

  • Consistency verification is not recommended when you choose to resize disks or partitions for the target server. Since paths between the source and target servers may not align perfectly, the verification results may be inaccurate.
  • It is not applicable to verification of cross-file system files or shared folders.
  • To prevent your services on the source server from being affected, a maximum of 1 million files can be verified in a single directory.
  • To prevent excessive memory usage, only paths that are shorter than 1024 bytes are verified.
  • Windows paths with non-ASCII characters (like Chinese or Japanese) cannot be verified and will be skipped during the process.

Enabling Data Consistency Verification When You Configure the Target Server

If you enable consistency verification when you configure the target server, data consistency will be verified after the full replication is complete. For details, see Configuring a Target Server.

Enabling Data Consistency Verification When You Initiate an Incremental Synchronization

  1. Open the Sync Incremental Data page by referring to Synchronizing Incremental Data.
  2. Select Verify Data consistency. This is a quick verification, and only the file size and modification time will be compared.

    Figure 1 Enabling data consistency verification
    Configure the verification policy based on the following table and your actual requirements.

    Parameter

    Description

    Enable Hash Verification

    If this option is enabled, the system will generate and compare hash values for each file to be verified. Hash verification is recommended when individual files are large and important. Enabling this option will increase CPU and disk I/O overheads for the source server and extend the verification time.

    CAUTION:
    • Hash values cannot be calculated for files in use, so these files will be skipped during the verification.
    • Enabling this option requires you to specify the verification scope, and only files in the specified scope will be verified.

    Verification Scope

    • Under Exclude paths, enter the paths you want to exclude from the verification. A maximum of 30 paths can be entered. Use commas (,) to separate the paths. For example, /root/data,/var. Leaving it empty will initiate a full verification.
    • Under Include paths, enter the paths you want to verify.
    NOTICE:
    • If the entered paths are incorrect or empty, 0 will be displayed for them in the verification results.
    • The more data you need to verify, the longer the consistency check will take. It is wise to focus on verifying only key paths.
    • The following paths will be excluded from consistency verification by default:
      • Linux: /bin, /boot, /dev, /home, /etc, /lib, /media, /proc, /sbin, /selinux, /sys, /usr, /var, /run, and /tmp
      • Windows: top-level directories of partitions, for example, C:\ and D:\

      If you want to verify some of the excluded paths, see Modifying the Default Excluded Paths.

    Verify Inconsistencies

    This option can only be enabled after at least one consistency verification is complete.

  3. Click OK to synchronize incremental data and verify consistency. After the synchronization and verification are complete, you can view the verification results by referring to Viewing Verification Results.

Modifying the Default Excluded Paths

  1. Log in to the source server.
  2. Open the g-property.cfg configuration file of the SMS-Agent.

    • Linux: .../SMS-Agent/agent/config/g-property.cfg
    • Windows: C:\SMS-Agent-Py*\config\g-property.cfg

  3. Modify the [consistency_check] configuration item to fit your requirements. Use commas (,) to separate paths and do not end with a comma. The following is an example:

    • Linux: list_dir_illegal_linux = /bin,/boot,/dev,/home,/etc,/lib,...
    • Windows: list_dir_illegal_windows = C:\SMS-Agent-Py3,C:\SMS-Agent-Py2,...

  4. Save the configuration file.

Skipping Consistency Verification

If you want to skip consistency verification after the incremental synchronization starts, perform the following steps:

  1. In the server list, click the server name. The task details show up on the right.
  2. On the Task Progress tab, locate the Verify data consistency subtask and click Skip Verification under the progress bar. In this displayed window, click OK.

    Figure 2 Skipping consistency verification
    NOTICE:

    Consistency verification can be skipped only when the progress is between 5% and 95%.

Viewing Verification Results

After the verification is complete, go to the task details page and click the Consistency Verification tab to view the verification results.
Figure 3 Viewing verification results

If 0 is displayed in the Files Verified column, it means the specified directory could not be found or is empty.

All files verified to be inconsistent are recorded in the log file sms_cmp_result.log in the SMS-Agent installation directory (*/SmsAgent/agent/Logs/ on Linux and C://SMS-Agent-Py*/Logs on Windows) on the source server.

Estimating Verification Time

The following table lists the verification time tested on servers where only the migration process runs but is for reference only.

OS

Specifications

Disk Performance

Verification Time (per 100 GB)

Windows

2 vCPUs and 4 GB of memory

5,000 IOPS/150 MB/s

About 17 minutes

Linux

2 vCPUs and 4 GB of memory

5,000 IOPS/150 MB/s

About 13 minutes

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback