Modifying System Resource Attributes

Function

This interface is used to modify the system resource attributes.

Syntax

Operation type: PATCH

URL: https://device_ip/redfish/v1/Systems

Request header:

X-Auth-Token: auth_value
Content-Type: header_type

Request message body:

{
    "AssetTag": tag,
    "DateTime": time,
    "DateTimeLocalOffset": offset,
    "HostName": hostname
}

Request Parameters

Table 1 Request parameters

Parameter

Mandatory/Optional

Description

Value

AssetTag

Optional

Customized asset tag.

The value is a string of 1 to 255 characters.

The value consists of digits, letters, and punctuation marks, that is, the characters whose ASCII codes range from 0x20 to 0x7E.

DateTime

Optional

Current system time.

The value is a string of 10 to 64 characters in the format of %Y-%m-%d %H:%M:%S or %Y-%m-%d.

NOTE:

The time range supported by the system is the time range supported by the Linux system.

DateTimeLocalOffset

Optional

Time zone of the system.

The value is a string of 0 to 100 characters, including uppercase and lowercase letters (a-z and A-Z), digits (0 to 9), and other characters (+-/:_). The value cannot contain two consecutive periods (..).

HostName

Optional

System host name.

The value is a string of 1 to 63 characters.

The value can contain digits (0-9), letters (a-z and A-Z), and hyphens (-), but cannot start or end with a hyphen (-).

Usage Guidelines

None

Example

Request:

PATCH https://10.10.10.10/redfish/v1/Systems

Request header:

X-Auth-Token: auth_value 
Content-Type: application/json 

Request message body:

{
    "AssetTag": "test00",
    "DateTime": "2022-05-13 15:36:10",
    "DateTimeLocalOffset": "UTC",
    "HostName": "Atlas 200I A2"
}

Response:

{
    "@odata.context": "/redfish/v1/$metadata#Systems",
    "@odata.id": "/redfish/v1/Systems",
    "@odata.type": "#ComputerSystem.v1_18_0.ComputerSystem",
    "Id": "1",
    "Name": "Computer System",
    "HostName": "Atlas 200 A2",
    "UUID": "025VLB10K6000019",
    "Model": "Atlas 200 A2",
    "SupportModel": "Atlas 200 DK A2",
    "SerialNumber": "2102312NNU10K7000017",
    "AssetTag": "test00",
    "Status": {
        "Health": "OK"
    },
    "Processors": {
        "@odata.id": "/redfish/v1/Systems/Processors"
    },
    "Memory": {
        "@odata.id": "/redfish/v1/Systems/Memory"
    },
    "EthernetInterfaces": {
        "@odata.id": "/redfish/v1/Systems/EthernetInterfaces"
    },
    "LogServices": {
        "@odata.id": "/redfish/v1/Systems/LogServices"
    },
    "SimpleStorages": {
        "@odata.id": "/redfish/v1/Systems/SimpleStorages"
    },
    "Oem": {
        "PCBVersion": 1,
        "Temperature": 50,
        "Power": 23,
        "Voltage": 0.02,
        "CpuHeating": "Stop",
        "DiskHeating": "Stop",
        "UsbHubHeating": "Heating",
        "AiTemperature": 55,
        "SoftwareVersion": "22.0.3",
        "ProcessorArchitecture": "ARM",
        "OSVersion": "EulerOS 2.0 (SP10)",
        "KernelVersion": "4.19.90",
        "Uptime": "06:56:58 up 6 min",
        "Datetime": "Fri May 13 15:36:17 UTC 2022",
        "DateTimeLocalOffset": "UTC (UTC, +0000)",
        "CpuUsage": 9.09,
        "MemoryUsage": 16.31,
        "Firmware": [
            {
                "Version": "3.0",
                "InactiveVersion": "3.0",
                "Module": "Ascend-firmware",
                "BoardId": "",
                "UpgradeResult": false,
                "UpgradeProcess": 0
            }
        ],
        "InactiveFirmware": [],
        "InactiveConfiguration": null,
        "NTPService": {
            "@odata.id": "/redfish/v1/Systems/NTPService"
        },
        "ExtendedDevices": {
            "@odata.id": "/redfish/v1/Systems/ExtendedDevices"
        },
        "LTE": {
            "@odata.id": "/redfish/v1/Systems/LTE"
        },
        "NfsManage": {
            "@odata.id": "/redfish/v1/Systems/NfsManage"
        },
        "SecurityService": {
            "@odata.id": "/redfish/v1/Systems/SecurityService"
        },
        "Alarm": {
            "@odata.id": "/redfish/v1/Systems/Alarm"
        },
        "SystemTime": {
            "@odata.id": "/redfish/v1/Systems/SystemTime"
        },
        "EthIpList": {
            "@odata.id": "/redfish/v1/Systems/EthIpList"
        },
        "Modules": {
            "@odata.id": "/redfish/v1/Systems/Module"
        }
    },
    "Actions": {
        "#ComputerSystem.Reset": {
            "target": "/redfish/v1/Systems/Actions/ComputerSystem.Reset"
        },
        "Oem": {
            "#ComputerSystem.RestoreDefaults": {
                "target": "/redfish/v1/Systems/Actions/ComputerSystem.RestoreDefaults"
            }
        }
    }
}

