Code Monkey home page Code Monkey logo

phosphor-logging's Introduction

phosphor-logging

The phosphor logging repository provides mechanisms for event and journal logging.

Table Of Contents

To Build

To build this package, do the following steps:

  1. meson builddir
  2. ninja -c builddir

Structured Logging

phosphor-logging provides APIs to add program logging information to the systemd-journal and it is preferred that this logging data is formatted in a structured manner (using the facilities provided by the APIs).

See Structured Logging for more details on this API.

Event Logs

OpenBMC event logs are a collection of D-Bus interfaces owned by phosphor-log-manager that reside at /xyz/openbmc_project/logging/entry/X, where X starts at 1 and is incremented for each new log.

The interfaces are:

On platforms that make use of these event logs, the intent is that they are the common event log representation that other types of event logs can be created from. For example, there is code to convert these into both Redfish and IPMI event logs, in addition to the event log extensions mentioned below.

The logging daemon has the ability to add callout associations to an event log based on text in the AdditionalData property. A callout is a link to the inventory item(s) that were the cause of the event log. See here for details.

Creating Event Logs In Code

There are two approaches to creating event logs in OpenBMC code. The first makes use of the systemd journal to store metadata needed for the log, and the second is a plain D-Bus method call.

Journal Based Event Log Creation

Event logs can be created by using phosphor-logging APIs to commit sdbusplus exceptions. These APIs write to the journal, and then call a Commit D-Bus method on the logging daemon to create the event log using the information it put in the journal.

The APIs are found in <phosphor-logging/elog.hpp>:

  • elog(): Throw an sdbusplus error.
  • commit(): Catch an error thrown by elog(), and commit it to create the event log.
  • report(): Create an event log from an sdbusplus error without throwing the exception first.

Any errors passed into these APIs must be known to phosphor-logging, usually by being defined in <phosphor-logging/elog-errors.hpp>. The errors must also be known by sdbusplus, and be defined in their corresponding error.hpp. See below for details on how get errors into these headers.

Example:

#include <phosphor-logging/elog-errors.hpp>
#include <phosphor-logging/elog.hpp>
#include <xyz/openbmc_project/Common/error.hpp>
...
using InternalFailure =
    sdbusplus::xyz::openbmc_project::Common::Error::InternalFailure;
...
if (somethingBadHappened)
{
    phosphor::logging::report<InternalFailure>();
}

Alternatively, to throw, catch, and then commit the error:

try
{
    phosphor::logging::elog<InternalFailure>();
}
catch (InternalFailure& e)
{
    phosphor::logging::commit<InternalFailure>();
}

Metadata can be added to event logs to add debug data captured at the time of the event. It shows up in the AdditionalData property in the xyz.openbmc_project.Logging.Entry interface. Metadata is passed in via the elog() or report() functions, which write it to the journal. The metadata must be predefined for the error in the metadata YAML so that the daemon knows to look for it in the journal when it creates the event log.

Example:

#include <phosphor-logging/elog-errors.hpp>
#include <phosphor-logging/elog.hpp>
#include <xyz/openbmc_project/Control/Device/error.hpp>
...
using WriteFailure =
    sdbusplus::xyz::openbmc_project::Control::Device::Error::WriteFailure;
using metadata =
    xyz::openbmc_project::Control::Device::WriteFailure;
...
if (somethingBadHappened)
{
    phosphor::logging::report<WriteFailure>(metadata::CALLOUT_ERRNO(5),
                              metadata::CALLOUT_DEVICE_PATH("some path"));
}

In the above example, the AdditionalData property would look like:

["CALLOUT_ERRNO=5", "CALLOUT_DEVICE_PATH=some path"]

Note that the metadata fields must be all uppercase.

Event Log Definition

As mentioned above, both sdbusplus and phosphor-logging must know about the event logs in their header files, or the code that uses them will not even compile. The standard way to do this to define the event in the appropriate <error-category>.errors.yaml file, and define any metadata in the <error-category>.metadata.yaml file in the appropriate *-dbus-interfaces repository. During the build, phosphor-logging generates the elog-errors.hpp file for use by the calling code.

In much the same way, sdbusplus uses the event log definitions to generate an error.hpp file that contains the specific exception. The path of the error.hpp matches the path of the YAML file.

For example, if in phosphor-dbus-interfaces there is xyz/openbmc_project/Control/Device.errors.yaml, the errors that come from that file will be in the include: xyz/openbmc_project/Control/Device/error.hpp.

In rare cases, one may want one to define their errors in the same repository that uses them. To do that, one must:

  1. Add the error and metadata YAML files to the repository.
  2. Run the sdbus++ script within the makefile to create the error.hpp and .cpp files from the local YAML, and include the error.cpp file in the application that uses it. See openpower-occ-control for an example.
  3. Tell phosphor-logging about the error. This is done by either:
    • Following the directions defined in this README, or
    • Running the script yourself:
    1. Run phosphor-logging's elog-gen.py script on the local yaml to generate an elog-errors.hpp file that just contains the local errors, and check that into the repository and include it where the errors are needed.
    2. Create a recipe that copies the local YAML files to a place that phosphor-logging can find it during the build. See here for an example.

D-Bus Event Log Creation

There is also a D-Bus method to create event logs:

  • Service: xyz.openbmc_project.Logging
  • Object Path: /xyz/openbmc_project/logging
  • Interface: xyz.openbmc_project.Logging.Create
  • Method: Create
    • Method Arguments:
      • Message: The Message string property for the xyz.openbmc_project.Logging.Entry interface.
      • Severity: The severity property for the xyz.openbmc_project.Logging.Entry interface. An xyz.openbmc_project.Logging.Entry.Level enum value.
      • AdditionalData: The AdditionalData property for the xyz.openbmc_project.Logging.Entry interface, but in a map instead of in a vector of "KEY=VALUE" strings. Example:
    std::map<std::string, std::string> additionalData;
    additionalData["KEY"] = "VALUE";

Unlike the previous APIs where errors could also act as exceptions that could be thrown across D-Bus, this API does not require that the error be defined in the error YAML in the D-Bus interfaces repository so that sdbusplus knows about it. Additionally, as this method passes in everything needed to create the event log, the logging daemon doesn't have to know about it ahead of time either.

That being said, it is recommended that users of this API still follow some guidelines for the message field, which is normally generated from a combination of the path to the error YAML file and the error name itself. For example, the Timeout error in xyz/openbmc_project/Common.errors.yaml will have a Message property of xyz.openbmc_project.Common.Error.Timeout.

The guidelines are:

  1. When it makes sense, one can still use an existing error that has already been defined in an error YAML file, and use the same severity and metadata (AdditionalData) as in the corresponding metadata YAML file.

  2. If creating a new error, use the same naming scheme as other errors, which starts with the domain, xyz.openbmc_project, org.open_power, etc, followed by the capitalized category values, followed by Error, followed by the capitalized error name itself, with everything separated by "."s. For example: xyz.openbmc_project.Some.Category.Error.Name.

  3. If creating a new common error, still add it to the appropriate error and metadata YAML files in the appropriate D-Bus interfaces repository so that others can know about it and use it in the future. This can be done after the fact.

Adding application specific error YAML

  • This document captures steps for adding application specific error YAML files and generating local elog-errors.hpp header file for application use.
  • Should cater for continuous integration (CI) build, bitbake image build, and local repository build.

Continuous Integration (CI) build

  • Make is called on the repository that is modified.
  • Dependent packages are pulled based on the dependency list specified in the configure.ac script.

Recipe build

  • Native recipes copy error YAML files to shared location.
  • phosphor-logging builds elog-errors.hpp by parsing the error YAML files from the shared location.

Local repository build

  • Copies local error YAML files to the shared location in SDK
  • Make generates elog-errors.hpp by parsing the error YAML files from the shared location.

Makefile changes

Reference

Export error YAML to shared location
Modify Makefile.am to export newly added error YAML to shared location
yamldir = ${datadir}/phosphor-dbus-yaml/yaml
nobase_yaml_DATA = \
    org/open_power/Host.errors.yaml
Generate elog-errors.hpp using elog parser from SDK location
  • Add a conditional check "GEN_ERRORS"
  • Disable the check for recipe bitbake image build
  • Enable it for local repository build
  • If "GEN_ERRORS" is enabled, build generates elog-errors.hpp header file.
  # Generate phosphor-logging/elog-errors.hpp
  if GEN_ERRORS
  ELOG_MAKO ?= elog-gen-template.mako.hpp
  ELOG_DIR ?= ${OECORE_NATIVE_SYSROOT}${datadir}/phosphor-logging/elog
  ELOG_GEN_DIR ?= ${ELOG_DIR}/tools/
  ELOG_MAKO_DIR ?= ${ELOG_DIR}/tools/phosphor-logging/templates/
  YAML_DIR ?= ${OECORE_NATIVE_SYSROOT}${datadir}/phosphor-dbus-yaml/yaml
  phosphor-logging/elog-errors.hpp:
      @mkdir -p ${YAML_DIR}/org/open_power/
      @cp ${top_srcdir}/org/open_power/Host.errors.yaml \
        ${YAML_DIR}/org/open_power/Host.errors.yaml
      @mkdir -p `dirname $@`
      @chmod 777 $(ELOG_GEN_DIR)/elog-gen.py
      $(AM_V_at)$(PYTHON) $(ELOG_GEN_DIR)/elog-gen.py -y ${YAML_DIR} \
        -t ${ELOG_MAKO_DIR} -m ${ELOG_MAKO} -o $@
  endif
Update BUILT_SOURCES
  • Append elog-errors.hpp to BUILT_SOURCES list and put it in conditional check GEN_ERRORS so that the elog-errors.hpp is generated only during local repository build.
    if GEN_ERRORS
    nobase_nodist_include_HEADERS += \
                phosphor-logging/elog-errors.hpp
    endif
    if GEN_ERRORS
    BUILT_SOURCES += phosphor-logging/elog-errors.hpp
    endif
Conditional check for native build
  • As the same Makefile is used both for recipe image build and native recipe build, add a conditional to ensure that only installation of error yaml files happens during native build. It is not required to build repository during native build.
   if !INSTALL_ERROR_YAML
   endif

Autotools changes

Reference

Add option(argument) to enable/disable installing error yaml file
  • Install error yaml option(argument) is enabled for native recipe build and disabled for bitbake build.

  • When install error yaml option is disabled do not check for target specific packages in autotools configure script.

Add option(argument) to install error yaml files
AC_ARG_ENABLE([install_error_yaml],
    AS_HELP_STRING([--enable-install_error_yaml],
    [Enable installing error yaml file]),[], [install_error_yaml=no])
AM_CONDITIONAL([INSTALL_ERROR_YAML],
    [test "x$enable_install_error_yaml" = "xyes"])
AS_IF([test "x$enable_install_error_yaml" != "xyes"], [
..
..
])
Add option(argument) to enable/disable generating elog-errors header file
AC_ARG_ENABLE([gen_errors],
    AS_HELP_STRING([--enable-gen_errors], [Enable elog-errors.hpp generation ]),
    [],[gen_errors=yes])
AM_CONDITIONAL([GEN_ERRORS], [test "x$enable_gen_errors" != "xno"])

Recipe changes

Reference

Extend recipe for native and nativesdk
  • Extend the recipe for native and native SDK builds
BBCLASSEXTEND += "native nativesdk"
Remove dependencies for native and native SDK build
  • Native recipe caters only for copying error yaml files to shared location.
  • For native and native SDK build remove dependency on packages that recipe build depends
Remove dependency on phosphor-logging for native build
DEPENDS_remove_class-native = "phosphor-logging"
Remove dependency on phosphor-logging for native SDK build
DEPENDS_remove_class-nativesdk = "phosphor-logging"
Add install_error_yaml argument during native build
  • Add package config to enable/disable install_error_yaml feature.
Add package config to enable/disable install_error_yaml feature
PACKAGECONFIG ??= "install_error_yaml"
PACKAGECONFIG[install_error_yaml] = " \
        --enable-install_error_yaml, \
        --disable-install_error_yaml, ,\
        "
