Skip to main content

Refreshing or Deleting a DB2 VDB after a SQL5187N error (KBA9628)




KBA# 9628



When attempting to perform VDB operations such as Refresh or Delete on a DB2 VDB, the following error may be reported:

Failed to execute the DB2 script /opt/delphix/toolkit/.../plugin/DB2_.../logs/myinstance/MYVDB.CONNECT_PROC.sql.

DB21034E The command was processed as an SQL statement because it was not a
valid Command Line Processor command. During SQL processing it returned:
SQL5187N The "CREATE OR REPLACE PROCEDURE" operation is not allowed for
procedure "CP.CONNECT_PROCEDURE" because a connection procedure with the same
name is defined for the database. LINE NUMBER=8. SQLSTATE=429C8


Applicable Delphix Versions

Click here to view the versions of the Delphix engine to which this article applies
Major Release All Sub Releases






In order to ensure that a DB2 VDB cannot be accessed while provisioning processes are still running, a "connection procedure" is temporarily defined to restrict connections.

In cases when the provisioning process is aborted or fails, this connection procedure may remain in place and need to be removed manually.


To resolve this issue and prevent the SQL5187N error, connect to the server running the affected VDB and remove the connection procedure from the VDB by modifying the CONNECT_PROC database configuration parameter:

db2 "connect to <VDB Name>"
db2 "update db cfg for <VDB Name> using CONNECT_PROC NULL"

Once this change is made, the failing VDB operations should run successfully to completion.

Delphix Engineering is aware of this behavior, and considering improvements for a future release.



Related Articles

The following articles may provide more information or related information to this article: