<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Ilo5 - Change hostname of the server in python redfish in Server Management - Remote Server Management</title>
    <link>https://community.hpe.com/t5/server-management-remote-server/ilo5-change-hostname-of-the-server-in-python-redfish/m-p/7082289#M8620</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;It is mandatory to initialize the&amp;nbsp;HostName&amp;nbsp;property before the OS deployment or boot process because once set, Redfish caches it to make it persistent across reboots. Perform this configuration with an HTTP PATCH toward&amp;nbsp;/redfish/v1/Systems/{item}/&amp;nbsp;and a payload similar to:&amp;nbsp;{"HostName": ""}&lt;/P&gt;&lt;P&gt;Note that this resource can only be modified when the system is&amp;nbsp;Off&amp;nbsp;or in&amp;nbsp;FinishedPost&amp;nbsp;state. Said differently it cannot be modified in&amp;nbsp;InPost&amp;nbsp;or&amp;nbsp;InPostDiscoveryComplete&amp;nbsp;states. This gives the assurance that only a limited number of entities can modify it: An end-user through the iLO GUI, the Redfish API and the Operating System.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please refer:&amp;nbsp;&lt;A href="https://developer.hpe.com/blog/master-the-redfish-server-states-to-improve-your-monitoring-and-manageme" target="_blank"&gt;https://developer.hpe.com/blog/master-the-redfish-server-states-to-improve-your-monitoring-and-manageme&lt;/A&gt;&lt;/P&gt;&lt;P class="grommetux-paragraph grommetux-paragraph--large grommetux-paragraph--align-start grommetux-paragraph--margin-small"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="grommetux-paragraph grommetux-paragraph--large grommetux-paragraph--align-start grommetux-paragraph--margin-small"&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 12 Mar 2020 05:25:26 GMT</pubDate>
    <dc:creator>Suvamay</dc:creator>
    <dc:date>2020-03-12T05:25:26Z</dc:date>
    <item>
      <title>Ilo5 - Change hostname of the server in python redfish</title>
      <link>https://community.hpe.com/t5/server-management-remote-server/ilo5-change-hostname-of-the-server-in-python-redfish/m-p/7081678#M8602</link>
      <description>&lt;P&gt;Hello,&lt;BR /&gt;&lt;BR /&gt;According the official doc :&amp;nbsp;&lt;A href="https://hewlettpackard.github.io/ilo-rest-api-docs/ilo5" target="_blank" rel="noopener"&gt;https://hewlettpackard.github.io/ilo-rest-api-docs/ilo5&lt;/A&gt;&lt;BR /&gt;It's possible to edit the server hostname through Redfish.&lt;BR /&gt;&lt;BR /&gt;Mainly, my code is like this :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;url = 'https://%s/redfish/v1/Systems/1' %(login_host)
body = {"HostName": "new_hostname"}
req = requests.patch(url, data=json.dumps(body), headers=headers, verify=False)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;On a iLO4 (in last version), its working great.&lt;BR /&gt;&lt;BR /&gt;I used the same on a iLO5 (in 2.10 version).&lt;BR /&gt;I have the following 400 error :&lt;BR /&gt;@Message.ExtendedInfo":[{"MessageArgs":["Cannot modify HostName - possibly in POST"],"MessageId":"iLO.2.13.InternalErrorWithParam"}]}}'&lt;BR /&gt;&lt;BR /&gt;If i used a POST instead of PATCH :&lt;BR /&gt;"@Message.ExtendedInfo":[{"MessageArgs":["Action"],"MessageId":"Base.1.4.PropertyMissing"}]}}'&lt;BR /&gt;&lt;BR /&gt;Do you have the good path/payload to update the hostname of a Gen10 server please ?&lt;BR /&gt;&lt;BR /&gt;Thanks a lot.&lt;/P&gt;</description>
      <pubDate>Fri, 06 Mar 2020 10:24:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/server-management-remote-server/ilo5-change-hostname-of-the-server-in-python-redfish/m-p/7081678#M8602</guid>
      <dc:creator>Bruniche</dc:creator>
      <dc:date>2020-03-06T10:24:40Z</dc:date>
    </item>
    <item>
      <title>Re: Ilo5 - Change hostname of the server in python redfish</title>
      <link>https://community.hpe.com/t5/server-management-remote-server/ilo5-change-hostname-of-the-server-in-python-redfish/m-p/7082289#M8620</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;It is mandatory to initialize the&amp;nbsp;HostName&amp;nbsp;property before the OS deployment or boot process because once set, Redfish caches it to make it persistent across reboots. Perform this configuration with an HTTP PATCH toward&amp;nbsp;/redfish/v1/Systems/{item}/&amp;nbsp;and a payload similar to:&amp;nbsp;{"HostName": ""}&lt;/P&gt;&lt;P&gt;Note that this resource can only be modified when the system is&amp;nbsp;Off&amp;nbsp;or in&amp;nbsp;FinishedPost&amp;nbsp;state. Said differently it cannot be modified in&amp;nbsp;InPost&amp;nbsp;or&amp;nbsp;InPostDiscoveryComplete&amp;nbsp;states. This gives the assurance that only a limited number of entities can modify it: An end-user through the iLO GUI, the Redfish API and the Operating System.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please refer:&amp;nbsp;&lt;A href="https://developer.hpe.com/blog/master-the-redfish-server-states-to-improve-your-monitoring-and-manageme" target="_blank"&gt;https://developer.hpe.com/blog/master-the-redfish-server-states-to-improve-your-monitoring-and-manageme&lt;/A&gt;&lt;/P&gt;&lt;P class="grommetux-paragraph grommetux-paragraph--large grommetux-paragraph--align-start grommetux-paragraph--margin-small"&gt;&amp;nbsp;&lt;/P&gt;&lt;P class="grommetux-paragraph grommetux-paragraph--large grommetux-paragraph--align-start grommetux-paragraph--margin-small"&gt;Thanks,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Mar 2020 05:25:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/server-management-remote-server/ilo5-change-hostname-of-the-server-in-python-redfish/m-p/7082289#M8620</guid>
      <dc:creator>Suvamay</dc:creator>
      <dc:date>2020-03-12T05:25:26Z</dc:date>
    </item>
  </channel>
</rss>