Enable install_error_yaml check for native build
PACKAGECONFIG_add_class-native = "install_error_yaml"
PACKAGECONFIG_add_class-nativesdk = "install_error_yaml"
Disable install_error_yaml during target build
PACKAGECONFIG_remove_class-target = "install_error_yaml"
Disable generating elog-errors.hpp for bitbake build
  • Disable gen_errors argument for bitbake image build as the application uses the elog-errors.hpp generated by phosphor-logging
  • Argument is enabled by default for local repository build in the configure script of the local repository.
 XTRA_OECONF += "--disable-gen_errors"

Local build

  • During local build use --prefix=/usr for the configure script.

Reference

Event Log Extensions

The extension concept is a way to allow code that creates other formats of error logs besides phosphor-logging's event logs to still reside in the phosphor-log-manager application.

The extension code lives in the extensions/<extension> subdirectories, and is enabled with a --enable-<extension> configure flag. The extension code won't compile unless enabled with this flag.

Extensions can register themselves to have functions called at the following points using the REGISTER_EXTENSION_FUNCTION macro.

  • On startup
    • Function type void(internal::Manager&)
  • After an event log is created
    • Function type void(args)
    • The args are:
      • const std::string& - The Message property
      • uin32_t - The event log ID
      • uint64_t - The event log timestamp
      • Level - The event level
      • const AdditionalDataArg& - the additional data
      • const AssociationEndpointsArg& - Association endpoints (callouts)
  • Before an event log is deleted, to check if it is allowed.
    • Function type void(std::uint32_t, bool&) that takes the event ID
  • After an event log is deleted
    • Function type void(std::uint32_t) that takes the event ID

Using these callback points, they can create their own event log for each OpenBMC event log that is created, and delete these logs when the corresponding OpenBMC event log is deleted.

In addition, an extension has the option of disabling phosphor-logging's default error log capping policy so that it can use its own. The macro DISABLE_LOG_ENTRY_CAPS() is used for that.

Motivation

The reason for adding support for extensions inside the phosphor-log-manager daemon as opposed to just creating new daemons that listen for D-Bus signals is to allow interactions that would be complicated or expensive if just done over D-Bus, such as:

  • Allowing for custom old log retention algorithms.
  • Prohibiting manual deleting of certain logs based on an extension's requirements.

Creating extensions

  1. Add a new flag to configure.ac to enable the extension:

    AC_ARG_ENABLE([foo-extension],
                  AS_HELP_STRING([--enable-foo-extension],
                                 [Create Foo logs]))
    AM_CONDITIONAL([ENABLE_FOO_EXTENSION],
                   [test "x$enable_foo_extension" == "xyes"])
  2. Add the code in extensions/<extension>/.

  3. Create a makefile include to add the new code to phosphor-log-manager:

    phosphor_log_manager_SOURCES += \
            extensions/foo/foo.cpp
  4. In extensions/extensions.mk, add the makefile include:

    if ENABLE_FOO_EXTENSION
    include extensions/foo/foo.mk
    endif
  5. In the extension code, register the functions to call and optionally disable log capping using the provided macros:

    DISABLE_LOG_ENTRY_CAPS();
    
    void fooStartup(internal::Manager& manager)
    {
        // Initialize
    }
    
    REGISTER_EXTENSION_FUNCTION(fooStartup);
    
    void fooCreate(const std::string& message, uint32_t id, uint64_t timestamp,
                    Entry::Level severity, const AdditionalDataArg& additionalData,
                    const AssociationEndpointsArg& assocs)
    {
        // Create a different type of error log based on 'entry'.
    }
    
    REGISTER_EXTENSION_FUNCTION(fooCreate);
    
    void fooRemove(uint32_t id)
    {
        // Delete the extension error log that corresponds to 'id'.
    }
    
    REGISTER_EXTENSION_FUNCTION(fooRemove);

Extension List

The supported extensions are:

  • OpenPower PELs
    • Enabled with --enable-openpower-pel-extension
    • Detailed information can be found here

Remote Logging via Rsyslog

