Running the SQL update scripts

When upgrading to 8.2 service pack 2 or later (that is, to product version 8.2.02, 8.2.03, or 8.2.04), after upgrading the Application Server you must run a set of SQL Update scripts to upgrade the BMC Server Automation database to the service pack level compatible with the Application Server.

Before you begin

Ensure that the computer on which you run the SQL Update scripts fulfills the following requirements:

  • Has access to the BMC Server Automation database server
  • Has SQL tools installed, such as SQL*Plus (in the case of Oracle) or sqlcmd (in the case of Microsoft SQL Server)
    You can install the sqlcmd utility from the SQL Server install media, or as part of the SQL Server 2008 R2 feature pack or the SQL Server 2012 feature pack. You can find the utility from the full SQL server install under Shared Features > Management Tools - Basic.
    Click here to download a standalone installer from the Microsoft website. 

In addition, ensure that the user that you created for the BMC Server Automation database owner has permissions to create tables and indexes in the database.

To run the SQL update scripts for an Oracle database

  1. Obtain the zipped package of SQL Update scripts from the BMC Electronic Product Distribution (EPD) website, as described in Obtaining the installation files. This zipped package is named 82-<SP level>-SQL_Update_Scripts.zip file, where <SP level> can be one of the following values: SP4, SP3, or SP2
  2. Extract the contents of the zipped package of SQL Update scripts to a temporary local directory.
  3. Navigate to the directory that contains the update scripts  (temporaryDirectory/8.2.0x/Remediation/oracle).
  4. Log on to SQL*Plus as the BMC Server Automation database owner (as provided to blasadmin during BMC Server Automation schema creation).
  5. Run the script, as follows:

    SQL>start install_hotfix_update_oracle_script.sql
    

To run the SQL update scripts for a Microsoft SQL Server database

  1. Obtain the zipped package of SQL Update scripts from the BMC Electronic Product Distribution (EPD) website, as described in Downloading the installation files. This zipped package is named 82-<SP level>-SQL_Update_Scripts.zip file, where <SP level> can be one of the following values: SP4, SP3, or SP2
  2. Extract the contents of the zipped package of SQL Update scripts to a temporary local directory.
  3. Navigate to the directory that contains the upgrade scripts (temporaryDirectory/8.2.0x/Remediation/sqlserver).
  4. Execute the install_hotfix_update_sqlserver_script.bat file with the following input parameters:
    install_hotfix_update_sqlserver_script.bat <DBServerName> <DBName> <Username> <Password>

    Example


    install_hotfix_update_sqlserver_script.bat testserver test_db BLuser BMC123

    Recommendation

    After upgrading the SQL update scripts from version 3.1.01 to 4.1, the scripts do not execute when the password has special characters.

    BMC recommends entering the password in double quotes while executing this script on command prompt.

Was this page helpful? Yes No Submitting... Thank you

Comments