Search code examples
javajdbc

What causes FileNotFoundException: ...pdq.jar with db2jcc4?


When adding db2jcc4.jar to the system class path, Tomcat 8.0 raises a FileNotFoundException on a jar file that has no apparent reference to my project, pdq.jar.

I couldn't find it anywhere on my system or where it might come from, except through a search which turned up the answer below.

In this case, I have my CATALINA_HOME pointed to C:\tomcat8.0\apache-tomcat-8.0.41 and my project has the following maven dependency defined:

<dependency>
        <groupId>com.ibm.db2.jcc</groupId>
        <artifactId>db2jcc4</artifactId>
        <version>10.1</version>
        <scope>system</scope>
        <systemPath>${env.CATALINA_HOME}/lib/db2jcc4-10.1.jar</systemPath>
</dependency>

Solution

  • According to this KB article on IBM, the problem comes from the MANIFEST, which lists pdq.jar, a third party optimization tool.

    I had both db2jcc4.jar and db2jcc4.10.1.jar in my lib folder.

    While the article suggests editing the MANIFEST file in db2jcc4.jar, version 10.1 does not include this entry at all.

    Removing db2jcc4.jar solved my problem, so a solution in this case could also be to upgrade db2jcc4 from an older version to version 10.1, or if that is not possible, edit the manifest file as instructed.