openbmc.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* UpdateService in Redfish
@ 2018-08-21  8:01 Henbin Chang
  2018-08-21 15:07 ` Tanous, Ed
  0 siblings, 1 reply; 4+ messages in thread
From: Henbin Chang @ 2018-08-21  8:01 UTC (permalink / raw)
  To: Tanous, Ed, OpenBMC Maillist

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

Hi Ed,
I search the below commit in the bmcweb REPO.

commit acb7cfb4b571bd2045b1d269625ba054806a466d
Author: Jennifer Lee <jennifer1.lee@intel.com>
Date:   Thu Jun 7 16:08:15 2018 -0700

    Implement POST for redfish UpdateService

    - POST an image file to /redfish/v1/UpdateServer uri will upload the
      image and activate it
    - Modified SoftwareInventoryCollection to list items with
      xyz.openbmc_project.Software.Activation/Activation property as
    "xyz.openbmc_project.Software.Activation.Activations.Active"
    - SoftwareInventory odata.id is identified with DBus generated uuid

May I know if BMC FW can be updated through UpdateService in Redfish?
If yes, could you share how to use it?

Besides that, I add some debug message in
the redfish-core/lib/update_service.hpp but output nothing

Could you give some suggestion?
...
private:
  void doGet(crow::Response &res, const crow::Request &req,
             const std::vector<std::string> &params) override {
    std::cout << "Henbin=" << __FILE__<< ": "<<__LINE__ << "\n";
BMCWEB_LOG_INFO << "Henbin=" << __FILE__<< ": "<<__LINE__ << "\n";
    res.jsonValue = Node::json;
    res.end();
  }
...

Thanks.

BRs,
Henbin.

[-- Attachment #2: Type: text/html, Size: 1956 bytes --]

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

* RE: UpdateService in Redfish
  2018-08-21  8:01 UpdateService in Redfish Henbin Chang
@ 2018-08-21 15:07 ` Tanous, Ed
  2018-08-22  2:30   ` Henbin Chang
  0 siblings, 1 reply; 4+ messages in thread
From: Tanous, Ed @ 2018-08-21 15:07 UTC (permalink / raw)
  To: Henbin Chang, OpenBMC Maillist

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

Yes, it should work, although it’s relatively new, so it’s possible there are bugs or corner cases we haven’t hit yet.  If you find new issues, it would be great if you could file them against the bmcweb project.

To use the endpoint, it should just be a matter of sending a POST request to the update URL containing the tarred image with the manifest in the body.  It works very similarly to the existing update endpoints, it just meets the Redfish specifications.

One thing to watch out for is payload size.  Bmcweb imposes appropriate payload limits, but if you’re reverse proxying the server behind nginx, you might have nginx payload limits imposed and that’ll need to be updated.

-Ed

From: Henbin Chang [mailto:henbinchang@gmail.com]
Sent: Tuesday, August 21, 2018 1:02 AM
To: Tanous, Ed <ed.tanous@intel.com>; OpenBMC Maillist <openbmc@lists.ozlabs.org>
Subject: UpdateService in Redfish

Hi Ed,
I search the below commit in the bmcweb REPO.

commit acb7cfb4b571bd2045b1d269625ba054806a466d
Author: Jennifer Lee <jennifer1.lee@intel.com<mailto:jennifer1.lee@intel.com>>
Date:   Thu Jun 7 16:08:15 2018 -0700

    Implement POST for redfish UpdateService

    - POST an image file to /redfish/v1/UpdateServer uri will upload the
      image and activate it
    - Modified SoftwareInventoryCollection to list items with
      xyz.openbmc_project.Software.Activation/Activation property as
    "xyz.openbmc_project.Software.Activation.Activations.Active"
    - SoftwareInventory odata.id<http://odata.id> is identified with DBus generated uuid

May I know if BMC FW can be updated through UpdateService in Redfish?
If yes, could you share how to use it?

Besides that, I add some debug message in the redfish-core/lib/update_service.hpp but output nothing

Could you give some suggestion?
...
private:
  void doGet(crow::Response &res, const crow::Request &req,
             const std::vector<std::string> &params) override {
    std::cout << "Henbin=" << __FILE__<< ": "<<__LINE__ << "\n";
          BMCWEB_LOG_INFO << "Henbin=" << __FILE__<< ": "<<__LINE__ << "\n";
    res.jsonValue = Node::json;
    res.end();
  }
...

Thanks.

BRs,
Henbin.

[-- Attachment #2: Type: text/html, Size: 7866 bytes --]

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

* Re: UpdateService in Redfish
  2018-08-21 15:07 ` Tanous, Ed
