BMC Release Package and Deployment - How to enable PHP error_logging in BRPD instance?

Version 2
    Share This:

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


    PRODUCT:

    BMC VaraLogix Q Deployment Automation


    COMPONENT:

    Release Package and Deployment


    APPLIES TO:

    All versions of BRPD



    QUESTION:

    How to enable PHP error_logging in BRPD instance?


    ANSWER:

    BRPD or Varalogix Q Deployment Automation runs on PHP. There is an option to enable PHP error logging so that in case there are issues in the php engine, then it can write to a proper log file which can be reviewed.
    Below are the steps followed:
    1. Stop all the BRPD processes (apache, engines, dispatcher and api).
    2. Edit the <BRPD_INSTALL_HOME>/lib/php/etc/php.ini (linux) or <BRPD_INSTALL_HOME>\lib\php\php.ini file

      Around line #572 make sure to uncomment (remove the semi-colon) and point it to a valid path/file.  
    See sample below. All the lines are comments and only error_log uncommented. 
      
          568 ; Log errors to specified file. PHP's default behavior is to leave this value  
        569 ; empty.  
        570 ; http://php.net/error-log  
        571 ; Example:  
           572 error_log = "/opt/bmc/RLM/logs/php_errors.log" 
        573 ; Log errors to syslog (Event Log on Windows).  
        574 ;error_log = syslog 
      
      3. Start all the BRPD services.  
     
      
      
      You can follow the below steps to check if the logging is working or not. 
      
      1. Create a testlogging.php file with below contents: 
      
      <?php  
    {  
        error_log("PHP-error-logging-test", 0);  
    }  
     
    ?> 
      
      2. Set path to PHP: 
      
      export PATH=<BRPD_INSTALL_HOME>/lib/php/bin:$PATH 
      
      3. Run the PHP code: 
      
      php testlogging.php 
      
      4. Tail the log file: 
      
      tail -f /opt/bmc/RLM/logs/php_errors.log 
      
     
    If the configuration is right then you can also see the file getting created with the new log entry like below: 
      
      [12-Mar-2019 14:16:02 America/Chicago] PHP-error-logging-test 
      
     
      

     


    Article Number:

    000342164


    Article Type:

    FAQ/Procedural



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