当前位置: 首页 > DDS > 正文

DDS数据对比测试

DDS数据对比测试,DDS数据对比测试是基本行的数据对比

 

1,修改目标端对比进程个数

[dds@www.htz.pw data]$cat ddstart

#!/bin/sh

 

if [ "${NLS_LANG}NONE" = "NONE" ]

then

    echo "Error: NLS_LANG is not set."

    exit -1

fi

 

if [ "${ORACLE_HOME}NONE" = "NONE" ]

then

    echo "Error: ORACLE_HOME is not set."

    exit -1

fi

 

LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH:/lib:/usr/lib:/usr/local/lib

DDS_HOME=/oracle/app/dds/1123/bin

DDS_DATA=/oracle/app/dds/1123/data

export DDS_HOME DDS_DATA LD_LIBRARY_PATH

 

${DDS_HOME}/dds_pmont -v

 

${DDS_HOME}/dds_pmont

 

if [ $? -eq 0 ]

then

    # rm $DDS_DATA/msg.log 2>/dev/null

    ${DDS_HOME}/dds_pmsgt

    ${DDS_HOME}/dds_precvt

    ${DDS_HOME}/dds_pclr

    ${DDS_HOME}/dds_pfile

    ${DDS_HOME}/dds_pput

    ${DDS_HOME}/dds_pput -1

    ${DDS_HOME}/dds_pput -1

    ${DDS_HOME}/dds_pput -1

    ${DDS_HOME}/dds_pput -x这增加几行进程用于数据对比

else

    exit -1

fi

2odmp导出对比数据

[dds@htz62 ~]$ odmp -c 192.168.111.63:8204 -x -t scott dds1/dds1

0808162429[5.DMP00]     Dump Task:    1 SCOTT.DEPT

0808162429[5.DMP00]     Dump Task:    2 SCOTT.EMP

0808162429[5.DMP00]     Dump Task:    3 SCOTT.BONUS

0808162429[5.DMP00]     Dump Task:    4 SCOTT.SALGRADE

0808162429[5.DMP00]     Dump Task:    5 SCOTT.HTZ

0808162429[5.DMP00] Starting DMP Processes (nreader=1, Verify:Y)

0808162429[5.DMP00] ok to login [dds1/dds1]

0808162429[5.DMP00] DmpOUT: 192.168.111.63:8204   HOST:192.168.111.63 PORT: 8204

0808162429[5.DMP00] GetDATA for SCOTT.DEPT 

0808162429[5.DMP00] Count of Record: SCOTT.DEPT  4 DataLEN=43

0808162429[5.DMP00] Get SCOTT.DEPT Time: 124 ms

0808162429[5.DMP00] GetDATA for SCOTT.EMP 

0808162429[5.DMP00] Count of Record: SCOTT.EMP  14 DataLEN=83

0808162429[5.DMP00] Get SCOTT.EMP Time: 14 ms

0808162429[5.DMP00] GetDATA for SCOTT.BONUS 

0808162429[5.DMP00] Count of Record: SCOTT.BONUS  0 DataLEN=0

0808162429[5.DMP00] Get SCOTT.BONUS Time: 10 ms

0808162429[5.DMP00] GetDATA for SCOTT.SALGRADE 

0808162429[5.DMP00] Count of Record: SCOTT.SALGRADE  5 DataLEN=47

0808162429[5.DMP00] Get SCOTT.SALGRADE Time: 41 ms

0808162429[5.DMP00] GetDATA for SCOTT.HTZ 

0808162430[5.DMP00] Count of Record: SCOTT.HTZ  50079 DataLEN=229341

0808162430[5.DMP00] Get SCOTT.HTZ Time: 578 ms

0808162431[5.DMP00] DMP0 RC: R=0 P=0 W=0

0808162431[5.DMP00] Reader EXIT ( PID=6715 dumper=0, rc=0 )

0808162431[5.DMP00] CHILD: 6715 EXIT(0)

0808162431[5.DMP00]

+——————————————+

| Dmp Finish: return=  0   SUCCESSFULE     |

+——————————————+

3,目标端日志

目标端日志