Response code: 200

Output Description

Table 2 Operation output description

Field

Type

Description

@odata.context

String

OData description of a system resource model.

@odata.id

String

System resource access path.

@odata.type

String

Type of a system resource.

Id

String

System resource ID.

Name

String

System resource name.

HostName

String

System host name.

UUID

String

Unique identifier of the system.

Model

String

Product name.

SupportModel

String

Name of the product that can be updated.

SerialNumber

String

Product SN.

AssetTag

String

User-defined electronic label.

Status

Object

System resource status.

Health: indicates the health status of a system resource.

Processors

Object

Path to access the processor interface resource.

Memory

Object

Path to access the memory interface resource.

EthernetInterfaces

Object

Path to access the Ethernet interface resource.

LogServices

Object

Path to access the log interface resource.

SimpleStorage

Object

Path to access the simple storage interface resource.

Oem

Object

Custom attribute.

PCBVersion

Number

PCB version.

Temperature

Number

System temperature.

Power

Number

System power.

Voltage

Number

System voltage.

CpuHeating

String

CPU heating status.

DiskHeating

String

Drive heating status.

UsbHubHeating

String

USB hub heating status.

AiTemperature

Number

MiniD temperature.

SoftwareVersion

String

System software version.

ProcessorArchitecture

String

Processor architecture.

OSVersion

String

OS version.

KernelVersion

String

OS kernel version.

Uptime

String

Continuous running time of the system.

Datetime

String

Current system time.

NOTE:

Due to system data cache, the returned time is 20s deviation from the system time.

DateTimeLocalOffset

String

Time zone of the system.

CpuUsage

Number

CPU usage, in percentage. The value ranges from 0 to 100.

MemoryUsage

Number

Memory usage, in percentage. The value ranges from 0 to 100.

Firmware

List

Firmware list.

The value is Ascend-firmware.

InactiveFirmware

List

Name of the firmware that does not take effect.

If multiple pieces of firmware do not take effect, separate them with commas (,).

InactiveConfiguration

String

Name of the profile that has been imported but has not taken effect.

NTPService

Object

Path to access the NTPService interface resource.

ExtendedDevices

Object

Path to access the external device interface resource.

LTE

Object

Path to access the wireless network interface resource.

Partitions

Object

Path to access the drive interface resource.

NfsManage

Object

Path to access the NFS interface resource.

SecurityService

Object

Path to access the security service interface resource.

Alarm

Object

Path to access the alarm interface resource.

SystemTime

Object

Path to access the system time interface resource.

EthIpList

Object

Path to access the interface resource for obtaining the network port and IP address list.

Modules

Object

Path to access the external device module interface resource.

Actions

Object

Operations that can be performed.

#ComputerSystem.Reset

Object

OS restart operation.

#ComputerSystem.RestoreDefaults

Object

Remote factory setting restoration.