You need to enable JavaScript to run this app.
文档中心
弹性文件存储

弹性文件存储

复制全文
下载 pdf
文件系统
CreateFileSystem - 创建文件系统
复制全文
下载 pdf
CreateFileSystem - 创建文件系统

调用 CreateFileSystem 接口创建文件系统。

调试

请求参数

下表仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数。

参数
类型
是否必填
示例值
描述
Action
String
是

CreateFileSystem

要执行的操作,取值:CreateFileSystem。

Version
String
是

2022-01-01

API的版本,取值:2022-01-01。

ZoneId
String
是

cn-beijing-a

可用区 ID。

FileSystemName
String
是

data

文件系统名称。

Description
String
否

test

描述信息。

Capacity
Integer
是

100

文件系统容量。

ChargeType
String
是

PayAsYouGo

计费类型,取值 PayAsYouGo,表示按量计费。

FileSystemType
String
是

Extreme

文件系统类型。取值说明如下:

  • Extreme:NAS 极速型。
  • Capacity:NAS 容量型。
  • Cache:NAS 缓存型。
StorageType
String
否

Standard

存储类型,取值Standard,表示标准型。

ProtocolType
String
是

NFS

文件系统协议类型。取值 NFS,表示 NFS 协议,常用于 Linux 客户端。

ProjectName
String
否

default

项目名称。

SnapshotId
String
否

snap-123456

创建时使用的快照 ID。传入该参数后,将使用该快照新建文件系统。

说明

  • 您可以调用 DescribeSnapshots 接口查看快照 ID。

  • 只有 FileSystemType 为 Extreme 时可使用该参数。

ClientToken
String
否

123456-789-0

请求幂等性参数。

Tags
Array of Object
否

[{

"Key": "tagkey",

"Type": "Custom",

"Value": "tagvalue"

}]

文件系统的标签信息。

CacheBandwidth
Integer
否

800

预配置带宽,用于增加文件系统带宽。

说明

只有 FileSystemType 为 Cache 时可使用该参数。

返回参数

下表仅列出本接口特有的返回参数。更多信息请参见返回结构。

参数
类型
示例值
描述
FileSystemId
String

enas-cnbj12345678

文件系统 ID。

OrderNo
String

Order724371858305511****

订单号。

请求示例

POST /?Action=CreateFileSystem&Version=2022-01-01 HTTP/1.1
Host: filenas.volcengineapi.com
Content-Type: application/json; charset=UTF-8
X-Date: 20241126T032807Z
X-Content-Sha256: 287e874e******d653b44d21e
Authorization: HMAC-SHA256 Credential=Adfks******wekfwe/20241126/cn-beijing/FileNAS/request, SignedHeaders=host;x-content-sha256;x-date, Signature=47a7d934ff7b37c03938******cd7b8278a40a1057690c401e92246a0e41085f

{
  "ZoneId": "cn-beijing-a",
  "FileSystemName": "data",
  "Capacity": 100,
  "ChargeType": "PayAsYouGo",
  "FileSystemType": "Extreme",
  "ProtocolType": "NFS"
}

返回示例

{
  "ResponseMetadata": {
    "RequestId": "2024112611281209421001800263B1EA",
    "Action": "CreateFileSystem",
    "Version": "2022-01-01",
    "Service": "FileNAS",
    "Region": "cn-beijing"
  },
  "Result": {
    "FileSystemId": "enas-cnbj12345678",
    "OrderNo": "Order724371858305511****"
  }
}

错误码

下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。

状态码
错误码
错误信息
说明
400
InvalidParameter

The specified parameter format is invalid.

指定的参数不合法。

400
InvalidSaleStatus.NotSale

The specified product specification is not for sale.

指定的产品规格未售卖。

400
InvalidSaleStatus.NotExist

The specified product specification is not exist.

指定的产品规格不存在。

400
BillingError.UnsupportedType

The specified billing type is not allowed.

指定的计费类型不支持。

400
BillingError.AccountInArrears

Your account is in arrears, please recharge first.

您的账户已欠费,无法开通此服务!请前往账户充值。

400
InvalidParameter.Description

The specified parameter Description is invalid.

参数 Description 不合法。

400
InvalidParameter.Capacity

The specified parameter Capacity is invalid.

参数Capacity不合法。

400
InvalidParameter.ProtocolType

The specified parameter ProtocolType is invalid.

参数ProtocolType不合法。

400
InvalidParameter.ChargeType

The specified parameter ChargeType is invalid.

参数ChargeType不合法。

400
InvalidParameter.FileSystemType

The specified parameter FileSystemType is invalid.

参数FileSystemType不合法。

400
InvalidParameter.FileSystemName

The specified parameter FileSystemName is invalid.

参数 FileSystemName 不合法。

400
MissingParameter.Capacity

The required parameter Capacity is not supplied.

参数Capacity不能为空。

400
MissingParameter.ProtocolType

The required parameter ProtocolType is not supplied.

参数ProtocolType不能为空。

400
MissingParameter.ChargeType

The required parameter ChargeType is not supplied.

参数ChargeType不能为空。

400
MissingParameter.FileSystemType

The required parameter FileSystemType is not supplied.

参数FileSystemType不能为空。

400
MissingParameter.ZoneId

The required parameter ZoneId is not supplied.

参数ZoneId不能为空。

400
MissingParameter.FileSystemName

The required parameter FileSystemName is not supplied.

参数FileSystemName不能为空。

400
InvalidSaleStatus.SoldOut

The specified product specification is sold out.

指定的产品规格已售罄。

400
InvalidParameter.TagValue

The specified parameter TagValue is invalid.

参数 TagValue 不合法。

400
InvalidParameter.TagKey

The specified parameter TagKey is invalid.

参数 TagKey 不合法。

400
InvalidParameter.ProjectName

The specified parameter ProjectName is invalid.

参数 ProjectName 不合法。

400
BillingError.BalanceNotEnough

Your account balance and available vouchers are less than 100CNY, please recharge first.

您的账户余额及可用代金券共不足100元,无法开通此服务!请前往账户充值。

400
LimitExceeded.Capacity

The specified Capacity exceeds the limit.

指定的文件系统容量不在合法范围内。

400
QuotaExceeded.FileSystemCapacity

You have reached the limit on the number of FileSystemCapacity, please submit ticket to request an increase in quota.

文件系统容量达到配额上限,请先在配额中心提交申请。

400
QuotaExceeded.FileSystemNumber

You have reached the limit on the number of FileSystemNumber, please submit ticket to request an increase in quota.

文件系统个数达到配额上限,请先在配额中心提交申请。

400
LimitExceeded.Tags

The specified number of Tags exceeds the limit.

指定的标签数量已经达到上限。

400
AlreadyExist.FileSystemName

The specified FileSystem is already exist.

指定名称的文件系统已存在。

403
OperationDenied.SnapshotSizeNotMatch

The specified Capacity is less than snapshot size.

指定的Capacity小于快照的值。

403
OperationDenied.SnapshotZoneNotMatch

The specified ZoneId is not matching snapshot.

指定的ZoneId与快照不一致。

404
NotFound.Project

The specified Project is not exist or has been deleted.

项目不存在或已删除。

404
NotFound.Snapshot

The specified Snapshot is not exist or has been deleted.

快照不存在或已删除。

500
InternalError

An internal error has occurred.

内部错误。

最近更新时间:2025.04.27 17:14:16
这个页面对您有帮助吗?
有用
有用
无用
无用