IBM Support

"Error 500. Access denied" on file /tmp/jccdiag.log when running Java applications using the IBM Data Server Driver for JDBC

Troubleshooting


Problem

Java applications using the IBM Data Server Driver for JDBC failing with, "Error 500: Access denied (java.io.FilePermission /tmp/jccdiag.log write)"

Symptom

Error 500. Access denied (java.io.FilePermission /tmp/jccdiag.log write)

Cause

New to Db2 versions v9.7FP3 (DB2 v9.5 FP 7) the IBM Data Server Driver for JDBC now logs diagnostic information to the jccdiag.log file but JDK's 1.4 and JDK 1.5 do not have an API to control the file permission.

Resolving The Problem

The following options are available to avoid this error:

  • Upgrade to JDK 1.6 or above.
  • Modifying the jccdiag.log file or create it ahead of time with the appropriate file permission so that the user running the application can read and write to the file.
  • This jccdiag.log file is created in the directory set in the JVM system property "java.io.tmpdir" (which is typically /tmp by default). Specifying "java.io.tmpdir" to a directory which does not exist will also avoid the error.

[{"Product":{"code":"SSEPGG","label":"DB2 for Linux- UNIX and Windows"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Programming Interface - JDBC","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"}],"Version":"9.7;9.5","Edition":"Advanced Enterprise Server;Enterprise Server"}]

Document Information

Modified date:
16 June 2018

UID

swg21469908