Dbverify (dbv) in parallel

Today, I read the blog of Uwe Hesse about multiple dbverify sessions accessing one large datafile in parallel. I had some doubts if running multiple dbverify in parallel can significantly speed up the verification process but it looked like a good idea to me, so I decided to write a perl script to fetch size of the datafile, then spawn dbverify processes according to the desired parallelism.

Here’s the test result:

As you see, it took about 17 seconds to process 2 GB data file with dbverify. Then I run my script to run dbverify in parallel:

It took only 11 seconds. Not a significant improvement but all these tests are done in a virtual machine and I only processed about 2 GB datafile. If you test it on bigger datafiles, you can get surprising results. I used “date” function to measure the time, and I cleared the Linux Filesystem read cache between tests (and repeated the tests multiple times to be sure about the results).

If you want to test dbverify in parallel, you can download the perl script (dbvp.pl) and test it by yourself:


My script takes only 2 arguments: filename and parallelism (number of threads). For example the following command will let dbvp script to spawn 5 dbverify processes to check the datafile:

Because it uses dbv, you should set ORACLE_HOME and PATH variables according to your Oracle Home. I should say that I wrote this script just for fun and tested only on 11gR2, so there’s no guarantee that it would work on any other system. Anyway, if you find any bug, you may contact me and ask for a fix. If you like it, you can use it as you wish.

Please share this post Share on Facebook1Share on Google+0Share on LinkedIn2Share on Reddit0Tweet about this on Twitter

Gokhan Atil is a database architect who has hands-on experience with both RDBMS and noSQL databases (Oracle, PostgreSQL, Microsoft SQL Server, Sybase IQ, MySQL, Cassandra, MongoDB and ElasticSearch), and strong background on software development. He is certified as Oracle Certified Professional (OCP) and is awarded as Oracle ACE (in 2011) and Oracle ACE Director (in 2016) for his continuous contributions to the Oracle users community.

1 Comment

Leave Comment

Your email address will not be published. Required fields are marked *