Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA Enterprise SCADA

Identify and resolve data inconsistencies

  • Last UpdatedApr 24, 2025
  • 4 minute read

The Datapump Synchronization (DPResync) utility can help identify and resolve issues with data replication. DPResync compares the tables in multiple systems to ensure they are the same. If there are discrepancies in the data, you can also use the utility to synchronize the data and correct the differences.

To identify and resolve inconsistencies

Use the following syntax to issue DPResync commands:

DPResync -S <source service> -D <destination service>

-b <begin date> [-e <end date>] [-y <level>][-j <level>]

[-f <datafile>] [-r <run time>] [-s <stop time>] [-T] [-h]

-S, -D, and -b are mandatory parameters. All other parameters are optional:

Parameter

Description

-S <source service>

The source system.

Use the following format for the system name: [system:[RDBMS:]][userid/passwd@]service

Typically only the service name is specified, such as, the RTDB server name. For a full description of the options, execute the DPutil -h command.

-D <destination service>

The destination system.

The destination is specified in the same format as the source where the destination database is located in the same domain; for example, <system>\oasyshdb.

If the destination is located in a different domain, the Data Access Layer (DAL) driver, alias, and Remote Client Service (RCS) being used must also be specified.

For example: main:MSDAL:Dir=sub\\remote_RCS_XFER;Alias=Historical_XFER

Where main is the DPSystem and sub is the destination system in the untrusted domain.

-b <begin date>

The starting time and date of the data collection period you want to investigate or resolve.

The date must be entered in Greenwich Mean Time (GMT) format or as a time string in the "mm/dd/yyyy hh:mm:ss" format.

-B

Run the command in the background.

By default, the command runs in the foreground.

-e <end date>

The end time and date of the data collection period you want to investigate or resolve.

The date must be entered in Greenwich Mean Time (GMT) format or as a time string in the "mm/dd/yyyy hh:mm:ss" format.

If you do not specify the -e parameter, the command will use data up to the most recent entry.

-y <level>

Defaults to -y1 If<level> =1. Check for differences in the keys between the source and the destination if <level>=2, but DPFill is called to resolve differences.
If <level>=3, Check for differences in all columns.

-j <level>

Perform an integrity update between the source and destination.

If <level>=0, do inserts only.
If <level> =1, do inserts and deletes.
If <level>=2, do inserts, updates, and deletes.
If <level>=3, do inserts, updates (if required) and deletes.

-f <datafile>

Name of file that describes the tables to synchronize.

-r <run time>

The time to start running the resynchronization. Valid values are between 0-59. For example, if your run time is 15 and your stop time is 20, the resynchronization will occur at 15-20 minutes after the top of hour (1:15-1:20, 2:15-2:20, etc.).

-s <stop time>

The time to stop running the resynchronization. Valid values are between 0-59. For example, if your run time is 15 and your stop time is 20, the resynchronization will occur at 15-20 minutes after the top of hour (1:15-1:20, 2:15-2:20, etc.).

-T

Run in test mode; do not actually execute against the source or destination.

-h

Display usage message that defines all the parameters for the DPResync commands.

Note: To prevent comparison and synchronization activities during times that may already have high system activity, DPResync halts processing at 5 minutes before the top of hour, and then continues processing again at 15 minutes past the top of hour.

The DPResync utility uses other utilities to perform the synchronization or comparisons in the background. A log file is produced to record the output of these utilities. Upon completion, the <DataDirectory>\log\datapump_resync.log file contains a record of the operations that were performed and their success or failure status. The last line in the log file is always Done.

The DPCreateResyncDatafile utility creates the data file used by DPResync. The data file that is created, includes information such as table names, whether the table contains a time field and, if so, how many seconds of data should be processed at a time, and whether the table is periodically cleaned up. The data file can be modified to add optional where clause information, for example, custodyType = shared. This information allows the DPResync utility to optimize comparison and synchronization activities while reducing interference with normal operations, for example, minimizing database locks. The syntax is:

DPCreateResyncDatafile -s <DPSystem> -S <source> -D <destination> [-f <filename>] [-o <order>] [-h] [-A <archSvrName>]

Note: The DPCreateResyncDataFile does not support cross-domain connections. You will need to generate the file for a local system and then modify it manually for your cross-domain configuration.

Where the parameters are:

Parameter

Description

-f <filename>

(Optional) The name of the resynchronization file to create. When not specified, the file is created in the directory: %DNADataRoot%\Historical\scripts\Datapump\DPResyncData_<SystemName>.txt.

-D <destination>

The destination Microsoft SQL Server connection; for example, backup\OASYSHDB.

-S <source>

The source Microsoft SQL Server connection; for example, main\OASYSHDB.

-s <DPSystem>

The name of the destination system configured in the Datapump table on the source system.

-o <order>

(Optional) If order = asc, order the file using priority ascending.
If order = desc, order priority descending. (desc is used by deletion scripts.)
The default is asc.

-A <archSvrName>

(Optional) The name of the server in the Archive Schedule table on the destination Microsoft SQL Server connection. The default value is Historical.

-h

(Optional) Display the usage message.

Examples

  • The following example is syntax of a command that creates a DPResync file.

    DPCreateResyncDatafile.csc -s backup -S main1\OASYSHDB -D backup1\OASYSHDB -f %DNADataRoot%\Historical\scripts\DPResyncData_main_to_backup.txt

  • The following example is syntax of a command that compares the keys on a source and destination system. The comparison is done by examining the keys on both systems.

    DPResync -S NYCXIS -D NECXIS -b 1012539600 -e 1012626000 -f DPResyncData_NYC_to_NEC.txt -y 1

    DPResync -S NYCXIS -D NECXIS -b "02/27/2002 00:00:00" -e "02/28/2002 00:00:00" -y 1

    DPResync -S NYCXIS -D NECXIS -b "Feb/27/2002 00:00:00" -e "now" -y 1

  • The following example is syntax of a command that would resynchronize the data on your system. It would start with data timestamped on May 24, 2016 and move backwards to data timestamped on May 17th.

    DPResync -f datapump_resync_filelist.txt -S TGLHIS1 -D TGLDSS1 -j 1 -b "05/24/2016 00:00:00" -e "05/17/2016 00:00:00"