Creating and initializing DB2 on Linux

Complete the following steps to create and initialize the DB2 database on a Linux server.

Before you begin 

  • The database server software must be installed and configured.
  • You must have created a database, database user, and schema for the exclusive use of the TrueSight Middleware and Transaction Monitor product.
  • if you plan to use Transaction Management features of TrueSight Middleware and Transaction Monitor, use the largest data block/page size allowed by the DBMS, preferably 32K. Consult your DBMS vendor documentation on how to create a database or database objects with a larger page size.
  • The Services server must be in close physical proximity to the database server with a network latency of less than 5ms between them (100 Mb LAN). BMC recommends a gigabit LAN.
  • Database clients must be appropriate to the installation of the core components and to the database server. TrueSight Middleware and Transaction Monitor services are 64-bit applications on Windows and Linux (SLES, RHEL). BMC recommends that the database client version matches the database server version. 

Notes

  •  If the transaction logs for the database become full, your TrueSight Middleware and Transaction Monitor services might appear to stop. Be sure that you allocate adequate space for the transaction logs, and monitor their use so you can increase the space allocation if needed.
  • If you intend to use aliases and also intend to partition Performance and Availability history data and have TrueSight Middleware and Transaction Monitor manage those partitions, ensure that the schema that the TrueSight Middleware and Transaction Monitor user has the ability to store detached tables temporarily. Contact BMC Support for more information.

To create and initialize DB2 on Linux

  1. Install the database client software on any computer that needs access to the database.
  2. Run the scripts db2.create.sql and db2.init.sql from within a DB2 interactive session.

    See Running the scripts to create and initialize the database.

    db2 -o -stf db2.create.sql -l db2.create.log
    db2 -o -stf db2.init.sql -l db2.init.log
  3. Ensure that the schema for use by the TMTM user has full authority granted to all the objects within it.

    Use of aliases is supported, provided the TMTM database user has full authority over the base database objects through the aliases.
  4. Add the following to the .profile file of the local user used to run services.
    Adding these paths to your profile ensures that the services can locate and use required third-party software on your system.
    1. Replace db_details with the path to any TMTM database specific shared objects that are needed to run database applications.
    2. If necessary, work with your system or database administrator or your database documentation to determine the appropriate information to add to the path.
      Typically, this task involves sourcing the db2profile. If you do not plan to use a dedicated user account to run services, follow your company's policies for setting local environment variables to add this information.

      64-bit DB2

      export/add to .profile filei

      Linuxii

      LD_LIBRARY_PATH=.:/InstallDir:db_details:$LD_LIBRARY_PATH 

      This allows the services to connect to a 64-bit DB2 database using the 64-bit client libraries (libdb2.so, etc.).

      1. The colon is a separator character and must appear between each path.
      2. The LD_LIBRARY_PATH must be set on all Linux systems with the TMTM Application Service.
  5. When the scripts are complete, ensure that your entire database network is functioning and all of the clients can access and write to the server.

Where to go from here

Run scripts to create and initialize the database.

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

Comments