search cancel

ViP Auth Hub : DB connect failed during SSP dataload job

book

Article ID: 243992

calendar_today

Updated On:

Products

SITEMINDER VIP Authentication Hub

Issue/Introduction

SSP dataload job is failing with following error.

[[email protected] aws-service-viphub]$ kubectl logs ssp-data-ssp-data-networkdataload-job-axfs-6pc8m -n ssp
***************************************************
* Saving latest UnallocatedNetwork data to Database
***************************************************
list_management.sh: INFO: Using java found at "/opt/java/openjdk".Working directory is ./bin/../
{"type":"log","timestamp":"2022-06-14T11:51:55.711+0000","level":"INFO","level":"INFO","thread":"main","msg":"Preparing to import: /app/symc/deployListManagementTool/data/UnallocatedNetworks/UnallocatedNetworks_2022-05-23_v1043.zip","jobName": "NetworkDataLoader","jobVersion": "1.0.1042"}
ERROR StatusLogger Reconfiguration failed: No configuration found for '277050dc' at 'null' in 'null'
{"type":"log","timestamp":"2022-06-14T11:51:56.702+0000","level":"INFO","level":"INFO","thread":"main","msg":"database jdbc URL: jdbc:mysql://mysql-viphub.test.net:3306/viphubdb&rewriteBatchedStatements=true","jobName": "NetworkDataLoader","jobVersion": "1.0.1042"}
{"type":"log","timestamp":"2022-06-14T11:51:56.702+0000","level":"INFO","level":"INFO","thread":"main","msg":"Initializing Data Source Pool for JDBC URL jdbc:mysql://mysql-viphub.test.net:3306/viphubdb&rewriteBatchedStatements=true using password-based connection security","jobName": "NetworkDataLoader","jobVersion": "1.0.1042"}
{"type":"log","timestamp":"2022-06-14T11:51:56.707+0000","level":"WARN","level":"WARN","thread":"main","msg":"No encryption or checksum is used in JDBC connection.","jobName": "NetworkDataLoader","jobVersion": "1.0.1042"}
org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (Could not connect to address=(host=mysql-viphub.test.net)(port=3306)(type=master) : (conn=7867) Access denied for user 'viphubdbuser'@'%' to database 'viphubdb&rewriteBatchedStatements=true')
at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1225)
at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:880)
at com.verisign.connpool.ConnectionManager.getNonTransactionalConnection(ConnectionManager.java:180)
at com.snap.utils.DBUtils.testConnection(DBUtils.java:488)
at com.verisign.lmt.config.DBConnectionFactory.initialize(DBConnectionFactory.java:41)
at com.snap.fin.tools.FINMain.main(FINMain.java:48)
Caused by: java.sql.SQLSyntaxErrorException: Could not connect to address=(host=mysql-viphub.test.net)(port=3306)(type=master) : (conn=7867) Access denied for user 'viphubdbuser'@'%' to database 'viphubdb&rewriteBatchedStatements=true'
 

Environment

Release : 12.8

Component : VIP Authentication Hub

Cause

JDBC URL is invalid.

If you are adding any switch to the JDBC URL then it has to start with a query string (?) and subsequent switches need to be using ampersand(&) as separators.

"jdbc:mysql://mysql-viphub.test.net:3306/viphubdb&rewriteBatchedStatements=true"

Above sample is only using ampersand without any question mark so the "viphubdb" was supposed to be the DB Name but "rewriteBatchedStatements=true" became part of the DB name as the separator is not correctly used.

 

Resolution

JDBC URL should have been "jdbc:mysql://mysql-viphub.test.net:3306/viphubdb?rewriteBatchedStatements=true"