The BMC has the ability to stream out local logs (that go to the systemd journal) via rsyslog (https://www.rsyslog.com/).

The BMC will send everything. Any kind of filtering and appropriate storage will have to be managed on the rsyslog server. Various examples are available on the internet. Here are few pointers : https://www.rsyslog.com/storing-and-forwarding-remote-messages/ https://www.rsyslog.com/doc/rsyslog%255Fconf%255Ffilter.html https://www.thegeekdiary.com/understanding-rsyslog-filter-options/

Configuring rsyslog server for remote logging

The BMC is an rsyslog client. To stream out logs, it needs to talk to an rsyslog server, to which there's connectivity over a network. REST API can be used to set the remote server's IP address and port number.

The following presumes a user has logged on to the BMC (see https://github.com/openbmc/docs/blob/master/rest-api.md).

Set the IP:

curl -b cjar -k -H "Content-Type: application/json" -X PUT \
    -d '{"data": <IP address>}' \
    https://<BMC IP address>/xyz/openbmc_project/logging/config/remote/attr/Address

Set the port:

curl -b cjar -k -H "Content-Type: application/json" -X PUT \
    -d '{"data": <port number>}' \
    https://<BMC IP address>/xyz/openbmc_project/logging/config/remote/attr/Port

Querying the current configuration

curl -b cjar -k \
    https://<BMC IP address>/xyz/openbmc_project/logging/config/remote

Setting the hostname

Rsyslog can store logs separately for each host. For this reason, it's useful to provide a unique hostname to each managed BMC. Here's how that can be done via a REST API :

curl -b cjar -k -H "Content-Type: application/json" -X PUT \
    -d '{"data": "myHostName"}' \
    https://<BMC IP address>//xyz/openbmc_project/network/config/attr/HostName

Disabling remote logging

Remote logging can be disabled by writing 0 to the port, or an empty string("") to the IP.

Changing the rsyslog server

When switching to a new server from an existing one (i.e the address, or port, or both change), it is recommended to disable the existing configuration first.

Boot Fail on Hardware Errors

phosphor-logging supports a setting, which when set, will result in the software looking at new phosphor-logging entries being created, and if a CALLOUT* is found within the entry, ensuring the system will not power on. Entries with severities of Informational or Debug will not block boots, even if they have callouts.

The full design for this can be found here

To enable this function:

busctl set-property xyz.openbmc_project.Settings /xyz/openbmc_project/logging/settings xyz.openbmc_project.Logging.Settings QuiesceOnHwError b true

To check if an entry is blocking the boot:

obmcutil listbootblock

Resolve or clear the corresponding entry to allow the system to boot.

phosphor-logging's People

Contributors

amboar avatar anoo1 avatar aryakpadman avatar bjwyman avatar deepakala-k avatar devenrao avatar dkodihal avatar geissonator avatar gtmills avatar harisuddin82 avatar lakshmi-y avatar leiyu-bytedance avatar lxwinspur avatar mikecgithub avatar msbarth avatar priyangaramasamy avatar pstrinkle avatar rameshiyyar avatar smccarney avatar sotaoverride avatar spinler avatar sumitk56 avatar sunnysrivastava1984 avatar swarnendu-r-c avatar vflobo avatar wak-google avatar williamspatrick avatar wrightjl1 avatar zamiseck avatar zane131 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

phosphor-logging's Issues

bench event log performance

I use the phosphor snmp trap to send event, and also adding event into logging service.
The event in my platform ast2520 and flash is SPI flash with 50MHz.
I stress the logging, it just can log 8 events in a second.
and when the event achieve to 3000 items, stop the event creation,
webbrowser need about 25 second to show the event and when the target running top during the web connect event log
page, sometimes it cannot display over 3 minutes.
the top can see the bmcweb and phosphor-logging have higher CPU usage.
and also each event occupied a file.
Does anyone have benchmark of this module ?

thanks

how to get elog param from dbus call

If dbus service trigger an elog such as: elog(NotAllowedReason("xxx")); in dbus method call
how to get the reason "xxx" from dbus method caller ?

Commits to phosphor-logger are slow

I've noticed a 5s+ delay for sending requests to the logger from ipmid, we need to look into ways for speeding this up because it causes unacceptable delays in the ipmi stack. Maybe prefer asynchronous requests as we don't need to block returning up the stack on error reporting.

TestLogManager.logCap fails when journal sync is enabled

With commit https://gerrit.openbmc-project.xyz/#/c/openbmc/phosphor-logging/+/12357/ , the journal sync function was fixed to run even when the synced file didn't exist. This causes the unit test that calls commit to fail.
It seems the journal sync interface was mocked to work with the unit test cases ( https://gerrit.openbmc-project.xyz/#/c/openbmc/phosphor-logging/+/11279/ ) but maybe something else is needed.

Error:

17:54:39 [ RUN      ] TestLogManager.logCap
17:54:39 unknown file: Failure
17:54:39 C++ exception with description "sd_bus_call: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.systemd1 was not provided by any .service files" thrown in the test body.
17:54:39 [  FAILED  ] TestLogManager.logCap (16 ms)

Install elog-gen.py using setuptools

This script and its template file are used by other repositories. Currently, it's just copied into $datadir. The right way to do it would be to make it a python module.

Failed to forward phosphor-host-state-manager to remote log server

# journalctl --no-pager | grep phosphor-host-state-manager
Sep 19 19:19:49 xx.xx.xx.xx phosphor-host-state-manager[1362]: Initial Host State will be Off
Sep 19 19:19:49 xx.xx.xx.xx phosphor-host-state-manager[1362]: External request to reset reboot count
Sep 19 19:21:33 xx.xx.xx.xx phosphor-host-state-manager[1362]: Host State transaction request
Sep 19 19:21:37 xx.xx.xx.xx phosphor-host-state-manager[1362]: External request to reset reboot count
Sep 19 19:21:53 xx.xx.xx.xx phosphor-host-state-manager[1362]: Received signal that host is running
Sep 19 19:21:53 xx.xx.xx.xx phosphor-host-state-manager[1362]: Change to Host State
Sep 19 19:23:18 xx.xx.xx.xx phosphor-host-state-manager[1362]: External request to reset reboot count
Sep 20 04:54:49 xx.xx.xx.xx phosphor-host-state-manager[1362]: Host State transaction request
Sep 20 04:54:56 xx.xx.xx.xx phosphor-host-state-manager[1362]: Received signal that host is off
Sep 20 04:54:56 xx.xx.xx.xx phosphor-host-state-manager[1362]: Change to Host State
Sep 20 04:59:56 xx.xx.xx.xx phosphor-host-state-manager[1362]: Host State transaction request
Sep 20 04:59:59 xx.xx.xx.xx phosphor-host-state-manager[1362]: Received signal that host is off
Sep 20 04:59:59 xx.xx.xx.xx phosphor-host-state-manager[1362]: Change to Host State
Sep 20 04:59:59 xx.xx.xx.xx phosphor-host-state-manager[1362]: External request to reset reboot count
Sep 20 05:00:13 xx.xx.xx.xx phosphor-host-state-manager[1362]: Received signal that host is running
Sep 20 05:00:13 xx.xx.xx.xx phosphor-host-state-manager[1362]: Change to Host State
Sep 20 05:01:29 xx.xx.xx.xx phosphor-host-state-manager[1362]: External request to reset reboot count

Not sure if its doing selectively but I don't see this forwarded to remote log server in the latest build

Remote Logging config not updated

On the latest build, configure the remote logging via REST interface and verify the /etc/rsyslog.d/server.conf config setting

$ ./rest_cmd -i wsbmcxxx-o GET -u /xyz/openbmc_project/logging/config/remote
Executing: GET  /xyz/openbmc_project/logging/config/remote

/xyz/openbmc_project/logging/config/remote
{
    "Address": "xx.xx.xx.xx",
    "Port": 514
}
Login to BMC and verify
root@wsbmcxxx:~# cat /etc/rsyslog.d/server.conf
# Remote Logging (we use TCP for reliable delivery)
#*.* @@remote-host:port

Don't see any failure or suspicious activity on journald to tell what went wrong there.

Missing Description , EventID in error logging

In latest Master build, noticed following fields Missing

"Description":
"EventID"
{
    "data": {
        "/xyz/openbmc_project/logging/entry/12": {
            "AdditionalData": [
                "CALLOUT_INVENTORY_PATH=/xyz/openbmc_project/inventory/system/chassis/motherboard/cpu1/core3",
                "ESEL=00 00 df 00 00 00 00 20 00 04 12 65 6f aa 00 00",
                "_PID=1564"
            ],
            "Id": 12,
            "Message": "org.open_power.Host.Error.Event",
            "Purpose": "xyz.openbmc_project.Software.Version.VersionPurpose.BMC",
            "Resolved": false,
            "Severity": "xyz.openbmc_project.Logging.Entry.Level.Error",
            "Timestamp": 1554282910336,
            "Version": "2.7.0-dev-272-g22235cbeb",
            "associations": [
                [
                    "callout",
                    "fault",
                    "/xyz/openbmc_project/inventory/system/chassis/motherboard/cpu1/core3"
                ]
            ]
        },
        "/xyz/openbmc_project/logging/entry/12/callout": {
            "endpoints": [
                "/xyz/openbmc_project/inventory/system/chassis/motherboard/cpu1/core3"
            ]
        }
    },
    "message": "200 OK",
    "status": "ok"
}

lg2 does not support sdbusplus::message::object_path type

Here is a piece of pseudo code:

sdbusplus::message::object_path objectPath;
... ...
info("objectPath: {PATH}", "PATH", objectPath);

When I compile, the error message is as follows:

In file included from /usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2.hpp:8,
                 from ../fault-monitor/fru-fault-monitor.cpp:6:
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp: In instantiation of ‘auto lg2::details::log_convert(const char*, lg2::details::log_flag<As ...>, T) [with Fs = {}; T = sdbusplus::message::details::string_path_wrapper]’:
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp:343:50:   required from ‘static void lg2::details::log_conversion::step(std::tuple<_Tps ...>&&, const lg2::details::header_str&, V&&, Ss&& ...) [with Ts = {lg2::level&, const std::source_location&, const char*&}; V = sdbusplus::message::details::string_path_wrapper&; Ss = {}]’
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp:387:17:   required from ‘static void lg2::details::log_conversion::start(lg2::level, const source_location&, const char*, Ts&& ...) [with Ts = {const lg2::details::header_str&, sdbusplus::message::details::string_path_wrapper&}; lg2::source_location = std::source_location]’
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2.hpp:29:39:   required from ‘lg2::log<S, Ts>::log(const source_location&, const char*, lg2::details::header_str_conversion_t<Ts&&>...) [with lg2::level S = lg2::level::info; Ts = {const char (&)[5], sdbusplus::message::details::string_path_wrapper&}; lg2::source_location = std::source_location]’
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2.hpp:43:80:   required from ‘lg2::log<S, Ts>::log(const char*, lg2::details::header_str_conversion_t<Ts&&>..., const source_location&) [with lg2::level S = lg2::level::info; Ts = {const char (&)[5], sdbusplus::message::details::string_path_wrapper&}; lg2::source_location = std::source_location]’
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2.hpp:85:1:   required from here
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp:71:19: error: static assertion failed: Unsupported type for logging value.
   71 |     static_assert(!std::is_same_v<T, T>, "Unsupported type for logging value.");
      |                   ^~~~~~~~~~~~~~~~~~~~~
/usr/local/rainier/sysroots/arm1176jzs-openbmc-linux-gnueabi/usr/include/phosphor-logging/lg2/conversion.hpp:71:19: note: ‘!(bool)std::is_same_v<sdbusplus::message::details::string_path_wrapper, sdbusplus::message::details::string_path_wrapper>’ evaluates to false

@williamspatrick Could you take a look this issue?

Rework passing the arguments to the generation script

Currently the YAML_DIR* variables are passed to the elog-gen.py via the configure.ac file. It would be a little cleaner to just not pass the argument to the python script in this case. Ex in PIM Makefile.am:

if IFACES_PATH
PIMGEN_ARGS=-i $(IFACES_PATH)
endif
generated.cpp:
$(AM_V_GEN)$(PYTHON) $(top_srcdir)/pimgen.py $(PIMGEN_ARGS) -d $(extra_yamldir)/.. -o $(builddir) generate-cpp

lg2 stderr output is too verbose

When a program is running interactively, the log messages are printed to stderr, which is a really nice valuable feature. But often the function names prefixed to each line are huge and obscure the actual content of the log message.

I would like to request that the default format in cerr_extra_output is changed to remove the function_name, or preferably, that extra_output_method is exposed outside the library so that the user can set their own function to do custom formatting.

Remote Logging API doesnt take hostname string as input

The Address "xx.xx.xx.xx" format works but not "myremotehost.xyz.com "

$ curl -c cjar -b cjar -k -H "Content-Type: application/json" -X POST https://$BMC_IP/login -d "{\"data\": [ \"root\", \"0penBmc\" ] }"
{
  "data": "User 'root' logged in",
  "message": "200 OK",
  "status": "ok"
}
$ curl -c cjar -b cjar -k -H "Content-Type: application/json" -X GET https://$BMC_IP/xyz/openbmc_project/logging/config/remote
{
  "data": {
    "Address": "0",
    "Port": 0
  },
  "message": "200 OK",
  "status": "ok"
}
$ curl -b cjar -k -H "Content-Type: application/json" -X PUT -d '{"data":"myremotehost.xyz.com"}' https://$BMC_IP/xyz/openbmc_project/logging/config/remote/attr/Address
{
  "data": {
    "description": "Internal Server Error",
    "exception": "DBusException('Invalid argument was given.',)",
    "traceback": [
      "Traceback (most recent call last):",
      "  File \"/usr/lib/python2.7/site-packages/bottle.py\", line 862, in _handle",
      "    return route.call(**args)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 1213, in __call__",
      "    return self.callback(*a, **kw)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 1278, in wrap",
      "    return callback(*a, **kw)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 1502, in __call__",
      "    return self.callback(*a, **kw)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 1476, in wrap",
      "    return self.to_jsonp(callback(*a, **kw))",
      "  File \"/usr/lib/python2.7/site-packages/bottle.py\", line 1742, in wrapper",
      "    rv = callback(*a, **ka)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 1440, in wrap",
      "    data = callback(*a, **kw)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 1329, in wrap",
      "    return callback(*a, **kw)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 1532, in __call__",
      "    resp = self.callback(*a, **kw)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 243, in __call__",
      "    return getattr(self, 'do_' + request.method.lower())(**kw)",
      "  File \"/usr/lib/python2.7/site-packages/obmc/wsgi/apps/rest_dbus.py\", line 498, in do_put",
      "    properties_iface.Set(iface, prop, value)",
      "  File \"/usr/lib/python2.7/site-packages/dbus/proxies.py\", line 145, in __call__",
      "    **keywords)",
      "  File \"/usr/lib/python2.7/site-packages/dbus/connection.py\", line 651, in call_blocking",
      "    message, timeout)",
      "DBusException: xyz.openbmc_project.Common.Error.InvalidArgument: Invalid argument was given."
    ]
  },
  "message": "500 Internal Server Error",
  "status": "error"
}

Fix a exception during De-Serialize

While trying to De-Serialize a Non-versioned Cereal object from a versioned Cereal code, saw that it raised std::length_error exception as opposed to a CerealException and that is indicating an issue in the code that handles the vectors. May be association ?

terminate called after throwing an instance of 'std::length_error'
  what():  vector::_M_default_append

See : USCiLab/cereal#192

Need a method to create an internal error in error logs

Need a method to create an internal error in error logs. This is required for dump testing. My main intention is to see a dump getting created once this entry is logged.

Development support for the dump to get created is already in place. All we need is a method to generate an internal error.

Error callout doesn't clear callout on setting Resolved to True

root@witherspoon:~# cat /etc/os-release
ID="openbmc-phosphor"
NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro)"
VERSION="2.6.0-rc1"
VERSION_ID="2.6.0-rc1-31-g0cab252"
PRETTY_NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro) 2.6.0-rc1"
BUILD_ID="2.6.0-rc1"
root@witherspoon:~#

Create error

/xyz/openbmc_project/logging/entry/enumerate
{
    "/xyz/openbmc_project/logging/entry/3": {
        "AdditionalData": [
            "_PID=2949",
            "CALLOUT_DEVICE_PATH_TEST=/sys/devices/platform/gpio-fsi/fsi0/slave@00:00/raw",
            "CALLOUT_ERRNO_TEST=0",
            "DEV_ADDR=0x0DEADEAD"
        ],
        "Description": "An internal BMC error occurred",
        "EventID": "None",
        "Id": 3,
        "Message": "example.xyz.openbmc_project.Example.Elog.TestCallout",
        "Purpose": "xyz.openbmc_project.Software.Version.VersionPurpose.BMC",
        "Resolved": false,    <-------------------------------------------------------
        "Severity": "xyz.openbmc_project.Logging.Entry.Level.Error",
        "Timestamp": 1547469601710,
        "Version": "2.6.0-rc1-31-g0cab252",
        "associations": [
            [
                "callout",
                "fault",
                "/xyz/openbmc_project/inventory/system/chassis/motherboard/cpu0"
            ]
        ]
    },
    "/xyz/openbmc_project/logging/entry/3/callout": {
        "endpoints": [
            "/xyz/openbmc_project/inventory/system/chassis/motherboard/cpu0"
        ]
    },
    "/xyz/openbmc_project/logging/entry/3/callouts": {},
    "/xyz/openbmc_project/logging/entry/3/callouts/0": {
        "BuildDate": "1996-01-01 - 00:00:00",
        "Manufacturer": "IBM",
        "Model": "",
        "PartNumber": "02CY211",
        "Path": "/xyz/openbmc_project/inventory/system/chassis/motherboard/cpu0",
        "SerialNumber": "YA1934302447"
    }
}

Set the Resolved Field to True, and expect callout to be cleared

}-bash-4.1$ curl -b cjar -k -H "Content-Type: application/json" -X PUT -d '{"data":1}' https://$BMC_IP/xyz/openbmc_project/logging/entry/3/attr/Resolved
{
  "data": null,
  "message": "200 OK",
  "status": "ok"
}-bash-4.1$ curl -b cjar -k -H "Content-Type: application/json" -XGET' https://$BMC_IP/xyz/openbmc_project/logging/entry/3/attr/Resolved
{
  "data": 1,
  "message": "200 OK",
  "status": "ok"
}-bash-4.1$