@ 2018-08-22  2:30   ` Henbin Chang
  2018-08-28  1:56     ` Henbin Chang
  0 siblings, 1 reply; 4+ messages in thread
From: Henbin Chang @ 2018-08-22  2:30 UTC (permalink / raw)
  To: Tanous, Ed; +Cc: OpenBMC Maillist

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

Hi Ed,
Thanks for your response.

I tried to send POST request but got "Method Not Allowed".

curl -k -H "Content-Type: application/json" -X POST -d '{"data":
["10.99.240.105", "s2600wf-20180118092748.all.tar"]}'
https://root:0penBmc@10.99.241.36:883/redfish/v1/UpdateService

Please help correct if any typo.

Thanks.

BRs,
Henbin.

Tanous, Ed <ed.tanous@intel.com> 於 2018年8月21日 週二 下午11:07寫道:

> Yes, it should work, although it’s relatively new, so it’s possible there
> are bugs or corner cases we haven’t hit yet.  If you find new issues, it
> would be great if you could file them against the bmcweb project.
>
>
>
> To use the endpoint, it should just be a matter of sending a POST request
> to the update URL containing the tarred image with the manifest in the
> body.  It works very similarly to the existing update endpoints, it just
> meets the Redfish specifications.
>
>
>
> One thing to watch out for is payload size.  Bmcweb imposes appropriate
> payload limits, but if you’re reverse proxying the server behind nginx, you
> might have nginx payload limits imposed and that’ll need to be updated.
>
>
>
> -Ed
>
>
>
> *From:* Henbin Chang [mailto:henbinchang@gmail.com]
> *Sent:* Tuesday, August 21, 2018 1:02 AM
> *To:* Tanous, Ed <ed.tanous@intel.com>; OpenBMC Maillist <
> openbmc@lists.ozlabs.org>
> *Subject:* UpdateService in Redfish
>
>
>
> Hi Ed,
>
> I search the below commit in the bmcweb REPO.
>
>
>
> commit acb7cfb4b571bd2045b1d269625ba054806a466d
>
> Author: Jennifer Lee <jennifer1.lee@intel.com>
>
> Date:   Thu Jun 7 16:08:15 2018 -0700
>
>
>
>     Implement POST for redfish UpdateService
>
>
>
>     - POST an image file to /redfish/v1/UpdateServer uri will upload the
>
>       image and activate it
>
>     - Modified SoftwareInventoryCollection to list items with
>
>       xyz.openbmc_project.Software.Activation/Activation property as
>
>     "xyz.openbmc_project.Software.Activation.Activations.Active"
>
>     - SoftwareInventory odata.id is identified with DBus generated uuid
>
>
>
> May I know if BMC FW can be updated through UpdateService in Redfish?
>
> If yes, could you share how to use it?
>
>
>
> Besides that, I add some debug message in
> the redfish-core/lib/update_service.hpp but output nothing
>
>
>
> Could you give some suggestion?
>
> ...
>
> private:
>
>   void doGet(crow::Response &res, const crow::Request &req,
>
>              const std::vector<std::string> &params) override {
>
>     std::cout << "Henbin=" << __FILE__<< ": "<<__LINE__ << "\n";
>
>           BMCWEB_LOG_INFO << "Henbin=" << __FILE__<< ": "<<__LINE__ <<
> "\n";
>
>     res.jsonValue = Node::json;
>
>     res.end();
>
>   }
>
> ...
>
>
>
> Thanks.
>
>
>
> BRs,
>
> Henbin.
>

