PingDatabase failed to connect to database. Failed to open database connection.
search cancel

PingDatabase failed to connect to database. Failed to open database connection.

book

Article ID: 173818

calendar_today

Updated On:

Products

IT Management Suite

Issue/Introduction

While launching SIM (Symantec Installation Manager), a message was displayed saying that it couldn't connect to the database.
When the customer tried to connect to his existing database using SIM>Configure Settings, SIM was not able to show any of the existing databases nor create a new one.

The following entries were popping up in the NS logs:

Entry 1:
PingDatabase failed to connect to database.
Failed to open database connection.
[Symantec.Installation.Helpers.DatabaseNotAccessibleException @ SymantecInstallationManager]
at Symantec.Installation.Helpers.DatabaseManager.OpenConnection(String serverName, String catalog, String loginUserName, SecureString loginPassword, Boolean useIntegratedSecurity, Int32 retries)
at Symantec.Installation.InstallClasses.SQLAuth.PingDatabase(String databaseName, Int32 retries)

Cannot open database "Symantec_CMDB" requested by the login. The login failed.
Login failed for user 'DOMAIN\altirisadministrator'.


Entry 2:
VerifyDBPermissions failed
Database 'ALTIRISCMDB' does not exist. Make sure that the name is entered correctly.
[System.Data.SqlClient.SqlException @ .Net SqlClient Data Provider]


Entry 3:
Provided credentials (username DOMAIN\altirisadministrator) were valid but do not have NS database access rights.

Environment

ITMS 8.0 or later

Resolution

Try the following:

  1. Delete these regkeys (so SIM can recreate those references in case the encrypted ones were not right):
    HKEY_LOCAL_MACHINE\SOFTWARE\Altiris\AIM\Configuration\NsConfiguration\SqlUserName

    HKEY_LOCAL_MACHINE\SOFTWARE\Altiris\AIM\Configuration\NsConfiguration\SqlPassword

  2. Close and launch SIM again.
  3. Go to "Configure Settings>Configure Database Settings" try to attach the desired database and let the configuration process run.