Enumerate logging and the callout is not cleared

/xyz/openbmc_project/logging/entry/enumerate
{
    "/xyz/openbmc_project/logging/entry/3": {
        "AdditionalData": [
            "_PID=2949",
            "CALLOUT_DEVICE_PATH_TEST=/sys/devices/platform/gpio-fsi/fsi0/slave@00:00/raw",
            "CALLOUT_ERRNO_TEST=0",
            "DEV_ADDR=0x0DEADEAD"
        ],
        "Description": "An internal BMC error occurred",
        "EventID": "None",
        "Id": 3,
        "Message": "example.xyz.openbmc_project.Example.Elog.TestCallout",
        "Purpose": "xyz.openbmc_project.Software.Version.VersionPurpose.BMC",
        "Resolved": true,    <-------------------------------------------------------
        "Severity": "xyz.openbmc_project.Logging.Entry.Level.Error",
        "Timestamp": 1547469601710,
        "Version": "2.6.0-rc1-31-g0cab252",
        "associations": []
    },
    "/xyz/openbmc_project/logging/entry/3/callout": {
        "endpoints": [
            "/xyz/openbmc_project/inventory/system/chassis/motherboard/cpu0"
        ]
    },
    "/xyz/openbmc_project/logging/entry/3/callouts": {},
    "/xyz/openbmc_project/logging/entry/3/callouts/0": {
        "BuildDate": "1996-01-01 - 00:00:00",
        "Manufacturer": "IBM",
        "Model": "",
        "PartNumber": "02CY211",
        "Path": "/xyz/openbmc_project/inventory/system/chassis/motherboard/cpu0",
        "SerialNumber": "YA1934302447"
    }
}