[-- Attachment #2: Type: text/html, Size: 7457 bytes --]

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

* Re: UpdateService in Redfish
  2018-08-22  2:30   ` Henbin Chang
@ 2018-08-28  1:56     ` Henbin Chang
  0 siblings, 0 replies; 4+ messages in thread
From: Henbin Chang @ 2018-08-28  1:56 UTC (permalink / raw)
  To: Tanous, Ed; +Cc: OpenBMC Maillist

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

Hi Ed,
Could you share the correct usage for UpdateService?
Or please tell me where I can find the answer.

Thanks for your support.

BRs,
Henbin.


Henbin Chang <henbinchang@gmail.com> 於 2018年8月22日 週三 上午10:30寫道:

> Hi Ed,
> Thanks for your response.
>
> I tried to send POST request but got "Method Not Allowed".
>
> curl -k -H "Content-Type: application/json" -X POST -d '{"data":
> ["10.99.240.105", "s2600wf-20180118092748.all.tar"]}'
> https://root:0penBmc@10.99.241.36:883/redfish/v1/UpdateService
>
> Please help correct if any typo.
>
> Thanks.
>
> BRs,
> Henbin.
>
> Tanous, Ed <ed.tanous@intel.com> 於 2018年8月21日 週二 下午11:07寫道:
>
>> Yes, it should work, although it’s relatively new, so it’s possible there
>> are bugs or corner cases we haven’t hit yet.  If you find new issues, it
>> would be great if you could file them against the bmcweb project.
>>
>>
>>
>> To use the endpoint, it should just be a matter of sending a POST request
>> to the update URL containing the tarred image with the manifest in the
>> body.  It works very similarly to the existing update endpoints, it just
>> meets the Redfish specifications.
>>
>>
>>
>> One thing to watch out for is payload size.  Bmcweb imposes appropriate
>> payload limits, but if you’re reverse proxying the server behind nginx, you
>> might have nginx payload limits imposed and that’ll need to be updated.
>>
>>
>>
>> -Ed
>>
>>
>>
>> *From:* Henbin Chang [mailto:henbinchang@gmail.com]
>> *Sent:* Tuesday, August 21, 2018 1:02 AM
>> *To:* Tanous, Ed <ed.tanous@intel.com>; OpenBMC Maillist <
>> openbmc@lists.ozlabs.org>
>> *Subject:* UpdateService in Redfish
>>
>>
>>
>> Hi Ed,
>>
>> I search the below commit in the bmcweb REPO.
>>
>>
>>
>> commit acb7cfb4b571bd2045b1d269625ba054806a466d
>>
>> Author: Jennifer Lee <jennifer1.lee@intel.com>
>>
>> Date:   Thu Jun 7 16:08:15 2018 -0700
>>
>>
>>
>>     Implement POST for redfish UpdateService
>>
>>
>>
>>     - POST an image file to /redfish/v1/UpdateServer uri will upload the
>>
>>       image and activate it
>>
>>     - Modified SoftwareInventoryCollection to list items with
>>
>>       xyz.openbmc_project.Software.Activation/Activation property as
>>
>>     "xyz.openbmc_project.Software.Activation.Activations.Active"
>>
>>     - SoftwareInventory odata.id is identified with DBus generated uuid
>>
>>
>>
>> May I know if BMC FW can be updated through UpdateService in Redfish?
>>
>> If yes, could you share how to use it?
>>
>>
>>
>> Besides that, I add some debug message in
>> the redfish-core/lib/update_service.hpp but output nothing
>>
>>
>>
>> Could you give some suggestion?
>>
>> ...
>>
>> private:
>>
>>   void doGet(crow::Response &res, const crow::Request &req,
>>
>>              const std::vector<std::string> &params) override {
>>
>>     std::cout << "Henbin=" << __FILE__<< ": "<<__LINE__ << "\n";
>>
>>           BMCWEB_LOG_INFO << "Henbin=" << __FILE__<< ": "<<__LINE__ <<
>> "\n";
>>
>>     res.jsonValue = Node::json;
>>
>>     res.end();
>>
>>   }
>>
>> ...
>>
>>
>>
>> Thanks.
>>
>>
>>
>> BRs,
>>
>> Henbin.
>>
>

[-- Attachment #2: Type: text/html, Size: 8128 bytes --]

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

end of thread, other threads:[~2018-08-28  1:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-21  8:01 UpdateService in Redfish Henbin Chang
2018-08-21 15:07 ` Tanous, Ed
2018-08-22  2:30   ` Henbin Chang
2018-08-28  1:56     ` Henbin Chang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).