Errors when starting Harweb - ORA-12505
search cancel

Errors when starting Harweb - ORA-12505

book

Article ID: 220774

calendar_today

Updated On:

Products

CA Harvest Software Change Manager

Issue/Introduction

After installing Harweb, when we try to start up Tomcat it has this error:

Loading DB authentication from SCM...
Loading authentication successful.
ConnectionPool: JDBCDriver = oracle.jdbc.driver.OracleDriver
ConnectionPool: JDBCConnectionURL: jdbc:oracle:thin:@oracle=server:1530:ORATNS
ConnectionPool: ConnectionPoolSize = 5
ConnectionPool: ConnectionPoolMax = 100
ConnectionPool: ConnectionUseCount = 5
ConnectionPool: ConnectionTimeout = 2 seconds
ConnectionPool: Registering oracle.jdbc.driver.OracleDriver
..created pool of size 5java.sql.SQLException: Listener refused the connection with the following error:
ORA-12505, TNS:listener does not currently know of SID given in connect descriptor

Environment

Release : 14.0

Component :

Resolution

During Harweb installation it asks for the Oracle database's hostname, port number and SID.  Accordingly it builds the JDBCConnectionURL in this format: 

jdbc:oracle:thin:@[HOST][:PORT]:SID

In many cases, the Oracle SID and the TNS Service Name are the same, but sometimes they're different.  To build the JDBCConnectionURL to use the TNS Service Name instead of the SID you have to use this format:

jdbc:oracle:thin:@[HOST][:PORT]/SERVICE 

In this case we knew the TNS Service Name but not the SID so we edited the harweb.cfg file inside <tomcathome>\webapps\Harweb\WEB-INF and changed the format of the JDBCConnectionURL to have the slash instead of the colon.

JDBCConnectionURL=jdbc:oracle:thin:@oracle=server:1530/ORATNS

After this, Tomcat and Harweb were able to start normally.