Build failed with gcc/g++ version 9.4.0 (Ubuntu 9.4.0-1ubuntu1~20.04.1)

Hi Folks,

Build failed with gcc/g++ version 9.4.0 (Ubuntu 9.4.0-1ubuntu1~20.04.1)

C++20 features are available since GCC 8. To enable C++20 support, add the command-line parameter -std=c++20 (use -std=c++2a in GCC 9 and earlier) to your g++ command line. Or, to enable GNU extensions in addition to C++20 features, add -std=gnu++20.

But I could not figure out where to give the flag. Please help to build.

msgubuntu@msgubuntu-OptiPlex-5000:~/vignesh/dbus/phosphor-logging$ ninja -C builddir
ninja: Entering directory `builddir'
[3/880] Compiling C++ object subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_event.cpp.o
FAILED: subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_event.cpp.o
c++ -Isubprojects/sdbusplus/libsdbusplus.so.1.0.0.p -Isubprojects/sdbusplus -I../subprojects/sdbusplus -I../subprojects/sdbusplus/include -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -Werror -std=c++2a -O2 -g -fPIC -MD -MQ subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_event.cpp.o -MF subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_event.cpp.o.d -o subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_event.cpp.o -c ../subprojects/sdbusplus/src/event.cpp
../subprojects/sdbusplus/src/event.cpp: In member function ‘sdbusplus::event::source sdbusplus::event::event::add_oneshot_timer(sd_event_time_handler_t, void*, sdbusplus::event::event::time_resolution, sdbusplus::event::event::time_resolution)’:
../subprojects/sdbusplus/src/event.cpp:156:15: error: ‘sd_event_add_time_relative’ was not declared in this scope; did you mean ‘sd_event_add_time’?
156 | auto rc = sd_event_add_time_relative(eventp, &s.sourcep, CLOCK_BOOTTIME,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
| sd_event_add_time
[7/880] Compiling C++ object subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_bus.cpp.o
FAILED: subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_bus.cpp.o
c++ -Isubprojects/sdbusplus/libsdbusplus.so.1.0.0.p -Isubprojects/sdbusplus -I../subprojects/sdbusplus -I../subprojects/sdbusplus/include -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -Wpedantic -Werror -std=c++2a -O2 -g -fPIC -MD -MQ subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_bus.cpp.o -MF subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_bus.cpp.o.d -o subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_bus.cpp.o -c ../subprojects/sdbusplus/src/bus.cpp
In file included from ../subprojects/sdbusplus/include/sdbusplus/message.hpp:6,
from ../subprojects/sdbusplus/include/sdbusplus/bus.hpp:7,
from ../subprojects/sdbusplus/src/bus.cpp:1:
../subprojects/sdbusplus/include/sdbusplus/message/append.hpp: In static member function ‘static void sdbusplus::message::details::append_single<std::basic_string_view >::op(sdbusplus::SdBusInterface*, sd_bus_message*, T&&)’:
../subprojects/sdbusplus/include/sdbusplus/message/append.hpp:225:24: error: ‘bit_cast’ is not a member of ‘std’; did you mean ‘bad_cast’?
225 | iovec iov{std::bit_cast<void*>(s.data()), s.size()};
| ^~~~~~~~
| bad_cast
../subprojects/sdbusplus/include/sdbusplus/message/append.hpp:225:33: error: expected primary-expression before ‘void’
225 | iovec iov{std::bit_cast<void*>(s.data()), s.size()};
| ^~~~
../subprojects/sdbusplus/include/sdbusplus/message/append.hpp:225:33: error: expected ‘}’ before ‘void’
../subprojects/sdbusplus/include/sdbusplus/message/append.hpp:225:33: error: expected ‘,’ or ‘;’ before ‘void’
[8/880] Compiling C++ object subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_server_interface.cpp.o
FAILED: subprojects/sdbusplus/libsdbusplus.so.1.0.0.p/src_server_interface.cpp.o

Regards,
Vignesh

Compile error: namespace does not have a type

While building this subproject for service-config-manager this error occured:

FAILED: subprojects/phosphor-logging/phosphor-rsyslog-config/phosphor-rsyslog-conf.p/meson-generated_.._.._elog-process-metadata.cpp.o
ccache c++ -Isubprojects/phosphor-logging/phosphor-rsyslog-config/phosphor-rsyslog-conf.p -Isubprojects/phosphor-logging/phosphor-rsyslog-config -I../subprojects/phosphor-logging/phosphor-rsyslog-config -Isubprojects/phosphor-logging -I../subprojects/phosphor-logging -Isubprojects/phosphor-dbus-interfaces/gen -I../subprojects/phosphor-dbus-interfaces/gen -I../subprojects/sdbusplus/include -Isubprojects/sdeventplus/src -I../subprojects/sdeventplus/src -Isubprojects/stdplus/src -I../subprojects/stdplus/src -I../subprojects/span-lite/include -Isubprojects/span-lite/__CMake_build -I../subprojects/span-lite/__CMake_build -Isubprojects/span-lite -I../subprojects/span-lite -I../subprojects/function2/include -Isubprojects/function2/__CMake_build -I../subprojects/function2/__CMake_build -Isubprojects/function2 -I../subprojects/function2 -Isubprojects/phosphor-logging/phosphor-logging -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wnon-virtual-dtor -Wextra -Wpedantic -Werror -std=c++17 -g -MD -MQ subprojects/phosphor-logging/phosphor-rsyslog-config/phosphor-rsyslog-conf.p/meson-generated_.._.._elog-process-metadata.cpp.o -MF subprojects/phosphor-logging/phosphor-rsyslog-config/phosphor-rsyslog-conf.p/meson-generated_.._.._elog-process-metadata.cpp.o.d -o subprojects/phosphor-logging/phosphor-rsyslog-config/phosphor-rsyslog-conf.p/meson-generated_.._.._elog-process-metadata.cpp.o -c subprojects/phosphor-logging/elog-process-metadata.cpp
In file included from subprojects/phosphor-logging/elog-process-metadata.cpp:7:
subprojects/phosphor-logging/phosphor-logging/elog-errors.hpp:2408:31: error: 'example' in namespace 'phosphor::logging::subprojects' does not name a type
 2408 |     using type = subprojects::example::net::poettering::Calculator::DivisionByZero;
      |                               ^~~~~~~
subprojects/phosphor-logging/phosphor-logging/elog-errors.hpp:2452:31: error: 'example' in namespace 'phosphor::logging::subprojects' does not name a type
 2452 |     using type = subprojects::example::net::poettering::Calculator::PermissionDenied;
      |                               ^~~~~~~

GCC

> gcc --version
gcc (GCC) 11.1.0
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

syslog.socket: Failed with result 'trigger-limit-hit'.

Build: https://openpower.xyz/job/openbmc-build/1927/

BMC Firmware level:

ID="openbmc-phosphor"
NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro)"
VERSION="2.6.0-rc1"
VERSION_ID="2.6.0-rc1-31-g0cab252"
PRETTY_NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro) 2.6.0-rc1"
BUILD_ID="2.6.0-rc1"

Journald snippet

Jan 14 08:35:23 witherspoon systemd[1]: syslog.socket: Trigger limit hit, refusing further activation.
Jan 14 08:35:23 witherspoon systemd[1]: syslog.socket: Failed with result 'trigger-limit-hit'.
root@witherspoon:~# systemctl status syslog.socket | cat
● syslog.socket - Syslog Socket
   Loaded: loaded (/lib/systemd/system/syslog.socket; static; vendor preset: disabled)
   Active: failed (Result: trigger-limit-hit) since Mon 2019-01-14 08:50:34 UTC; 15min ago
     Docs: man:systemd.special(7)
           https://www.freedesktop.org/wiki/Software/systemd/syslog
   Listen: /run/systemd/journal/syslog (Datagram)

Jan 14 08:50:34 witherspoon systemd[1]: Listening on Syslog Socket.
Jan 14 08:50:34 witherspoon systemd[1]: syslog.socket: Trigger limit hit, refusing further activation.
Jan 14 08:50:34 witherspoon systemd[1]: syslog.socket: Failed with result 'trigger-limit-hit'.
root@witherspoon:~#
```