0808162431[5.CHK00] Load /home/dds/dds/data/chk0/0/1.dtf (LEN=65)

0808162431[5.CHK00] Load /home/dds/dds/data/chk0/0/2.dtf (LEN=43)

0808162431[5.CHK00] Load /home/dds/dds/data/chk0/0/3.dtf (LEN=50)

0808162431[5.CHK00] Verify OK SCOTT.DEPT->HTZ.DEPT Rows: 4~4 OK:4

0808162431[5.CHK00] Load /home/dds/dds/data/chk0/0/4.dtf (LEN=64)

0808162431[5.CHK00] Load /home/dds/dds/data/chk0/0/5.dtf (LEN=83)

0808162431[5.CHK00] Load /home/dds/dds/data/chk0/0/6.dtf (LEN=49)

0808162431[5.CHK00] Verify OK SCOTT.EMP->HTZ.EMP Rows: 14~14 OK:14

0808162431[5.CHK00] Load /home/dds/dds/data/chk0/0/7.dtf (LEN=66)

0808162432[5.CHK00] Load /home/dds/dds/data/chk0/0/8.dtf (LEN=51)

0808162432[5.CHK00] Verify OK SCOTT.BONUS->HTZ.BONUS Rows: 0~0 OK:0

0808162432[5.CHK00] Load /home/dds/dds/data/chk0/0/9.dtf (LEN=69)

0808162432[5.CHK00] Load /home/dds/dds/data/chk0/0/10.dtf (LEN=47)

0808162432[5.CHK00] Load /home/dds/dds/data/chk0/0/11.dtf (LEN=54)

0808162432[5.CHK00] Verify OK SCOTT.SALGRADE->HTZ.SALGRADE Rows: 5~5 OK:5

0808162432[5.CHK00] Load /home/dds/dds/data/chk0/0/12.dtf (LEN=64)

0808162432[5.CHK00] Load /home/dds/dds/data/chk0/0/13.dtf (LEN=229341,zLEN=178104 77%)

0808162432[5.CHK00] Load /home/dds/dds/data/chk0/0/14.dtf (LEN=49)

0808162432[5.CHK00] Verify OK SCOTT.HTZ->HTZ.HTZ Rows: 50079~50079 OK:50079

0808162432[5.CHK00] Load /home/dds/dds/data/chk0/0/15.dtf (LEN=5)

0808162432[5.CHK00] End Verify objects: OK-5 ERROR-0

0808162432[5.CHK00] End Verify

4verify日志内容

[dds@htz63 chk0]$ cat verify.txt

 

************************************************

Verify SCOTT.DEPT — HTZ.DEPT

  Rows     in source table:  4

  Rows     in target table:  4

  Rows     in same   table:  4

  Rows not in source table:  0

  Rows not in target table:  0

  Rows not equal          :  0

  Rows     has Other Error:  0

  Counts of slot no  > 512:  0

  Start from: 2014-07-08 16:24:31

  End at    : 2014-07-08 16:24:31

  Total     : 0

************************************************

5,报错日志内容

如果有错误,会在下面显示出来的

 

[dds@htz63 chk0]$ cat verify.err

 

************************************************

Verify SCOTT.HTZ — HTZ.HTZ

  Rows     in source table:  0

  Rows     in target table:  50079

  Rows     in same   table:  0

  Rows not in source table:  0

  Rows not in target table:  0

  Rows not equal          :  0

  Rows     has Other Error:  0

  Counts of slot no  > 512:  0

  Start from: 2014-07-08 16:52:46

  End at    : 2014-07-08 16:52:46

  Total     : 0

************************************************

Err to verify table SCOTT.HTZ — HTZ.HTZ

本文固定链接: http://www.htz.pw/2014/08/11/dds%e6%95%b0%e6%8d%ae%e5%af%b9%e6%af%94%e6%b5%8b%e8%af%95.html | 认真就输

该日志由 huangtingzhong 于2014年08月11日发表在 DDS 分类下, 你可以发表评论,并在保留原文地址及作者的情况下引用到你的网站或博客。
原创文章转载请注明: DDS数据对比测试 | 认真就输
关键字: