After installing Control-M/Forecast, the Control-M/Enterprise Manager Sybase database is growing very fast.

Version 1
    Share This:

    This document contains official content from the BMC Software Knowledge Base. It is automatically updated when the knowledge article is modified.


    PRODUCT:

    Control-M/Enterprise Manager


    APPLIES TO:

    Control-M/Enterprise Manager



    PROBLEM:

     

      After installing Forecast, the Gateway's start to collect "forecast records" in two tables RUNINFO_HISTORY and AVG_RUN_INFO:  
     
    - RUNINFO_HISTORY: For each job execution in the last 90 days a record is entered to this table. The RunTimeHistoryDays system parameter determines how many days will be kept in the RUNINFO_HISTORY table. This value can be lowered or set to 0 so only one day will be kept in the database. Forecast reports from the Reporting Facility will have only one day of data but it will not affect any other Forecast features.  
     
    - AVG_RUN_INFO: For each job definition a record is entered to this table, so that it should contain up to the maximum number of job definitions which exists in the database. Each row consists of the job key, its average run time and the last 20 running times. The last 20 runtimes are kept in order to have a more accurate average runtime calculation.  
     
    The AVG_RUN_INFO table is used during a Forecast of a future date to get the average elapsed time. Deleting the contents of this table will cause Forecast results to be inaccurate (Forecast will use a default of 5 minutes for each job).  
     
    This problem may occur in environments that submit new jobs via the ctmcreate utility on Control-M Server.  
    As a result, AVG_RUN_INFO table is growing constantly, adding a new line for each new job. 
      

     

     


    SOLUTION:

     

    Legacy ID:KA318913

      
      Tracking item BCTM005914 relates to this problem that causes the AVG_RUN_INFO table to consume a lot of memory.  
     
    In the Sybase table AVG_RUN_INFO, columns SAMPLES_RUN_TIME, SAMPLES_START_TIME are defined as type 'text' which can reserve 2kb or 4kb of memory.   

    Workaround:
    Alter table AVG_RUN_INFO by applying the following procedure:

    1. Stop all gateways

    2. Connect to the Control-M/Enterprise Manager database

       

    3. Run the following SQL statements (in this order):
    1> truncate table AVG_RUN_INFO
    2> go
    1> alter table AVG_RUN_INFO drop SAMPLES_START_TIME
    2> go
    1> alter table AVG_RUN_INFO drop SAMPLES_RUN_TIME
    2> go
    1> alter table AVG_RUN_INFO add SAMPLES_RUN_TIME varchar(255) null
    2> go
    1> alter table AVG_RUN_INFO add SAMPLES_START_TIME varchar(255) null
    2> go

    4. Verify that columns SAMPLES_START_TIME and SAMPLES_RUN_TIME are using type varchar.
    1> sp_help AVG_RUN_INFO
    2> go

       

    5. Start all gateways.

    If Control-M/Enterprise Manager database is ever rebuilt, it will be necessary to repeat the above instructions.

      
      

     

      
    Related Products:  
       
    1. Control-M/Enterprise Manager

     


    Article Number:

    000081966


    Article Type:

    Solutions to a Product Problem



      Looking for additional information?    Search BMC Support  or  Browse Knowledge Articles