Multiple dbverify sessions accessing one large datafile in parallel

Do you use dbverify (dbv) against large datafiles to check for block corruption? Then chances are that you missed an 11gR1 New Feature: dbv can now divide one file into multiple parts and check them in parallel:

SQL> select * from v$version;
BANNER
 --------------------------------------------------------------------------------
 Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
 PL/SQL Release 11.2.0.3.0 - Production
 CORE    11.2.0.3.0    Production
 TNS for Linux: Version 11.2.0.3.0 - Production
 NLSRTL Version 11.2.0.3.0 - Production
SQL> col name for a50
 SQL> select name,blocks from v$datafile;
NAME                               BLOCKS
 -------------------------------------------------- ----------
 /home/oracle/prima/system01.dbf             38400
 /home/oracle/prima/sysaux01.dbf             25600
 /home/oracle/prima/undotbs01.dbf            22912
 /home/oracle/prima/users01.dbf              1280

My demo system is on 11.2.0.3, but the feature is already there in 11gR1, as the doc page here shows. See the parameters start and end there.

[oracle@uhesse1 ~]$ dbv file=/home/oracle/prima/users01.dbf start=1 end=500

DBVERIFY: Release 11.2.0.3.0 - Production on Mon Aug 20 21:59:28 2012

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

DBVERIFY - Verification starting : FILE = /home/oracle/prima/users01.dbf

DBVERIFY - Verification complete

Total Pages Examined         : 500
Total Pages Processed (Data) : 11
Total Pages Failing   (Data) : 0
Total Pages Processed (Index): 0
Total Pages Failing   (Index): 0
Total Pages Processed (Other): 136
Total Pages Processed (Seg)  : 0
Total Pages Failing   (Seg)  : 0
Total Pages Empty            : 353
Total Pages Marked Corrupt   : 0
Total Pages Influx           : 0
Total Pages Encrypted        : 0
Highest block SCN            : 212814 (0.212814)
[oracle@uhesse1 ~]$ dbv file=/home/oracle/prima/users01.dbf start=501 end=1280

DBVERIFY: Release 11.2.0.3.0 - Production on Mon Aug 20 22:10:16 2012

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

DBVERIFY - Verification starting : FILE = /home/oracle/prima/users01.dbf

DBVERIFY - Verification complete

Total Pages Examined         : 780
Total Pages Processed (Data) : 0
Total Pages Failing   (Data) : 0
Total Pages Processed (Index): 0
Total Pages Failing   (Index): 0
Total Pages Processed (Other): 0
Total Pages Processed (Seg)  : 0
Total Pages Failing   (Seg)  : 0
Total Pages Empty            : 780
Total Pages Marked Corrupt   : 0
Total Pages Influx           : 0
Total Pages Encrypted        : 0
Highest block SCN            : 0 (0.0)

Granted, the file here is not large – but you should get the picture: I could have run the two dbv sessions from two different  terminal windows in parallel as well. I realized from a recent twitter thread that this 11g New Feature that I teach since years is probably widely unknown – did you know it?

As always: Don’t believe it, test it! 🙂

,

  1. #1 von musingdba am August 21, 2012 - 02:26

    Thanks Uwe.

    This feature is something new to me. thanks for posting.

    regards,
    madhurendra

  2. #2 von Gokhan Atil am August 21, 2012 - 17:35

    Hey Uwe, nice idea! I wrote a small script about it:

    http://www.gokhanatil.com/2012/08/dbverify-dbv-in-parallel.html

  3. #3 von Uwe Hesse am August 25, 2012 - 08:43

    madhurendra, you’re welcome 🙂
    Gokhan, yes I saw that. Great follow up, thank you for sharing. This social media thing is really amazing, isn’t it? 🙂

  4. #4 von Andrew Reid am November 27, 2012 - 01:12

    Dear Uwe,

    I liked this post so I translated it into Spanish here:
    http://oracleenespanol.wordpress.com/2012/11/26/dbverify-en-modo-paralelo/
    Incidentally, I think this was already available in Oracle 10.2.

    Kind regards,

    Andrew

  5. #5 von Uwe Hesse am November 28, 2012 - 20:50

    Hi Andrew,
    thank you for the translation! I do not think that this was available in 10.2 – at least it is not documented: http://docs.oracle.com/cd/B19306_01/server.102/b14215/dbverify.htm#sthref1843

  6. #6 von Prasad Avadhanam am April 28, 2016 - 16:16

    If the activity is I/O bound, then, each task is already keeping disks 100% busy, does the parallel scanning really expedite the whole operation?

  1. Dbverify (dbv) in parallel | Gokhan Atil's Oracle Blog
  2. dbverify en Modo Paralelo | Mi Blog sobre Oracle

Kommentar verfassen

Trage deine Daten unten ein oder klicke ein Icon um dich einzuloggen:

WordPress.com-Logo

Du kommentierst mit deinem WordPress.com-Konto. Abmelden /  Ändern )

Facebook-Foto

Du kommentierst mit deinem Facebook-Konto. Abmelden /  Ändern )

Verbinde mit %s

Diese Seite verwendet Akismet, um Spam zu reduzieren. Erfahre, wie deine Kommentardaten verarbeitet werden..