HPE OneView
cancel
Showing results for 
Search instead for 
Did you mean: 

REST change boot order

bsadigh
Occasional Visitor

REST change boot order

Hello,

I'm having a really hard time to change to boot order on servers managed by one view, from the REST API.

I have done it with ilo rest api before, with ease, but i'm not having any luck with one view.

Moreover, i can't get any example in the docs or from my research.

Did anyone managed to do it ? 

Thanks in advance.

1 REPLY
ChrisLynchHPE
Neighborhood Moderator

Re: REST change boot order

Boot order management is performed in the Server Profile.  Have you not looked at PUT /rest/server-profiles/{id} ?  Here is an example of a Server Profile with the Boot Order configured:

{
        "uri": "/rest/server-profiles/{id}",
        "type": "ServerProfileV5",
        "name": "Profile101",
        "serverHardwareUri": "/rest/server-hardware/{id}",
        "affinity": "Bay",
        "hideUnusedFlexNics":true,
        "connections": [],
        "bootMode": {
            "manageMode": true,
            "mode": "BIOS"
         },
        "boot": {
            "manageBoot": true,
            "order": ["PXE",
            "HardDisk",
            "CD",
            "Floppy",
            "USB"]
        },
        "bios": {
            "manageBios": false
        },
        "localStorage": {
            "controllers": [{
                "slotNumber": "0",
                "managed": true,
                "mode": "RAID",
                "initialize": false,
                "importConfiguration": false,
                "logicalDrives": [
                  {
                    "driveName": "Operating System",
                    "raidLevel": "RAID0",
                    "bootable": true,
                    "driveTechnology": null,
                    "numPhysicalDrives": "1"
                  },
                  {
                    "driveName": "Recovery Volume",
                    "raidLevel": "RAID1",
                    "bootable": false,
                    "driveTechnology": "SasHdd",
                    "numPhysicalDrives": "2"
                }]
            }]
        },        
        "firmware": {
            "manageFirmware": true,
            "firmwareBaselineUri": "/rest/firmware-drivers/{fwBaselineId}",
            "forceInstallFirmware": false
        }