Unsupported content This version of the product has reached end of support. The documentation is available for your convenience. However, you must be logged in to access it. You will not be able to leave comments.

Setting up a SQL Server database


BMC provides an automated approach to setting up a database as part of the overall installation for BladeLogic Portal (see Installing-a-compact-deployment-of-the-portal-on-Windows). However, if you prefer, you can set up a Microsoft SQL Server database manually using this procedure.

This topic includes the following sections:

About the procedure

The procedure describes how to create two users (also known as logins). One user creates the portal database while the other user functions as an operational user. For security reasons, the operational user is granted only limited access to data.

This procedure uses SQL scripts that are provided in installation files.

Warning

These tasks should be performed by a database administrator (DBA). Perform the steps in these tasks in the order in which they are described. If you are not using the scripts mentioned in this procedure, refer to them to determine the privileges required.

Before you begin

  • Use SQL Server 2012 x64 or SQL Server 2014 x64.
  • Obtain the installation file called BTD22.WIN64.zip and extract its contents. The extraction creates a directory structure where the top level directory is called BladeLogicPortal.
    In versions earlier than 2.2.01, the file is called BLPortal22.WIN64.zip.

To set up a SQL Server database

Recommendation

Use only Latin alphabet letters, numbers, and underscores (_) in database names. Do not begin database names with a number.

  1. Log into the SQL Server database using administrator credentials.
  2. Create a new login.
    1. Assign any name consistent with your naming standards.
      For example, create a login named blportal_owner
    2. If you select SQL Server authentication, provide a password.
    3. When defining the login, on the Server Roles page, select Public
    4. On the Status page, ensure that Permission to connect to database engine is set to Grant and Login is set to Enabled.
  3. Create a new database object.
    1. Assign any name consistent with your naming standards. For example, assign a name called blportal
    2. Set Owner to the login name you created in step 1, such as blportal_owner.
  1. Open the Properties page for the login created in step 2 and change Default database to the database created in step 3.
    This step limits user access to only the portal database for security reasons.
  2. Create another login that functions as the operational user. 
    1. Assign any name consistent with your naming standards.
      For example create a login named blportal_oper
    2. If you select SQL Server authentication, provide a password.
    3. Set Default database to the database created in step 3
    4. On the User Mapping page, select the database created in step 3, and on the same page select the following role memberships:

      • db_datawriter
      • db_datareader

      The public role is selected automatically on the User Mapping page. Leave it as is. 

    5. On the Status page, ensure that Permission to connect to database engine is set to Grant and Login is set to Enabled.
  3. Create the database tables by executing the sqlserver_master.bat script. 

    1. In the installation files, cd to this directory: installation_file_location\\BladeLogicPortal\windows\Disk1\utility\sqlserver
    2. Run the following command:
      sqlserver_master.bat sqlserv db user pwd

      where:

      sqlserv is the name of the host where SQL Server is running, such as localhost
      db is the name of the database created in step 2, such as blportal.
      user is the name of the SQL Server user that has the db_owner role. This login is created in step 1. For example, blportal_owner.
      pwd is the password of the SQL Server user.

    SQL Server creates the schema, core data, indexes, and constraints.

Where to go next

Enable web services in BMC Server Automation, which is a prerequisite to installation. Then you are ready to install BladeLogic Portal on Windows.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*