CA API Gateway Platform Patch application error Thread died in Berkeley DB library Fatal error
search cancel

CA API Gateway Platform Patch application error Thread died in Berkeley DB library Fatal error

book

Article ID: 229356

calendar_today

Updated On:

Products

CA API Gateway

Issue/Introduction

When installing the platform patch there is a error in the sspc log and the patch install fails .

sh /opt/SecureSpan/Controller/bin/patch.sh /opt/SecureSpan/Controller/ upload /home/ssgconfig/Layer7_API_PlatformUpdate_64bit_v10.X-CentOS-2021-10-20.L7P

Patch ID Layer7_API_PlatformUpdate_64bit_v10.X-CentOS-2021-10-20 (Upgrades the Layer7 API 64bit Platform to the 10.X-CentOS-2021-10-20 version.This patch requires that the 10.X Platform Update be installed first. It also requires a restart of the Layer7 API Gateway Appliance.) is UPLOADED, last modified on 2021-11-16T21:59:36-0500

Patch operation completed successfully.

sh /opt/SecureSpan/Controller/bin/patch.sh /opt/SecureSpan/Controller/ install Layer7_API_PlatformUpdate_64bit_v10.X-CentOS-2021-10-20

Fails with below error in sspc_0_0.log


error: rpmdb: BDB0113 Thread/process 26961/139700598528064 failed: BDB1507 Thread died in Berkeley DB library
error: db5 error(-30973) from dbenv->failchk: BDB0087 DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages index using db5 -  (-30973)
error: cannot open Packages database in /var/lib/rpm
warning: acl-2.2.51-15.el7.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID f4a80eb5: NOKEY
error: rpmdb: BDB0113 Thread/process 26961/139700598528064 failed: BDB1507 Thread died in Berkeley DB library
error: db5 error(-30973) from dbenv->failchk: BDB0087 DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages index using db5 -  (-30973)
error: cannot open Packages database in /var/lib/rpm
ERROR   : Failed to install the missing RPMs
Error installing patch: Error executing patch task: non-zero exit code returned from patch install script (returned 1)
Full stack trace:
com.l7tech.server.processcontroller.patching.PatchException: Error executing patch task: non-zero exit code returned from patch install script (returned 1)
        at com.l7tech.server.processcontroller.patching.builder.ShellScriptPatchTask.runPatch(ShellScriptPatchTask.java:53)
        at com.l7tech.server.processcontroller.patching.builder.PatchMain.main(PatchMain.java:34)
Patch exit code: 1
Patch ID Layer7_API_PlatformUpdate_64bit_v10.X-CentOS-2021-10-20 (Upgrades the Layer7 API 64bit Platform to the 10.X-CentOS-2021-10-20 version. This patch requires that the 10.X Platform Update be installed first. It also requires a restart of the Layer7 API Gateway Appliance.) is ERROR, last modified on 2021-11-16T22:00:42-0500

There were errors during the patch operation.

See sspc logs in /opt/SecureSpan/Controller/var/logs for details.

Environment

Release : 10.x 

Component :

Resolution

The following steps will resolve the issue and repair the corrupted rpm database 

  1.  Take a VM snap shot or make sure you have a backup .
  2.  # mv /var/lib/rpm/__db.* /tmp 
  3.  # rpm -qa
  4.   Apply the layer7 patch again.