Can traces of the runtime system be logged in the syslog of the target system?

Yes, but this is only possible for the supported target systems that are based on Linux.

Hence, the logging of traces of the runtime system is possible in the →syslog of the following PLCs:

→phyBOARD-Regor, →phyBOARD-Wega, →Raspberry Pi, →Revolution Pi and when using the platform LinuxX86


In a nutshell: You must define the environment variable RTS_LOG_SYSLOG on the target system before the runtime system is started.

Here the detailed instruction:

  1. Terminate the runtime system on the target system.

  2. Define the environment variable RTS_LOG_SYSLOG.
    You are able to define environment variables by using the command export e.g. in a terminal window of PuTTY. If in doubt, ask an administrator for support.
    Example for defining the environment variable:

    export RTS_LOG_SYSLOG=1

    images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/information.svg Effects:

    • The following output is filed according to the system logging configuration of the target system:

      • log messages of the runtime system

      • log messages of the Trace block within the PLC-programs

      • all log messages of →vendor blocks when using the RT_TRACE() macro or the rt_trace() functions

    • By default, traces of the runtime system are filed in a file within the directory /var/log of the target system. Usually this file is:

      • /var/log/messages in case of systems that are using SysV-Init and the "syslog" service (usually, these are older systems)

      • /var/log/syslog in case of systems that are using the "SystemD" service (current Linux distributions, such as Ubuntu 18)

    • In order to change the filing location, adjust the configuration in the system files (/etc/syslog.conf, /etc/syslog.d/, /etc/rsyslog.conf/, /etc/rsyslog.d/). See the following websites for more information:

    • images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/warning.svg Logging of the traces of the runtime system to syslog influences the behavior of the runtime system.

    • images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/warning.svg In case of SystemD based systems without installed Syslog service, it might be necessary to use journactl in order to display the output. The reason for this is because the above-mentioned files do not exist.

    Notes:

    • If the runtime system is started as SystemD service, it is not necessary to activate the logging via the syslog mechanism. The output is automatically saved in the SystemD journals. It is possible to display them by using the system-specific logging viewer (e.g. by journalctl --unit=logirts).

  3. Start the runtime system on the target system

    as described in the tutorials. Example: For Raspberry Pi, these instructions are listed under "Installing and starting logi.RTS on Raspberry Pi"
    .

images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/information.svg logi.cals recommends to install and use the most current versions of logi.CAD 3 and the runtime system so that the latest features and problem fixes according to the release notes are provided in the used version.


Did this article help you? Did you find the requested information in this user documentation?
If not, contact the support team of logi.cals. State your questions or suggestions to improve/enhance the user documentation as detailed as possible.