To Create a Live Recording File from the Command Line

Restriction: This feature is only supported on the following platforms:
  • Red Hat Linux (x86 and x64)
  • SUSE Linux Enterprise Server (SLES) 12 SP2 (x64 only)

Additional restrictions apply. For details, see the Reverse Debug and Live Recording topic in the Known Issues and Restrictions section of this documentation.

  1. From a shell prompt, set the COB_LIVE_RECORD environment variable to the path and filename of the intended file:
    export COB_LIVE_RECORD=path/and/filename
  2. (Optional) Set the COB_LIVE_RECORD_SIZE environment variable to control the amount of memory used to store events that are to be written to the live recording file:
    export COB_LIVE_RECORD_SIZE=mem-size

    where mem-size is the amount of memory (in MB) allocated. If not set, the amount of memory used defaults to 268MB. The minimum value you can set is 67, and the maximum value is dependant on your environment (available memory, bitism, etc...).

    Warning: When the limit is reached, the buffer is cycled so that the oldest events are removed to make space for the most recent events; therefore, when debugging a recording file where this has occurred, debugging won't necessarily start at the beginning of the program.
  3. Run the application from the shell prompt:
    cobrun [switch-params] program-name [program-params]

    See the cobrun Command topic for a full explanation of the syntax.

When the application terminates, a recording file is created at the path specified, and with the filename appended with <processID>.mfr; for example MyProg.1884.mfr. You can now use this file on another machine to step through the recorded execution.