Openbmc archive at lore.kernel.org
 help / color / Atom feed
* Request to create repository google-ipmi-bmc-health
@ 2020-09-30 15:27 Sui Chen
  2020-10-01 19:05 ` Vijay Khemka
  0 siblings, 1 reply; 6+ messages in thread
From: Sui Chen @ 2020-09-30 15:27 UTC (permalink / raw)
  To: OpenBMC Maillist

Hello OpenBMC community,

We are working on an IPMI blob-based implementation of BMC health
monitoring. We currently have an internal working prototype version
and would like to upload it to this newly proposed repository,
openbmc/google-ipmi-bmc-health .

We are aware of existing BMC health monitoring designs such as:
1. https://github.com/openbmc/phosphor-health-monitor and its
documentation https://gerrit.openbmc-project.xyz/c/openbmc/docs/+/31957
2. https://gerrit.openbmc-project.xyz/c/openbmc/docs/+/34766

Main differences between this implementation and existing ones are:
- google-ipmi-bmc-health is implemented with the IPMI blob handler
framework and exists as an IPMI blob handler, while
phosphor-health-monitor runs as a daemon and exposes BMC health
metrics on DBus in the same manner sensors are exposed.
- This implementation does not check health metric values against
thresholds or perform actions when thresholds are crossed.
- This implementation currently reports uptime, memory usage, free
disk space, CPU time consumed by processes, and file descriptor stats.
- This implementation does not read a configuration file yet. It
always reads the hard-coded set of health metrics listed above.
- This implementation does not post-process sensor readings such as
compute the average CPU usage over a certain time window.

As such, this implementation differs enough from existing ones such
that we believe we have enough reasons to have a separate repository
for it.

Thanks!

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Request to create repository google-ipmi-bmc-health
  2020-09-30 15:27 Request to create repository google-ipmi-bmc-health Sui Chen
@ 2020-10-01 19:05 ` Vijay Khemka
  2020-10-02  1:52   ` Sui Chen
  0 siblings, 1 reply; 6+ messages in thread
From: Vijay Khemka @ 2020-10-01 19:05 UTC (permalink / raw)
  To: Sui Chen, OpenBMC Maillist

Hi Sui,

On 9/30/20, 8:30 AM, "openbmc on behalf of Sui Chen" <openbmc-bounces+vijaykhemka=fb.com@lists.ozlabs.org on behalf of suichen@google.com> wrote:

    Hello OpenBMC community,

    We are working on an IPMI blob-based implementation of BMC health
    monitoring. We currently have an internal working prototype version
    and would like to upload it to this newly proposed repository,
    openbmc/google-ipmi-bmc-health .

In my opinion, we can enhance existing health-monitor and add your features.

    We are aware of existing BMC health monitoring designs such as:
    1. https://github.com/openbmc/phosphor-health-monitor and its
    documentation https://urldefense.proofpoint.com/v2/url?u=https-3A__gerrit.openbmc-2Dproject.xyz_c_openbmc_docs_-2B_31957&d=DwIBaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=v9MU0Ki9pWnTXCWwjHPVgpnCR80vXkkcrIaqU7USl5g&m=Z-_Rsue1ZHBD_TgPw7EDIc8dh8E8o8dlUe8aKr7I5VA&s=HTKEM8tcIgwzwL4OQVP1Kcve6ZfnhSTohdwPmIrjwe4&e= 
    2. https://urldefense.proofpoint.com/v2/url?u=https-3A__gerrit.openbmc-2Dproject.xyz_c_openbmc_docs_-2B_34766&d=DwIBaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=v9MU0Ki9pWnTXCWwjHPVgpnCR80vXkkcrIaqU7USl5g&m=Z-_Rsue1ZHBD_TgPw7EDIc8dh8E8o8dlUe8aKr7I5VA&s=EcxSrU1PC6Akfy1FR0wo-5TC_QvMld9SDT7pJAh5QcM&e= 

    Main differences between this implementation and existing ones are:
    - google-ipmi-bmc-health is implemented with the IPMI blob handler
    framework and exists as an IPMI blob handler, while
    phosphor-health-monitor runs as a daemon and exposes BMC health
    metrics on DBus in the same manner sensors are exposed.

Is this going to be a library or daemon, Same health-monitor daemon can 
Be enhanced to add these functionalities.

    - This implementation does not check health metric values against
    thresholds or perform actions when thresholds are crossed.

If you don't define threshold in configuration file, health-monitor will
also not monitor metrics defined.

    - This implementation currently reports uptime, memory usage, free
    disk space, CPU time consumed by processes, and file descriptor stats.

Same can be added as extra metrics. That was the goal of this repo as to
start with basic metrics and add more as required.

    - This implementation does not read a configuration file yet. It
    always reads the hard-coded set of health metrics listed above.

We can enable or disable certain metrics through this configuration file.

    - This implementation does not post-process sensor readings such as
    compute the average CPU usage over a certain time window.

Window size 1 can give latest data rather than averaged data.

    As such, this implementation differs enough from existing ones such
    that we believe we have enough reasons to have a separate repository
    for it.

I will strongly prefer to add all of the features in the existing repo.

    Thanks!


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Request to create repository google-ipmi-bmc-health
  2020-10-01 19:05 ` Vijay Khemka
