Mounting an NFS Partition
Function
This interface is used to mount an NFS partition to a specified directory. An NFS partition can be mounted to up to 32 directories.
Syntax
Operation type: POST
URL: https://device_ip/redfish/v1/Systems/NfsManage/Actions/NfsManage.Mount
Request header:
X-Auth-Token: auth_value
Request message body:
{
"ServerIP": serverIp,
"ServerDir": serverPath,
"FileSystem": version,
"MountPath": mountPath
}
Request Parameters
Parameter |
Mandatory/Optional |
Parameter Description |
Value |
|---|---|---|---|
ServerIP |
Mandatory |
IP address of an NFS server. |
IPv4 address. The value is a string. |
ServerDir |
Mandatory |
Shared directory on an NFS server. |
The value starts with a slash (/) and contains up to 256 characters, including only uppercase and lowercase letters (a to z and A to Z), digits (0 to 9), and other characters (/_-). The value cannot contain two consecutive periods (..). |
FileSystem |
Mandatory |
NFS version information. |
nfs4 |
MountPath |
Mandatory |
Local directory to which an NFS partition is mounted. |
The value starts with a slash (/) and contains up to 256 characters, including only uppercase and lowercase letters (a to z and A to Z), digits (0 to 9), and other characters (/_-). The value cannot contain two consecutive periods (..). |
Usage Guidelines
None
Example
Request:
POST https://10.10.10.10/redfish/v1/Systems/NfsManage/Actions/NfsManage.Mount
Request header:
X-Auth-Token: auth_value
Request message body:
{
"ServerIP": "192.168.2.108",
"ServerDir": "/home",
"FileSystem": "nfs4",
"MountPath": "/opt/mount"
}
Response:
{
"error": {
"code": "Base.1.0.Success",
"message": "Operation success. See ExtendedInfo for more information.",
"@Message.ExtendedInfo": [
{
"@odata.type": "#MessageRegistry.v1_0_0.MessageRegistry",
"Description": "Indicates that no error has occurred.",
"Message": "Mount NFS successfully.",
"Severity": "OK",
"NumberOfArgs": null,
"ParamTypes": null,
"Resolution": "None"
}
]
}
}
Response code: 200
Output Description
Field |
Type |
Description |
|---|---|---|
code |
Character string |
A string indicating the specific message ID in the message registry. |
message |
Character string |
A readable message corresponding to a message in the message registry. |
@odata.type |
Character string |
OData description of a message resource. |
Description |
Character string |
Detailed description of a message resource. |
Message |
Character string |
Detailed information about a message resource. |
Severity |
Character string |
Severity.
|
NumberOfArgs |
Number |
Number of parameters in a message description. |
ParamTypes |
Array |
Parameter type list. |
Resolution |
Character string |
Event handling suggestions. |