This is a pervasive failure and seen on Witherspoon / Romulus and likely on other as well.

This has an impact on rsyslog module and probably because of this even when the config was created the server config file is not created by the app

```
cat: can't open '/etc/rsyslog.d/server.conf': No such file or directory
``` 

phosphor-log-manager: Failed to find metadata

-bash-4.1$ ./rest_cmd -i wsbmcxxx-o esel
Fetching esel from BMC
Error entry(s) found:
[u'/xyz/openbmc_project/logging/entry/13']
Entry : /xyz/openbmc_project/logging/entry/13
{
    "AdditionalData": [
        "_PID=1363"
    ],
    "Description": "An internal failure has occurred while performing an operation.",
    "EventID": "FQPSPCR0021F",
    "Id": 13,
    "Message": "xyz.openbmc_project.Common.Error.InternalFailure",
    "Purpose": "xyz.openbmc_project.Software.Version.VersionPurpose.BMC",
    "Resolved": false,
    "Severity": "xyz.openbmc_project.Logging.Entry.Level.Error",
    "Timestamp": 1536073149893,
    "Version": "v2.3-240-g40c4f35",
    "associations": []
}
looks like i m seeing this on poweron and off.. 

Sep 04 14:59:09 wsbmcxxx phosphor-log-manager[1158]: Failed to find metadata
Sep 04 14:59:09 wsbmcxxx phosphor-fru-fault-monitor[1362]: /xyz/openbmc_project/logging/entry/13 created```


Adriana Kobylak [20:37]
to workaround this issue, issue a “journalctl --sync” to create the file and sync the journal so that we don’t have missing metadata, until i get the fix up

rsyslog.service: Main process exited, code=exited, status=1/FAILURE

On latest yacto 2.6 build
root@witherspoon:~# cat /etc/os-release
ID="openbmc-phosphor"
NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro)"
VERSION="v2.4-247"
VERSION_ID="v2.4-247-g1a4b7ee"
PRETTY_NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro) v2.4-247"
BUILD_ID="v2.4"

Remote logging server crashed out

Jan 09 07:42:07 witherspoon systemd[1]: rsyslog.service: Scheduled restart job, restart counter is at 670.
Jan 09 07:42:07 witherspoon systemd[1]: Stopped System Logging Service.
Jan 09 07:42:07 witherspoon systemd[1]: Starting System Logging Service...
Jan 09 07:42:07 witherspoon systemd[1]: rsyslog.service: Main process exited, code=exited, status=1/FAILURE
Jan 09 07:42:07 witherspoon systemd[1]: rsyslog.service: Failed with result 'exit-code'.
Jan 09 07:42:07 witherspoon systemd[1]: Failed to start System Logging Service.
Jan 09 07:42:08 witherspoon systemd[1]: rsyslog.service: Service RestartSec=1s expired, scheduling restart.
Jan 09 07:42:08 witherspoon systemd[1]: rsyslog.service: Scheduled restart job, restart counter is at 671.
Jan 09 07:42:08 witherspoon systemd[1]: Stopped System Logging Service.
Jan 09 07:42:08 witherspoon systemd[1]: Starting System Logging Service...
Jan 09 07:42:08 witherspoon systemd[1]: rsyslog.service: Main process exited, code=exited, status=1/FAILURE
Jan 09 07:42:08 witherspoon systemd[1]: rsyslog.service: Failed with result 'exit-code'.
Jan 09 07:42:08 witherspoon systemd[1]: Failed to start System Logging Service.
root@witherspoon:~# systemctl status rsyslog.service | cat
● rsyslog.service - System Logging Service
   Loaded: loaded (/lib/systemd/system/rsyslog.service; enabled; vendor preset: enabled)
  Drop-In: /lib/systemd/system/rsyslog.service.d
           └─rsyslog-override.conf
   Active: activating (auto-restart) (Result: exit-code) since Wed 2019-01-09 07:40:31 UTC; 246ms ago
     Docs: man:rsyslogd(8)
           http://www.rsyslog.com/doc/
  Process: 2487 ExecStart=/usr/sbin/rsyslogd -n -iNONE (code=exited, status=1/FAILURE)
 Main PID: 2487 (code=exited, status=1/FAILURE)
root@witherspoon:~#

Rework the generation script so that the output headers are added to the build tree

Currently the Makefile.am calls elog-gen.py and redirects the output (generated header files) to the sources tree.
Instead of redirecting the output, the generated header files should go into the build tree instead.
Per Brad: 'it doesn't seem appropriate to be directing output of the script to the source tree. maybe open an issue to rework later so that it goes to the build tree.'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.