@ 2020-10-02  1:52   ` Sui Chen
  2020-10-02 20:54     ` Vijay Khemka
  0 siblings, 1 reply; 6+ messages in thread
From: Sui Chen @ 2020-10-02  1:52 UTC (permalink / raw)
  To: Vijay Khemka; +Cc: OpenBMC Maillist

Hi Vijay,

We can use whatever means that gets health monitoring done.
I have the following questions on how to merge the proposed IPMI
Blob-based implementation, google-ipmi-bmc-health (referred to as
"IPMI health blob") with phosphor-health-monitor. The intent of having
a separate "google-ipmi-bmc-health" was to avoid these questions:

1) The IPMI health blob is a library, not a daemon, so after the IPMI
health blob is added, phosphor-health-monitor will have both a library
and a daemon. The user needs to have a way to configure it. What is
the recommended way of doing this configuration?

2) We are sending a protocol buffer through the IPMI interface to the
BMC, and the protocol buffer may be only used for the IPMI path and
not anywhere else. Would there be any concerns on the usage of a
protocol buffer here?

Other than these two things I think adding new metrics to
phosphor-health-monitor should be manageable. I can start by trying to
add the IPMI blob handler to phosphor-health-monitor; my first attempt
might not look very elegant, but if we find answers to the two
questions above, the merged result will look a lot better. Hopefully
we can find a solution that works well for everyone.

Thanks,
Sui

