调整 File Storage for Classic 卷的IOPS
立即调整文件存储卷的每秒输入/输出操作次数(IOPS)值,且不会导致服务中断或影响正常运行。
存储费用的计费已更新,将新价格的按比例计算的差额计入当前计费周期。 在下一个计费周期中将采用整个新金额记帐。
可调整 IOPS 的优点
- 成本管理:客户可根据使用情况调整 IOPS。 例如,一家大型零售店在节假日期间会迎来使用高峰,此时其存储系统所需的IOPS要高于盛夏时节。 通过此功能,您可以管理成本并仅在需要时支付更高的 IOPS。
限制
调整 IOPS 时,无法在“耐力”和“性能”模式之间切换。 您可以根据以下条件为存储器指定新的 IOPS 值:
| 卷大小 (GB) | IOPS 范围 |
|---|---|
| 10 - 39 | 100 - 1,000 |
| 40 - 79 | 100 - 2,000 |
| 80 - 99 | 100 - 4,000 |
| 100 - 499 | 100 - 6,000 |
| 500 - 999 | 100 - 10,000 |
| 1,000 - 1,999 | 100 - 20,000 |
| 2,000 - 2,999 | 200 - 40,000 |
| 3,000 - 3,999 | 200 - 48,000 |
| 4,000 - 7,999 | 300 - 48,000 |
| 8,000 - 9,999 | 500 - 48,000 |
| 10,000 - 12,000 | 1,000 - 48,000 |
文件存储器共享的最大 IOPS 因卷大小而异。 文件共享的最大 IOPS 为 48,000 IOPS。
IOPS 调整对复制的影响
如果卷已复制到位,那么将自动更新该副本以与主卷的 IOPS 选择相匹配。
在控制台中调整存储的 IOPS
- 转至 File Storage for Classic 的列表。 从 IBM Cloud® 控制台,单击基础设施
> 经典基础设施 > 存储 > File Storage for Classic。
- 从列表中选择卷,然后单击省略号
> 修改文件共享。
- 在 调整存储器 IOPS 部分中,进行新选择:
- 对于耐久性 (分层 IOPS),请为存储器选择其他 IOPS 层。 可以随时增大 IOPS 层。 但是,一个月只能减小一次。
- 对于“性能(分配的 IOPS)”,请为存储指定一个新的 IOPS 选项,输入的值应在 100 至 48,000 IOPS 之间。
- 复查您的选择和新的定价。 单击 修改。
- 新存储器分配将在几分钟后可用。
从 CLI 调整存储器上的 IOPS
在开始操作之前,请先确定要使用的命令行界面(CLI)客户端。
- 您可以安装 IBM Cloud CLI 并使用
ibmcloud plugin install sl安装 SL 插件。 有关更多信息,请参阅 使用插件扩展 IBM Cloud CLI。 - 或者,可以安装 SLCLI。
从 IBMCLOUD CLI 调整 IOPS
您可以使用 ibmcloud sl file volume-modify 命令来更新 IOPS。 以下示例通过指定新的 IOPS 值来修改性能文件共享。
ibmcloud sl file volume-modify 12345678 --new-iops 4000
以下示例通过指定新的 IOPS 层来修改耐久性文件共享。
ibmcloud sl file volume-modify 12345678 --new-tier 4
有关可用于此命令的所有参数的更多信息,请参阅 ibmcloud sl file volume-modify。
从 SLCLI 调整 IOPS
您可以使用以下命令更新 IOPS。
$ slcli file volume-modify --help
Usage: slcli file volume-modify [OPTIONS] VOLUME_ID
Options:
-c, --new-size INTEGER New Size of file volume in GB. ***If no size
is given, the original size of volume is
used.***
Potential Sizes: [20, 40, 80, 100,
250, 500, 1000, 2000, 4000, 8000, 12000]
Minimum: [the original size of the volume]
-i, --new-iops INTEGER Performance Storage IOPS, between 100 and 6000
in multiples of 100 [only for performance
volumes] ***If no IOPS value is specified, the
original IOPS value of the volume will be
used.***
-t, --new-tier [0.25|2|4|10] Endurance Storage Tier (IOPS per GB) [only for
endurance volumes] ***If no tier is specified,
the original tier of the volume will be
used.***
-h, --help Show this message and exit.
使用 API 调整存储器上的 IOPS
您可以通过调用 SOAP Web 服务的应用程序编程接口 (API) 来调整 IOPS。 可以使用您选择的脚本语言进行以下样本 API 调用。
有关 SLAPI 的更多信息,请参阅 SLDN。
-
以下示例演示了如何对性能型存储卷请求更改 IOPS。
XXXXXXXXX是您要修改的卷的 ID。3000是您希望卷具有的新 IOPS 值。189433是最高级别价格的 ID。190233是 2000-2999 GB 容量区间的 ID。190293是 200-40000 IOPS 区间的 ID。<?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://api.service.softlayer.com/soap/v3.1/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <SOAP-ENV:Header> <ns1:authenticate> </ns1:authenticate> </SOAP-ENV:Header> <SOAP-ENV:Body> <ns1:placeOrder> <orderData xsi:type="ns1:SoftLayer_Container_Product_Order_Network_Storage_AsAService_Upgrade"> <volume xsi:type="ns1:SoftLayer_Network_Storage"> <id xsi:type="xsd:int">XXXXXXXXX</id> </volume> <iops xsi:type="xsd:int">3000</iops> <packageId xsi:type="xsd:int">759</packageId> <prices SOAP-ENC:arrayType="ns1:SoftLayer_Product_Item_Price[3]" xsi:type="SOAP-ENC:Array"> <item xsi:type="ns1:SoftLayer_Product_Item_Price"> <id xsi:type="xsd:int">189433</id> </item> <item xsi:type="ns1:SoftLayer_Product_Item_Price"> <id xsi:type="xsd:int">190233</id> </item> <item xsi:type="ns1:SoftLayer_Product_Item_Price"> <id xsi:type="xsd:int">190293</id> </item> </prices> </orderData> </ns1:placeOrder> </SOAP-ENV:Body> </SOAP-ENV:Envelope> -
以下示例展示了如何调整持久性存储卷上的 IOPS。
XXXXXXXXX是您要修改的卷的 ID。4是您希望卷具有的新 IOPS 层值。189433是最高级别价格的 ID。193373和193433是卷的容量和 IOPS 对应的价格范围的 ID。<?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://api.service.softlayer.com/soap/v3.1/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <SOAP-ENV:Header> <ns1:authenticate> </ns1:authenticate> </SOAP-ENV:Header> <SOAP-ENV:Body> <ns1:placeOrder> <orderData xsi:type="ns1:SoftLayer_Container_Product_Order_Network_Storage_AsAService_Upgrade"> <volume xsi:type="ns1:SoftLayer_Network_Storage"> <id xsi:type="xsd:int">XXXXXXXX</id> </volume> <packageId xsi:type="xsd:int">759</packageId> <iops xsi:type="xsd:int">4</iops> <prices SOAP-ENC:arrayType="ns1:SoftLayer_Product_Item_Price[3]" xsi:type="SOAP-ENC:Array"> <item xsi:type="ns1:SoftLayer_Product_Item_Price"> <id xsi:type="xsd:int">189433</id> </item> <item xsi:type="ns1:SoftLayer_Product_Item_Price"> <id xsi:type="xsd:int">193373</id> </item> <item xsi:type="ns1:SoftLayer_Product_Item_Price"> <id xsi:type="xsd:int">193433</id> </item> </prices> </orderData> </ns1:placeOrder> </SOAP-ENV:Body> </SOAP-ENV:Envelope>
使用 Terraform 调整存储设备的 IOPS
您可以通过使用 ibm_storage_file 资源并在 iops 参数中指定其他数字来调整 IOPS。 以下示例将耐久性共享的性能层增加到 4 IOPS/GB 层。
resource "ibm_storage_file" "fs_endurance" {
type = "Endurance"
datacenter = "dal09"
capacity = 20
iops = 4
}
以下示例将性能共享的性能级别更改为 150 IOPS。
resource "ibm_storage_file" "fs_performance" {
type = "Performance"
datacenter = "dal09"
capacity = 20
iops = 150
}
有关自变量和属性的更多信息,请参阅 ibm_storage_file。