E0302004d: Cannot connect to the datasource <datasourcename> as user <userid>
search cancel

E0302004d: Cannot connect to the datasource <datasourcename> as user <userid>

book

Article ID: 112460

calendar_today

Updated On:

Products

CA Harvest Software Change Manager - OpenMake Meister CA Harvest Software Change Manager

Issue/Introduction

Error accessing the SCM server scm-broker.


Below is the error in the <date>HBroker<pid>.log file found in the %CA_SCM_HOME/log folder - 

SQLSTATE=28000 

HServer | 20180803 14:35:57 | Trying to connect to database... (Attempt 6 of 10) 
HServer | 20180803 14:36:02 | ERROR: E0302004d: Cannot connect to the datasource <datasourcename> as user <userid>. 
HServer | 20180803 14:36:02 | ERROR: [CAI/PT][ODBC Oracle Dynamic driver][Oracle]ORA-01017: invalid username/password; logon denied 

SQLSTATE=28000 

HServer | 20180803 14:36:02 | Trying to connect to database... (Attempt 7 of 10) 
HServer | 20180803 14:36:08 | ERROR: E0302004d: Cannot connect to the datasource <datasourcename> as user <userid>. 
HServer | 20180803 14:36:08 | ERROR: [CAI/PT][ODBC Oracle Dynamic driver][Oracle]ORA-01017: invalid username/password; logon denied 

SQLSTATE=28000 

HServer | 20180803 14:36:08 | Trying to connect to database... (Attempt 8 of 10) 
HServer | 20180803 14:36:13 | ERROR: E0302004d: Cannot connect to the datasource <datasourcename> as user <userid>. 
HServer | 20180803 14:36:13 | ERROR: [CAI/PT][ODBC Oracle Dynamic driver][Oracle]ORA-01017: invalid username/password; logon denied

Environment

Harvest Software Change Manager all versions and platforms
Oracle DBMS

Cause

This message happens when the userid and/or password the HServer is trying to use to connect to the Oracle database is incorrect.  
 

Resolution

To correct the problem:

  1. Stop all SCM processes.  
  • If your SCM Broker is on a Windows computer this is most easily done from Task Manager.  Search out and kill all “bkrd.exe” processes first, then any remaining “hserver.exe” processes, and any “rtserver.exe” processes last.  
  • If your SCM Broker is on a Linux or Unix computer this is most easily done by executing “ps -ef | grep -E "bkrd\|hserver\|rtserver"” and then killing all bkrd processes first, all hserver processes next, and all rtserver processes last.
  1. Double check to verify the correct Oracle userid and password to be used to connect to the Harvest database in Oracle.
  • The easiest way to do this is with SQL Plus.  From a command prompt window execute “sqlplus userid/password@servicename” where userid = your Harvest database schema owner userid, password = your Harvest database schema owner password, and servicename = the service name in your $ORACLE_HOME/network/admin/tnsnames.ora file that points to the hostname and port number for your Harvest database.  If you are able to successfully login and get the “SQL>” prompt you know you have the right userid and password.
  1. Use the “svrenc” command line utility to update the encrypted password file.
  • Execute the “svrenc -s” command.  It will prompt you for userid and password.  Provide the correct information and a new encrypted password file will be created.  On the Windows computer this file name is “%CA_SCM_HOME%\hsvr.dfo” on Unix and Linux this file name is $CA_SCM_HOME/.hsvr.dfo .  You can check the timestamp on this file to confirm that it has been updated.
  1. Restart the SCM broker and check your new HServer log files to confirm the problem is resolved.