On Thu, Oct 1, 2020 at 12:06 PM Vijay Khemka <vijaykhemka@fb.com> wrote:
>
> Hi Sui,
>
> On 9/30/20, 8:30 AM, "openbmc on behalf of Sui Chen" <openbmc-bounces+vijaykhemka=fb.com@lists.ozlabs.org on behalf of suichen@google.com> wrote:
>
>     Hello OpenBMC community,
>
>     We are working on an IPMI blob-based implementation of BMC health
>     monitoring. We currently have an internal working prototype version
>     and would like to upload it to this newly proposed repository,
>     openbmc/google-ipmi-bmc-health .
>
> In my opinion, we can enhance existing health-monitor and add your features.
>
>     We are aware of existing BMC health monitoring designs such as:
>     1. https://github.com/openbmc/phosphor-health-monitor and its
>     documentation https://urldefense.proofpoint.com/v2/url?u=https-3A__gerrit.openbmc-2Dproject.xyz_c_openbmc_docs_-2B_31957&d=DwIBaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=v9MU0Ki9pWnTXCWwjHPVgpnCR80vXkkcrIaqU7USl5g&m=Z-_Rsue1ZHBD_TgPw7EDIc8dh8E8o8dlUe8aKr7I5VA&s=HTKEM8tcIgwzwL4OQVP1Kcve6ZfnhSTohdwPmIrjwe4&e=
>     2. https://urldefense.proofpoint.com/v2/url?u=https-3A__gerrit.openbmc-2Dproject.xyz_c_openbmc_docs_-2B_34766&d=DwIBaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=v9MU0Ki9pWnTXCWwjHPVgpnCR80vXkkcrIaqU7USl5g&m=Z-_Rsue1ZHBD_TgPw7EDIc8dh8E8o8dlUe8aKr7I5VA&s=EcxSrU1PC6Akfy1FR0wo-5TC_QvMld9SDT7pJAh5QcM&e=
>
>     Main differences between this implementation and existing ones are:
>     - google-ipmi-bmc-health is implemented with the IPMI blob handler
>     framework and exists as an IPMI blob handler, while
>     phosphor-health-monitor runs as a daemon and exposes BMC health
>     metrics on DBus in the same manner sensors are exposed.
>
> Is this going to be a library or daemon, Same health-monitor daemon can
> Be enhanced to add these functionalities.
>
>     - This implementation does not check health metric values against
>     thresholds or perform actions when thresholds are crossed.
>
> If you don't define threshold in configuration file, health-monitor will
> also not monitor metrics defined.
>
>     - This implementation currently reports uptime, memory usage, free
>     disk space, CPU time consumed by processes, and file descriptor stats.
>
> Same can be added as extra metrics. That was the goal of this repo as to
> start with basic metrics and add more as required.
>
>     - This implementation does not read a configuration file yet. It
>     always reads the hard-coded set of health metrics listed above.
>
> We can enable or disable certain metrics through this configuration file.
>
>     - This implementation does not post-process sensor readings such as
>     compute the average CPU usage over a certain time window.
>
> Window size 1 can give latest data rather than averaged data.
>
>     As such, this implementation differs enough from existing ones such
>     that we believe we have enough reasons to have a separate repository
>     for it.
>
> I will strongly prefer to add all of the features in the existing repo.
>
>     Thanks!
>

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Request to create repository google-ipmi-bmc-health
  2020-10-02  1:52   ` Sui Chen
@ 2020-10-02 20:54     ` Vijay Khemka
  2020-10-06 22:57       ` Sui Chen
  0 siblings, 1 reply; 6+ messages in thread
From: Vijay Khemka @ 2020-10-02 20:54 UTC (permalink / raw)
  To: Sui Chen; +Cc: OpenBMC Maillist

Hi Sui,

On 10/1/20, 6:52 PM, "Sui Chen" <suichen@google.com> wrote:

    Hi Vijay,

    We can use whatever means that gets health monitoring done.
    I have the following questions on how to merge the proposed IPMI
    Blob-based implementation, google-ipmi-bmc-health (referred to as
    "IPMI health blob") with phosphor-health-monitor. The intent of having
    a separate "google-ipmi-bmc-health" was to avoid these questions:

    1) The IPMI health blob is a library, not a daemon, so after the IPMI
    health blob is added, phosphor-health-monitor will have both a library
    and a daemon. The user needs to have a way to configure it. What is
    the recommended way of doing this configuration?

Yes the same repo can generate library as well as daemon. Currently it is
configuring 2 metrics cpu and memory, we can add another entry like
IPMI blob and if it is there then only it will build ipmi blobs.

    2) We are sending a protocol buffer through the IPMI interface to the
    BMC, and the protocol buffer may be only used for the IPMI path and
    not anywhere else. Would there be any concerns on the usage of a
    protocol buffer here?

If I understand correctly, protocol buffer will be used by daemon who
Is responding to the IPMI request and connecting to this daemon via
library call, then it is completely restricted for the use of protocol buffer.
If you are passing protocol buffer to this daemon then we have to define
some policy here. 

    Other than these two things I think adding new metrics to
    phosphor-health-monitor should be manageable. I can start by trying to
    add the IPMI blob handler to phosphor-health-monitor; my first attempt
    might not look very elegant, but if we find answers to the two
    questions above, the merged result will look a lot better. Hopefully
    we can find a solution that works well for everyone.

I am looking forward to your patches

    Thanks,
    Sui

    On Thu, Oct 1, 2020 at 12:06 PM Vijay Khemka <vijaykhemka@fb.com> wrote:
    >
    > Hi Sui,
    >
    > On 9/30/20, 8:30 AM, "openbmc on behalf of Sui Chen" <openbmc-bounces+vijaykhemka=fb.com@lists.ozlabs.org on behalf of suichen@google.com> wrote:
    >
    >     Hello OpenBMC community,
    >
    >     We are working on an IPMI blob-based implementation of BMC health
    >     monitoring. We currently have an internal working prototype version
    >     and would like to upload it to this newly proposed repository,
    >     openbmc/google-ipmi-bmc-health .
    >
    > In my opinion, we can enhance existing health-monitor and add your features.
    >
    >     We are aware of existing BMC health monitoring designs such as:
    >     1. https://github.com/openbmc/phosphor-health-monitor and its
    >     documentation https://urldefense.proofpoint.com/v2/url?u=https-3A__gerrit.openbmc-2Dproject.xyz_c_openbmc_docs_-2B_31957&d=DwIBaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=v9MU0Ki9pWnTXCWwjHPVgpnCR80vXkkcrIaqU7USl5g&m=Z-_Rsue1ZHBD_TgPw7EDIc8dh8E8o8dlUe8aKr7I5VA&s=HTKEM8tcIgwzwL4OQVP1Kcve6ZfnhSTohdwPmIrjwe4&e=
    >     2. https://urldefense.proofpoint.com/v2/url?u=https-3A__gerrit.openbmc-2Dproject.xyz_c_openbmc_docs_-2B_34766&d=DwIBaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=v9MU0Ki9pWnTXCWwjHPVgpnCR80vXkkcrIaqU7USl5g&m=Z-_Rsue1ZHBD_TgPw7EDIc8dh8E8o8dlUe8aKr7I5VA&s=EcxSrU1PC6Akfy1FR0wo-5TC_QvMld9SDT7pJAh5QcM&e=
    >
    >     Main differences between this implementation and existing ones are:
    >     - google-ipmi-bmc-health is implemented with the IPMI blob handler
    >     framework and exists as an IPMI blob handler, while
    >     phosphor-health-monitor runs as a daemon and exposes BMC health
    >     metrics on DBus in the same manner sensors are exposed.
    >
    > Is this going to be a library or daemon, Same health-monitor daemon can
    > Be enhanced to add these functionalities.
    >
    >     - This implementation does not check health metric values against
    >     thresholds or perform actions when thresholds are crossed.
    >
    > If you don't define threshold in configuration file, health-monitor will
    > also not monitor metrics defined.
    >
    >     - This implementation currently reports uptime, memory usage, free
    >     disk space, CPU time consumed by processes, and file descriptor stats.
    >
    > Same can be added as extra metrics. That was the goal of this repo as to
    > start with basic metrics and add more as required.
    >
    >     - This implementation does not read a configuration file yet. It
    >     always reads the hard-coded set of health metrics listed above.
    >
    > We can enable or disable certain metrics through this configuration file.
    >
    >     - This implementation does not post-process sensor readings such as
    >     compute the average CPU usage over a certain time window.
    >
    > Window size 1 can give latest data rather than averaged data.
    >
    >     As such, this implementation differs enough from existing ones such
    >     that we believe we have enough reasons to have a separate repository
    >     for it.
    >
    > I will strongly prefer to add all of the features in the existing repo.
    >
    >     Thanks!
    >


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Request to create repository google-ipmi-bmc-health
  2020-10-02 20:54     ` Vijay Khemka
