You cannot create, edit, or delete records in the Main Log (sys_log), Script Log (sys_log_script), Exception Log (sys_log_exception) and tables. Only users with the admin role can read them.

If you need to find specific records or to sort them in a particular order, use the condition builder to configure the filters that best suit your needs.

Main Log

Navigate to the System Logs → Main Log to read the records of this storage,

The following system events are recorded in the storage:

  • adding attachments.

  • impersonation.

  • performing a search.

  • performing a quick import.

  • LDAP user authorization.

  • LDAP autoprovision (creating user accounts via LDAP).

  • email authorization.

  • calling the server-side SimpleSystem logging methods.

  • server validation errors.

  • incoming email errors.

  • errors occurred when sending incorrect parameters into notifications.

Main Log form fields

Field

Description

Source

Message source (the module, script, or functionality that was the originator of the logging).

Level

Message importance level:

  • Debug – debug message

  • Info – information message

  • Warning – warning message

  • Error – error message.

These messages can be added using relevant SimpleSystem API methods.

Message

The log message content.

Username

Reference to the user initiated this record creation.

Script Log

This storage is for script execution extended information. All related information can be found here, from the script body to its memory usage.

It is recommended to use the Script Log only for test instances. When used in production, it creates a significant load on the servers and can degrade the performance.

Set the value of the simple.logs.enable_script_logging property to false to disable the script logging.

Navigate to System Logs → Script Log to access these storage records.

Script Log record fields

Field

Description

Script Document

A reference to the script object realized by this script. It may be, for example, a business rule.

Script

The script body.

Result

Script execution results (the returned value, as an example).

Exception log

Reference to the Exception Log record that appeared during script execution.

Essence document

A reference to the object on which this script was executed.

Start time

This field displays the timestamp when the script started (in the Unix time format).

Processing time

Script processing time (in seconds).

Memory usage

Total script memory usage.

Memory start

Script memory usage when it just started.

URL

Page URL where the script was called.

Username

Reference to the user initiated this record creation.

Exception Log 

This storage contains records with an exception thrown when the script is executed.

Navigate to System Logs → Exception Log to access these storage records.

Exception Log form fields

Field

Description

Message

Error message text returned by script.

UsernameReference to the user initiated this record creation.

File

PHP-script file that has returned this error.

String

Line number in script file.

Backtrace

A call back stack with a list of the functions called.

Page URL

Link to a page where this exception was thrown.


Log Archiving

Instance log storage grows over time. And in most cases, the analysis requires logs from the last two weeks or a month.

The log archiving engine allows you to save outdated logs, so that they do not affect system performance.

Archiving setup


The archiving engine is not active by default. To activate it, complete the steps below:

  1. Navigate to System Scheduler → Scheduled Scripts.

  2. Go to the one of the Run Log Archiving record delivered and select the Active checkbox.

  3. Click Save or Save and exit to apply the changes.

The "out-of-box" solution includes three archive scripts with different start times: 1 a.m., 3 a.m. and 5 a.m. You can specify different time and frequency for the archiving. To do this, edit the existing records, or create similar records with the Make a copy UI action and modify the copy.

The background archiving process performs the following operations:

  1. Collects logs which are the most outdated at the moment.

  2. Pack them into an archive.

The script determines the oldest log from three following tables: sys_log, sys_log_script, sys_log_exception. After that, the check is performed whether these logs outdated at the moment. To do so, the simple.logs.rotate_period_in_days property is used that allows you to set the logs' rotation period in days. If a period is not defined, the default value is 30 days.

Manage log archives


To unpack a log archive, complete the steps below:

  1. Navigate to System Logs → Archive.

  2. Find the date you need the logs for and go to the specified logs record.

  3. On the record form, click Unpack.

  4. Once completed, all records will be available in the relevant tables.

To pack a log archive, complete the steps below:

  1. Navigate to log record.

  2. Click Archive unpacked data.

  • No labels