Updated on 2024-11-13 GMT+08:00

Updating a File System

Function

This API is used to update the cold data eviction period of a file system.

Constraints

This API is only supported for 1,000 MB/s/TiB, 500 MB/s/TiB, 250 MB/s/TiB, 125 MB/s/TiB, 40 MB/s/TiB, and 20 MB/s/TiB file systems that already have storage backends added.

URI

PUT /v1/{project_id}/sfs-turbo/shares/{share_id}

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID

share_id

Yes

String

File system ID

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Account token

Content-Type

Yes

String

MIME type

Table 3 Request body parameters

Parameter

Mandatory

Type

Description

action

Yes

String

Type of operation for updating a file system Only config_gc_time is supported currently.

gc_time

Yes

Integer

Cold data eviction duration. The unit is hour. The value ranges from 1 to 100000000. The default value is 60 hours.

Response Parameters

Status code: 200

Table 4 Response header parameters

Parameter

Type

Description

X-request-id

String

Request ID

Table 5 Response body parameters

Parameter

Type

Description

gc_time

Integer

File system cold data eviction duration

Status code: 404

Table 6 Response body parameters

Parameter

Type

Description

errCode

String

Error code

errMsg

String

Error description

Status code: 500

Table 7 Response body parameters

Parameter

Type

Description

errCode

String

Error code

errMsg

String

Error description

Example Requests

{
  "action" : "config_gc_time",
  "gc_time" : 5
}

Example Responses

Status code: 200

Task submitted

{
  "gc_time" : 10
}

Status code: 404

Error response

{
  "errCode" : "SFS.TURBO.0002",
  "errMsg" : "share not exist"
}

Status code: 500

Error response

{
  "errCode" : "SFS.TURBO.0005",
  "errMsg" : "Internal server error"
}

Status Codes

Status Code

Description

200

Task submitted

404

Error response

500

Error response

Error Codes

See Error Codes.