@ 2020-10-06 22:57       ` Sui Chen
  2020-10-07  1:43         ` Patrick Williams
  0 siblings, 1 reply; 6+ messages in thread
From: Sui Chen @ 2020-10-06 22:57 UTC (permalink / raw)
  To: Vijay Khemka; +Cc: OpenBMC Maillist

On Fri, Oct 2, 2020 at 1:54 PM Vijay Khemka <vijaykhemka@fb.com> wrote:
>
> Hi Sui,
>
> On 10/1/20, 6:52 PM, "Sui Chen" <suichen@google.com> wrote:
>
>     Hi Vijay,
>
>     We can use whatever means that gets health monitoring done.
>     I have the following questions on how to merge the proposed IPMI
>     Blob-based implementation, google-ipmi-bmc-health (referred to as
>     "IPMI health blob") with phosphor-health-monitor. The intent of having
>     a separate "google-ipmi-bmc-health" was to avoid these questions:
>
>     1) The IPMI health blob is a library, not a daemon, so after the IPMI
>     health blob is added, phosphor-health-monitor will have both a library
>     and a daemon. The user needs to have a way to configure it. What is
>     the recommended way of doing this configuration?
>
> Yes the same repo can generate library as well as daemon. Currently it is
> configuring 2 metrics cpu and memory, we can add another entry like
> IPMI blob and if it is there then only it will build ipmi blobs.
>
>     2) We are sending a protocol buffer through the IPMI interface to the
>     BMC, and the protocol buffer may be only used for the IPMI path and
>     not anywhere else. Would there be any concerns on the usage of a
>     protocol buffer here?
>
> If I understand correctly, protocol buffer will be used by daemon who
> Is responding to the IPMI request and connecting to this daemon via
> library call, then it is completely restricted for the use of protocol buffer.
> If you are passing protocol buffer to this daemon then we have to define
> some policy here.

The Protocol buffer is only for serializing the data to be sent
outside of the BMC. It is not used for communication inside
phosphor-health-monitor and will not be passed to the daemon.

>
>     Other than these two things I think adding new metrics to
>     phosphor-health-monitor should be manageable. I can start by trying to
>     add the IPMI blob handler to phosphor-health-monitor; my first attempt
>     might not look very elegant, but if we find answers to the two
>     questions above, the merged result will look a lot better. Hopefully
>     we can find a solution that works well for everyone.
>
> I am looking forward to your patches

Please check out this WIP:
https://gerrit.openbmc-project.xyz/c/openbmc/phosphor-health-monitor/+/37092

