White Papers

10 Standards-based storage management for Dell EMC PowerEdge servers
SupportedDeviceProtocols
0 "SAS"
1 "SATA"
StorageControllers@odata.count 1
Volumes
@odata.id "/redfish/v1/Systems/System.Embedded.1/Storage/RAID.Integrated.1-
1/Volumes"
3.2 Creating a virtual drive (VD) by using Redfish 2016
To create a VD, run a POST command by using the target storage controller URI
redfish/v1/Systems/System.Embedded.1/Storage/{selected storage controller instance ID}/Volumes” with
payload required parameters VolumeType and Drives.
Note: Redfish 2016 schema Storage section will list all the required / optional parameters with supported
values for creating a VD.
The following example shows how to use the controller URI with a payload dictionary and POST command to
create a VD by using Python:
url = 'https://%s/redfish/v1/Systems/System.Embedded.1/Storage/RAID.Slot.6-
1/Volumes' % idrac_ip
payload = {"VolumeType":"Mirrored","Drives":[{"@odata.id":
"/redfish/v1/Systems/System.Embedded.1/Storage/Drives/Disk.Bay.0:Enclosure.Inter
nal.0-1:RAID.Slot.6-1"},{"@odata.id":
"/redfish/v1/Systems/System.Embedded.1/Storage/Drives/Disk.Bay.1:Enclosure.Inter
nal.0-1:RAID.Slot.6-1"}]}
response = requests.post(url, data=json.dumps(payload), headers=headers,
verify=False,auth=(idrac_username,idrac_password))
The example below illustrates using the Python script “CreateVirtualDiskRedfish.py” from the Dell EMC
Redfish Scripting Github repository to create a 10 GB RAID-0 VD.
Note: A best practice is to first run the script with the h option to view the help text which explains the
supported parameters and values and provides usage examples.
1. Check for the storage controllers detected on the target server.
C:\Python27>CreateVirtualDiskRedfish.py -ip 192.168.0.130 -u root -p calvin -c y
- Server controller(s) detected -
RAID.Slot.6-1
PCIeExtender.Slot.1
AHCI.Embedded.1-1
AHCI.Embedded.2-1
PCIeExtender.Slot.7
PCIeExtender.Slot.4