This WIP currently just adds the IPMI blob-based code to
phosphor-health-monitor almost as-is.
It also shows what we already have now.

There will be some work to merge the daemon and the blob handler in an
organic way, and I am open to discussion with you how to do that. The
first step I think I can do is to put the code for extracting the
metrics (metrics.cpp, blob/metric.cpp) into a single file and share
that between the daemon and the IPMI blob handler.

Another issue I found is I am not using the latest sdbusplus so I have
to comment out the usage of ValueIface::Unit::Percent for now.

To build this requires 1) adding a pkgconfig file to
phosphor-ipmi-blobs (before
https://gerrit.openbmc-project.xyz/c/openbmc/phosphor-ipmi-blobs/+/37133
gets merged) and 2) adding phosphor-ipmi-blobs and protobuf to DEPENDS
in phosphor-health-monitor's Bitbake recipe.

Hope this WIP change illustrates our intention clearly.

Thanks!

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Request to create repository google-ipmi-bmc-health
  2020-10-06 22:57       ` Sui Chen
@ 2020-10-07  1:43         ` Patrick Williams
  0 siblings, 0 replies; 6+ messages in thread
From: Patrick Williams @ 2020-10-07  1:43 UTC (permalink / raw)
  To: Sui Chen; +Cc: OpenBMC Maillist, Vijay Khemka


[-- Attachment #1: Type: text/plain, Size: 2515 bytes --]

On Tue, Oct 06, 2020 at 03:57:30PM -0700, Sui Chen wrote:
> On Fri, Oct 2, 2020 at 1:54 PM Vijay Khemka <vijaykhemka@fb.com> wrote:
> > If I understand correctly, protocol buffer will be used by daemon who
> > Is responding to the IPMI request and connecting to this daemon via
> > library call, then it is completely restricted for the use of protocol buffer.
> > If you are passing protocol buffer to this daemon then we have to define
> > some policy here.
> 
> The Protocol buffer is only for serializing the data to be sent
> outside of the BMC. It is not used for communication inside
> phosphor-health-monitor and will not be passed to the daemon.

Why isn't this part done from within an existing IPMI provider (ideally
to me a google-ipmi-* repository at this time)?  I'm not especially keen
on these details leaking out into other non-IPMI repositories.

> >
> >     Other than these two things I think adding new metrics to
> >     phosphor-health-monitor should be manageable. I can start by trying to
> >     add the IPMI blob handler to phosphor-health-monitor; my first attempt
> >     might not look very elegant, but if we find answers to the two
> >     questions above, the merged result will look a lot better. Hopefully
> >     we can find a solution that works well for everyone.
> >
> > I am looking forward to your patches
> 
> Please check out this WIP:
> https://gerrit.openbmc-project.xyz/c/openbmc/phosphor-health-monitor/+/37092
> 
> This WIP currently just adds the IPMI blob-based code to
> phosphor-health-monitor almost as-is.
> It also shows what we already have now.
> 
> There will be some work to merge the daemon and the blob handler in an
> organic way, and I am open to discussion with you how to do that. The
> first step I think I can do is to put the code for extracting the
> metrics (metrics.cpp, blob/metric.cpp) into a single file and share
> that between the daemon and the IPMI blob handler.
> 
> Another issue I found is I am not using the latest sdbusplus so I have
> to comment out the usage of ValueIface::Unit::Percent for now.
> 
> To build this requires 1) adding a pkgconfig file to
> phosphor-ipmi-blobs (before
> https://gerrit.openbmc-project.xyz/c/openbmc/phosphor-ipmi-blobs/+/37133
> gets merged) and 2) adding phosphor-ipmi-blobs and protobuf to DEPENDS
> in phosphor-health-monitor's Bitbake recipe.
> 
> Hope this WIP change illustrates our intention clearly.
> 
> Thanks!

-- 
Patrick Williams

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, back to index

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-30 15:27 Request to create repository google-ipmi-bmc-health Sui Chen
2020-10-01 19:05 ` Vijay Khemka
2020-10-02  1:52   ` Sui Chen
2020-10-02 20:54     ` Vijay Khemka
2020-10-06 22:57       ` Sui Chen
2020-10-07  1:43         ` Patrick Williams

Openbmc archive at lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/openbmc/0 openbmc/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 openbmc openbmc/ https://lore.kernel.org/openbmc \
		openbmc@lists.ozlabs.org openbmc@ozlabs.org
	public-inbox-index openbmc

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.ozlabs.lists.openbmc


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git