华为云用户手册

  • 前提条件 已在API网关控制台创建签名密钥,并绑定API,具体请参见创建并使用签名密钥。 已获取签名密钥的Key和Secret,请参见签名前准备获取。 进入API网关控制台,参考《API网关用户指南》的“SDK”章节,进入SDK页面并下载SDK。或直接下载SDK的最新版本。 已获取apigateway-backend-signature-demo。 已安装IntelliJ IDEA 2018.3.5或以上版本,如果未安装,请至IntelliJ IDEA官方网站下载。 已安装Java Development Kit 1.8.111或以上版本,如果未安装,请至Oracle官方下载页面下载。暂不支持Java Development Kit 17或以上版本。
  • 操作步骤 在FunctionGraph中开发函数。 下面以python2.7语言为例,函数代码需要满足如下条件: 函数代码支持三种请求参数定义,格式为: Header中的请求参数:event["headers"]["参数名"] Query中的请求参数:event["queryStringParameters"]["参数名"] 您自定义的用户数据:event["user_data"] 函数代码获取的三种请求参数与API网关自定义认证中的参数关系如下所示: Header中的请求参数:对应自定义认证中参数位置为Header的身份来源,其参数值在您调用使用该前端自定义认证的API时传入 Query中的请求参数:对应自定义认证中参数位置为Query的身份来源,其参数值在您调用使用该前端自定义认证的API时传入 您自定义的用户数据:对应自定义认证中的用户数据,其参数值在您创建自定义认证时输入 函数的返回值不能大于1M,必须满足如下格式: { "statusCode":200, "body": "{\"status\": \"allow\", \"context\": {\"user\": \"abc\"}}" } 其中,body字段的内容为字符串格式,json解码之后为: { "status": "allow/deny", "context": { "user": "abc" } } “status”字段为必选,用于标识认证结果。只支持“allow”或“deny”,“allow”表示认证成功,“deny”表示认证失败。 “context”字段为可选,支持字符串类型键值对,当实例支持authorizer_context_support_num_bool特性时,键值对的值支持number类型或boolean类型,键值不支持JSON对象或数组。 context中的数据为您自定义的字段,认证通过后作为认证参数映射到API网关后端参数中,其中context中的参数名称与系统参数名称必须完全一致,且区分大小写,context中的参数名称必须以英文字母开头,支持英文大小写字母、数字、下划线和中划线,且长度为1 ~ 32个字符。 前端认证通过后,context中的user的值abc映射到后端服务Header位置的test参数中。 Header中的请求参数定义代码示例: # -*- coding:utf-8 -*- import json def handler(event, context): if event["headers"].get("test")=='abc': resp = { 'statusCode': 200, 'body': json.dumps({ "status":"allow", "context":{ "user":"abcd" } }) } else: resp = { 'statusCode': 200, 'body': json.dumps({ "status":"deny", }) } return json.dumps(resp) Query中的请求参数定义代码示例: # -*- coding:utf-8 -*- import json def handler(event, context): if event["queryStringParameters"].get("test")=='abc': resp = { 'statusCode': 200, 'body': json.dumps({ "status":"allow", "context":{ "user":"abcd" } }) } else: resp = { 'statusCode': 200, 'body': json.dumps({ "status":"deny", }) } return json.dumps(resp) 用户数据定义代码示例: # -*- coding:utf-8 -*- import json def handler(event, context): if event.get("user_data")=='abc': resp = { 'statusCode': 200, 'body': json.dumps({ "status":"allow", "context":{ "user":"abcd" } }) } else: resp = { 'statusCode': 200, 'body': json.dumps({ "status":"deny", }) } return json.dumps(resp) 测试函数。在测试事件的“事件模板”中选择“apig-event-template”,根据实际情况修改后保存测试模板,单击“测试”。 执行结果为“成功”时,表示测试成功。 接下来您需要进入API网关界面创建前端自定义认证。
  • 操作场景 如果您想要使用自己的认证系统对API的访问进行认证鉴权,您可以在API管理中创建一个前端自定义认证来实现此功能。在使用前端自定义认证对前端请求进行认证鉴权前,您需要先在FunctionGraph创建一个函数,通过函数定义您所需的认证信息。函数创建完后,作为自定义认证的后端函数,对API网关中的API进行认证鉴权。 本章节介绍如何将校验函数封装成一个“自定义认证”,以及封装成自定义认证过程中的操作注意事项。 图1 前端自定义认证示意图 使用自定义认证调用API的流程如下图所示: 图2 自定义认证调用API 自定义认证依赖函数服务。如果当前Region没有上线函数服务,则不支持使用自定义认证。
  • 操作场景 如果您需要使用一种认证机制对接多个不同的外部认证系统,实现对于后端服务的保护,您可以通过API网关中的后端自定义认证实现此功能。在使用后端自定义认证对后端请求进行认证授权前,您需要先在FunctionGraph创建一个函数,通过函数定义您所需的认证信息。函数作为自定义认证的后端函数,对API网关中的API进行认证授权。 图1 后端自定义认证示意图 使用自定义认证调用API的流程如下图所示: 图2 使用自定义认证调用API 自定义认证依赖函数服务。如果当前Region没有上线函数服务,则不支持使用自定义认证。
  • 操作步骤 在FunctionGraph中开发函数。 下面以python2.7为例,函数代码需要满足如下条件: 函数代码只支持您自定义的用户数据,且它的格式为:event["user_data"]。 函数代码获取的请求参数与API网关自定义认证中的参数关系为:函数请求参数中的自定义用户数据对应API网关自定义认证中的用户数据,参数值在您创建API网关自定义认证时输入,用户数据格式不限制,您可以自行指定。 函数的返回值不能大于1M,必须满足如下格式: { "statusCode":200, "body": "{\"status\": \"allow\", \"context\": {\"user\": \"abc\"}}" } 其中,body字段的内容为字符串格式,json解码之后为: { "status": "allow/deny", "context": { "user": "abc" } } “status”字段为必选,用于标识认证结果。只支持“allow”或“deny”,“allow”表示认证成功,“deny”表示认证失败。 “context”字段为可选,支持字符串类型键值对,当实例支持authorizer_context_support_num_bool特性时,键值对的值支持number类型和boolean类型,键值不支持JSON对象或数组。 context中的数据为您自定义的字段,认证通过后作为认证参数映射到API网关后端参数中,其中context中的参数名称与系统参数名称必须完全一致,且区分大小写。context中的参数名称必须以英文字母开头,支持英文大小写字母、数字、下划线和中划线,且长度为1 ~ 32个字符。 后端认证通过后,context中的user的值abc映射到后端服务Header位置的test参数中,并将其传递给API的后端服务。 用户数据定义代码示例: # -*- coding:utf-8 -*- import json import base64 def handler(event, context): exampleuserdata=base64.b64encode(event["user_data"]) resp = { 'statusCode': 200, 'body': json.dumps({ "status":"allow", "context":{ "user":exampleuserdata } }) } return json.dumps(resp) 测试函数。在测试事件的“事件模板”中选择“空白模板”,内容为: {"user_data": "123"} 根据实际情况修改后保存测试模板,单击“测试”。 执行结果为“成功”时,表示测试成功。 接下来您需要进入API网关界面创建后端自定义认证。
  • 调用API示例 使用JavaScript SDK生成curl命令。 请登录API网关控制台,参考《API网关用户指南》的“SDK”章节,进入SDK页面并下载SDK。 或直接下载JavaScript SDK的最新版本,并解压。在浏览器中打开demo.html,页面如下图所示。 填入Key、Secret、方法名、请求协议、域名和url。例如: 1 2 3 4 5 6 // Directly writing AK/SK in code is risky. For security, encrypt your AK/SK and store them in the configuration file or environment variables. // In this example, the AK/SK are stored in environment variables for identity authentication. Before running this example, set environment variables HUAWEICLOUD_SDK_AK and HUAWEICLOUD_SDK_SK. Key=4f5f****100c Secret=****** Method=POST Url=https://c967a237-cd6c-470e-906f-a8655461897e.apigw.exampleRegion.com 填入json格式的Query和Headers,填入Body。 单击“Send request”,生成curl命令。将curl命令复制到命令行,访问API。 $ curl -X POST "https://c967a237-cd6c-470e-906f-a8655461897e.apigw.exampleRegion.com/" -H "X-Sdk-Date: 20180530T115847Z" -H "Authorization: SDK-HMAC-SHA256 Access=071fe245-9cf6-4d75-822d-c29945a1e06a, SignedHeaders=host;x-sdk-date, Signature=9e5314bd156d517******dd3e5765fdde4" -d "" Congratulations, sdk demo is running SDK生成的curl命令不符合Window下cmd终端格式,请在git bash下执行生成的curl命令。
  • FPGA加速型Fp1c 表15 通用型架构弹性云服务器的规格 规格名称 vCPU 内存 (GiB) 最大带宽/基准带宽 (Gbps) 最大收发包能力 (万PPS) 网卡多队列数 FPGA 虚拟化类型 fp1c.2xlarge.11 8 88GiB 5/1.3 20 2 1×VU9P KVM fp1c.8xlarge.11 32 352GiB 10/5 60 8 4×VU9P KVM fp1c.16xlarge.11 64 704GiB 10/10 100 8 8×VU9P KVM fp1c.8xlarge.8 32 224GiB 10/5 60 8 1×VU9P KVM fp1c.16xlarge.8 64 448GiB 10/10 100 8 2×VU9P KVM
  • 图形加速型G1 表13 G1型弹性云服务器的规格 规格名称 vCPU 内存 (GiB) 最大带宽/基准带宽 最大收发包能力 GPU 显存 (GiB) 虚拟化类型 g1.xlarge 4 8 中 中 1×M60-1Q 1 XEN g1.xlarge.4 4 16 中 中 1×M60-1Q 1 XEN g1.2xlarge 8 16 中 中 1×M60-2Q 2 XEN g1.2xlarge.8 8 64 中 中 直通 8 XEN g1.4xlarge 16 32 中 中 1×M60-4Q 4 XEN
  • FPGA加速型Fp1 表14 高性能架构弹性云服务器的规格 规格名称 vCPU 内存 (GiB) 最大带宽/基准带宽 (Gbps) 最大收发包能力 (万PPS) 网卡多队列数 FPGA 虚拟化类型 fp1.2xlarge.11 8 88GiB 5/1.3 20 2 1×VU9P KVM fp1.8xlarge.11 32 352GiB 10/5 60 8 4×VU9P KVM fp1.16xlarge.11 64 704GiB 10/10 100 8 8×VU9P KVM fp1.8xlarge.8 32 224GiB 10/5 60 8 1×VU9P KVM fp1.16xlarge.8 64 448GiB 10/10 100 8 2×VU9P KVM
  • 通用计算增强型C1 表3 C1型弹性云服务器的规格 规格名称 vCPU 内存(GiB) 最大带宽/基准带宽 最大收发包能力 虚拟化类型 c1.medium 1 1 低 低 XEN c1.large 2 2 低 低 XEN c1.xlarge 4 4 中 中 XEN c1.2xlarge 8 8 中 中 XEN c1.4xlarge 16 16 中 中 XEN c1.8xlarge 32 32 中 中 XEN
  • 磁盘增强型D1 表8 D1型弹性云服务器的规格 规格名称 vCPU 内存(GiB) 最大带宽/基准带宽 最大收发包能力 本地盘(GiB) 虚拟化类型 d1.xlarge 4 32 中 中 3 × 1675 XEN d1.2xlarge 8 64 中 中 6 × 1675 XEN d1.4xlarge 16 128 中 中 12 × 1675 XEN d1.9xlarge 36 256 中 中 24 × 1675 XEN
  • D1型弹性云服务器使用须知 不支持网卡热插拔。 主网卡和扩展网卡的使用场景如表9所示。 表9 D1型弹性云服务器网卡的使用场景 网卡类型 使用场景 配置说明 主网卡 用于南北向的三层通信。 - 扩展网卡 用于东西向的二层通信。 为了提高网络性能,可以将扩展网卡的MTU值设置为MTU=8888。 不支持规格变更。 不支持操作系统的重装、切换功能。 当前仅支持如下版本的操作系统: CentOS 7.2 64bit CentOS 7.3 64bit CentOS 6.8 64bit SUSE Enterprise Linux Server 11 SP3 64bit SUSE Enterprise Linux Server 11 SP4 64bit SUSE Enterprise Linux Server 12 SP1 64bit SUSE Enterprise Linux Server 12 SP2 64bit Red Hat Enterprise Linux 6.8 64bit Red Hat Enterprise Linux 7.3 64bit 可使用本地盘和云硬盘两类磁盘存储数据。关于本地盘和云硬盘的使用,有如下约束与限制: 系统盘只能部署在云硬盘上,不可以部署在本地盘上。 数据盘可以部署在云硬盘和本地盘上。 最多可以挂载60块磁盘(包括本地盘)。具体约束限制请参见一台弹性云服务器可以挂载多块磁盘吗。 对于已创建的D1型弹性云服务器,最多可以挂载的磁盘数量保持原配额。 对于D1型弹性云服务器,关机后其基础资源 (包括vCPU、内存、镜像)会继续收费。如需停止计费,需删除弹性云服务器。
  • 通用计算增强型C2 表2 C2型弹性云服务器的规格 规格名称 vCPU 内存(GiB) 最大带宽/基准带宽 最大收发包能力 虚拟化类型 c2.medium 1 2 低 低 XEN c2.large 2 4 低 低 XEN c2.xlarge 4 8 中 中 XEN c2.2xlarge 8 16 中 中 XEN c2.4xlarge 16 32 中 中 XEN c2.8xlarge 32 64 中 中 XEN
  • H1型云服务器使用须知 H1型弹性云服务器不支持网卡热插拔。 H1型弹性云服务器仅支持同类型云服务器的规格变更。 H1型弹性云服务器当前支持如下版本的操作系统: CentOS 6.8 64bit CentOS 7.2 64bit CentOS 7.3 64bit Windows Server 2008 Windows Server 2012 Windows Server 2016 SUSE Enterprise Linux Server 11 SP3 64bit SUSE Enterprise Linux Server 11 SP4 64bit SUSE Enterprise Linux Server 12 SP1 64bit SUSE Enterprise Linux Server 12 SP2 64bit Red Hat Enterprise Linux 6.8 64bit Red Hat Enterprise Linux 7.3 64bit H1型弹性云服务器主网卡和扩展网卡的使用场景如表12所示。 表12 H1型弹性云服务器网卡的使用场景 网卡类型 使用场景 配置说明 主网卡 用于南北向的三层通信 - 扩展网卡 用于东西向的二层通信 为了提高网络性能,可以将扩展网卡的MTU值设置为MTU=8888。
  • 通用计算型S1 表1 S1型弹性云服务器的规格 规格名称 vCPU 内存(GiB) 最大带宽/基准带宽 最大收发包能力 虚拟化类型 s1.medium 1 4 低 低 XEN s1.large 2 8 低 低 XEN s1.xlarge 4 16 中 中 XEN s1.2xlarge 8 32 中 中 XEN s1.4xlarge 16 64 中 中 XEN s1.8xlarge 32 128 中 中 XEN
  • 快速入门 以下教程将引导您了解并使用QingTian Enclave特性,包括如何启动QingTian Enclave父虚拟机,如何构建QingTian Enclave镜像文件,如何查询正在运行的QingTian Enclave,以及停止QingTian Enclave。 准备一台支持QingTian Enclave特性的虚拟机实例 在购买虚拟机时,您需要在高级选项中勾选Enclave,并选择Linux作为系统镜像。建议使用HCE2.0镜像。 连接到父虚拟机,请参考华为云E CS 用户指南。 在父虚拟机中安装qt CLI工具,并在配置文件中按需设置资源隔离参数,然后启动资源隔离服务。详情请见QingTian CLI(qt CLI)。 您可以安装qt CLI工具和其他必要rpm包: yum install qt-enclave-bootstrap yum install virtio-qtbox yum install qingtian-tool 在配置文件中按需配置隔离参数,本教程内使用默认1G内存,2个vCPU。然后启动隔离服务: systemctl start qt-enclave-env 在父虚拟机中安装Docker程序,我们推荐使用二进制的方式进行Docker安装,可以在Docker官方网站下载需要版本。这里以18.09.9为例: wget https://download.docker.com/linux/static/stable/x86_64/docker-18.09.9.tgz 对下载的压缩包进行解压操作: tar zxf docker-18.09.9.tgz 解压完成后将docker目录下所有文件复制到/usr/bin目录下: cp docker/* /usr/bin 启动docker服务,并将日志等级设置为error等级: dockerd -l error & 验证Docker版本: docker version 运行hello-world容器,查看Docker是否安装正确: docker run hello-world 构建QingTian Enclave镜像 本教程中,使用以下脚本作为QingTian Enclave应用程序: #!/bin/bash while true do echo "hello enclave!" sleep 2 done Dockerfile内容如下: FROM ubuntu:latest COPY hello_enclave.sh /root/hello_enclave.sh CMD ["/root/hello_enclave.sh"] 构建一个名为hello-enclave的Docker镜像: docker build -f Dockerfile -t hello-enclave . 使用qt enclave make-img命令将Docker镜像转换为名为hello-enclave.eif的QingTian Enclave镜像: qt enclave make-img --docker-uri hello-enclave --eif hello-enclave.eif 输出为: # qt enclave make-img --docker-uri hello-enclave --eif hello-enclave.eif { "digest": "SHA384", "PCR0": "63bf78ece7d2388ff773d0cad2ebc9a3070359db46d567ba271ff8adfb8b0b091be4ff4d5dda3f1c83109096e3656f3b", "PCR8": "000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" } 现在已经构建了名为hello-enclave.eif的QingTian Enclave镜像,命令包含了一系列PCR值,包括PCR0和PCR8(该例子中制作镜像时并没有指定证书和密钥,所以PCR8为0)。这些哈希值是在Enclave镜像构建时产生的测量值,它们通常作为预期的测量值(相对于证明文档中所包含的启动时测量值而言)。 运行QingTian Enclave实例 现在可以使用以下命令来运行QingTian Enclave镜像: qt enclave start --mem 1024 --cpus 2 --eif hello-enclave.eif --cid 4 --debug-mode 该实例运行在debug-mode,关于debug-mode详情可见qt enclave子命令介绍。 您会看到以下输出: # qt enclave start --cpus 2 --mem 1024 --eif hello-enclave.eif --cid 4 --debug-mode Started enclave with EnclaveID : 0, EnclaveCID : 4, NumberOfCPUs : 2, MemoryMiB : 1024 { "EnclaveID": 0, "EnclaveCID": 4, "NumberOfCPUs": 2, "MemoryMiB": 1024, "LaunchMode": "debug" } 在该教程中,我们为该QingTian Enclave实例分配了2个vCPU和1024M内存,并指定其cid为4,该cid可作为QingTian Enclave实例与父虚拟机实例之间的本地套接字的IP地址。 查询正在运行的QingTian Enclave 按以上步骤创建完QingTian Enclave实例后,可以以下命令查询他是否在运行: qt enclave query --enclave-id 0 # qt enclave query --enclave-id 0 [{ "EnclaveID": 0, "ProcessID": 29990, "EnclaveCID": 4, "NumberOfCPUs": 2, "MemoryMiB": 1024, "LaunchMode": "debug" }] 该命令可以用于查询QingTian Enclave相关信息,包括EnclaveID、ProcessID、EnclaveCID、vCPU数量、内存数量以及其运行模式。因为该实例是以debug模式启动的,所以可以用qt enclave console 命令查看QingTian Enclave的只读控制台输出。 hello enclave! hello enclave! hello enclave! hello enclave! 您将观察到终端每隔2秒打印一次hello enclave!。 停止正在运行的QingTian Enclave实例 如果您想停止运行以上的QingTian Enclave实例,可以使用以下命令: # qt enclave stop --enclave-id 0 stop enclave 0 successfully { "EnclaveID": 0 } 父主题: QingTian Enclave管理
  • QingTian Enclave SDK QingTian Enclave SDK由一系列开源库组成,以便您开发自己的QingTian Enclave应用程序。其中包括QingTian安全模块(QingTian Security Module,QTSM)提供的qtsm-lib函数库。此外,SDK集成了KMS接口,该接口内置了获取证明文档及调用华为云KMS相关服务的功能。在典型使用案例里,我们描述了在QingTian Enclave调用KMS解密接口的实例。 表1 接口介绍 类型 接口 接口描述 libqtsm接口 qtsm_describe_pcr 查询指定index的PCR数据信息 qtsm_extend_pcr 扩展指定index对应的PCR值 qtsm_lock_pcr 锁定指定index的PCR数据信息 qtsm_lock_pcrs 批量锁定指定index对应的PCR值 qtsm_get_describe 获取qtsm信息 qtsm_get_attestation 获取Attestation Doc qtsm_get_random 获取硬件随机数 KMS接口 kms_generate_datakey_blocking 生成新的密钥对,获取公钥与私钥 kms_generate_datakey_blocking_with_proxy 集成qtproxy代理的密钥对获取接口 kms_gen_random_blocking 获取随机数 kms_gen_random_blocking_with_proxy 集成qtproxy代理的随机数获取接口 kms_decrypt_data_blocking 解密数据 kms_decrypt_data_blocking_with_proxy 集成qtproxy代理的解密数据接口 源码可以在开源仓库https://gitee.com/HuaweiCloudDeveloper/huawei-qingtian/tree/master/enclave免费获取,您可以基于测试示例开发自己的QingTian Enclave应用程序。
  • libqtsm与SDK使用示例 本节主要基于开源示例代码来介绍如何在QingTian Enclave应用程序中使用libqtsm与SDK接口。本节中提供的示例程序只支持在Linux环境下运行。 安装libqtsm开发包: yum install libqtsm-devel 获取开源示例代码,拷贝至enclave镜像创建环境中,地址如下: https://gitee.com/HuaweiCloudDeveloper/huawei-qingtian/tree/master/enclave/qtsm 创建一个Dockerfile文件,内容如下: # start the Docker image from ubuntu FROM ubuntu AS base-img WORKDIR /home/builder # COPY libqtsm example COPY ./qtsm qtsm_tests/ # install relative dependencies RUN apt-get update && \ apt-get install gcc -y && \ apt-get install make -y && \ apt-get install libssl-dev -y && \ apt-get install libglib2.0-dev -y && \ apt-get install curl -y && \ apt-get install libcurl4-openssl-dev –y && \ apt-get install -y libcbor-dev && \ apt-get install -y libjson-c-dev # build a test demo RUN cd qtsm_tests/tests/ && \ make RUN cp /home/builder/qtsm_tests/tests/gtest_libqtsm /root/ # Launch a client CMD "/root/gtest_libqtsm" 构建docker镜像,将docker镜像装换为enclave镜像并启动enclave。 获取SDK接口的开源示例代码,地址如下: https://gitee.com/HuaweiCloudDeveloper/huawei-qingtian/tree/master/enclave/qtsm-sdk-c/samples
  • 相关操作 当不再使用虚拟IP时,可以删除虚拟IP地址,详细内容,请参考删除虚拟IP地址。 弹性云服务器的网卡解绑并删除虚拟IP地址后,需要在弹性云服务器上手工删除虚拟IP地址。 Linux系统(本文以“CentOS 7.2 64bit”为例,其他规格请参考对应官网帮助文档) 执行以下命令,查看并记录需要删除虚拟IP的网卡及对应连接。 nmcli connection 回显类似如下信息: 本示例的回显信息说明如下: DEVICE列的eth0为需要删除虚拟IP的网卡。 NAME列的Wired connection 1为网卡对应的连接。 执行以下命令,在目标连接中删除虚拟IP。 nmcli connection delete "CONNECTION" ipv4.addresses VIP 参数说明如下: CONNECTION:为步骤1中查到的网卡对应的连接。 VIP:待删除的虚拟IP地址。 执行以下命令,使配置生效。 nmcli connection up "CONNECTION" 命令示例: nmcli connection up "Wired connection 1" 执行以下命令,检查虚拟IP配置是否成功。 ip a 可以看到eth0网卡下已经不存在添加的虚拟IP地址。
  • 系统PCR PCR 度量内容 备注 PCR0 QingTian Enclave镜像文件 QingTian Enclave镜像文件本身,不包括证书与签名信息 PCR8 QingTian Enclave镜像文件签名证书 QingTian Enclave镜像文件的签名证书 当前QingTian Enclave提供的度量值支持PCR0和PCR8,后续会进行扩展。 PCR0是对QingTian Enclave镜像文件的度量值,在镜像制作完成时,PCR0的值就是确定的。以下是PCR0实例: EXTEND_PCR: index: 0 EXTEND_PCR: data: 0d1ae7330f437ee563178df30a7c7b7634125d31cac14f6784933db5e90080008438b38fdbb39c886ffe0586ab099b56 EXTEND_PCR res: data: b8c59692da8a5bcb739a83d15a0ceca670bd78da06cb2250ec70548f72254e674419e9888db9c0364a9b88dd58017a62 PCR8是对QingTian Enclave镜像文件的签名证书的度量值,用户可以选择用自己的证书和私钥对镜像文件进行签名。只有当镜像文件使用了签名证书和私钥进行签名,才会有对应的PCR8。使用PCR8可以确认是镜像是通过特定的签名证书来进行签名的,即使镜像文件改变,只要指定的签名证书不变,PCR8就不会变化。以下是PCR8实例: EXTEND_PCR: index: 8 EXTEND_PCR: data: c5b3e075e00c261e7fc364f1541067b2a42d4b793225ab10e5cfb8eaca31b3d598af9dd2e491828c2569a9953401abcb EXTEND_PCR res: data: 4f8b066ce5ac24150612ba9a55bbb9211f626152ada40ede160f4d7ecbfa214c2a549181f6611a3d16a12ec88a577a01
  • 事件状态 系统上报的事件状态如表2所示,您可以根据状态判断系统上报事件的进展,也可以通过状态进行事件筛选。 表2 事件状态 类型 描述 待授权 需要用户对事件操作进行授权, 授权时支持指定开始时间, 系统将会在一定时间内完成操作,详细内容请参见响应事件。 待执行 等待系统资源调度中。 执行中 系统已完成资源调度, 正在修复中。 执行成功 系统已完成事件执行。 请验证业务受损情况, 如遇异常,请联系技术支持。 执行失败 系统自动修复失败。 取消 该事件已被系统取消。
  • 事件类型 系统支持上报的事件如表1所示。 表1 支持系统上报的事件 事件类型 事件说明 事件影响 用户侧处理建议 实例重部署 当系统检测到ECS实例的底层宿主机异常,计划将ECS实例部署到新主机时,会自动上报实例重部署事件。 实例重部署过程中,云服务器将会有短暂时间不可用。 系统会在计划事件执行时间前24~72小时该系统事件通知。 须知: 对于包含本地盘的实例,会丢失所有本地盘上的数据。 您可以根据业务需要选择如下处理方式,并在事件处理完成后,及时验证业务受损情况, 如遇问题,请联系技术支持。 授权重部署 建议您在授权时选择业务低谷期为开始时间,如不指定将会以当前时间为开始时间。 本地盘换盘 系统检测到ECS实例(含裸金属类型实例)的底层宿主机存在磁盘故障风险,会对受影响的ECS实例自动生成本地盘换盘事件。 本地盘换盘会丢失本地盘上的数据。 您可以根据业务需要选择如下处理方式,并在事件处理完成后,及时验证业务受损情况, 如遇问题,请联系技术支持。 须知: 本地盘换盘操作会丢失本地盘上的数据,如果无需保留本地盘数据,可根据业务需要选择如下处理方式。 立即重部署:会丢失所有本地盘数据 裸金属类型实例暂不支持该操作。 授权换盘:会丢失故障本地盘数据 建议您在授权时选择业务低谷期为开始时间,如不指定将会以当前时间为开始时间。 通常会在开始时间后5个工作日内完成本地盘换盘,请耐心等待。 实例迁移 当系统检测到ECS实例的底层宿主机异常,需要进行重启、关机、下线等系统维护时,计划对ECS实例进行迁移,会自动上报实例迁移事件。 系统会先尝试对云服务器进行热迁移,如遇异常,则会触发HA机制(云服务器将会有短暂时间不可用)。 建议您在事件处理完成后,及时验证业务受损情况, 如遇问题,请联系技术支持。 系统维护 系统检测到ECS实例(含裸金属类型实例)的宿主机存在软硬件故障风险,计划对受影响的实例进行维护操作,会自动生成系统维护事件。 系统维护过程中,宿主机可能会进入下电状态,云服务器不可用。 您可以根据业务需要选择如下处理方式,并在事件处理完成后,及时验证业务受损情况, 如遇问题,请联系技术支持。 授权维护 建议您在授权时确保实例的业务已离线并选择业务低谷期为开始时间,如不指定将会以当前时间为开始时间。 不同故障系统维护的耗时不同。通常会在授权开始时间后5个工作日内完成系统维护,请耐心等待。
  • 构建QingTian Enclave镜像 在开发人员开发完成一个QingTian Enclave应用程序后,还需要在一个可信赖的环境中构建QingTian Enclave镜像文件(.eif)。该镜像文件提供了启动QingTian Enclave实例所需要的所有信息,包括应用程序代码、运行时依赖、操作系统和文件系统等。在本节我们将说明如何创建QingTian Enclave镜像文件。 制作docker源镜像 用户将开发好的enclave应用程序及其相关的执行环境打包成docker镜像。详情可见Linux系统上QingTian Enclave应用的开发。 获取镜像库中的镜像 本章将使用docker仓中提供的ubuntu镜像为例。从docker中获取镜像源(虚拟机内需要配置网络才可查询)。查询镜像源命令: docker search ubuntu 将ubuntu镜像pull到本地: docker pull ubuntu 镜像pull到本地后可以通过以下命令查询到: docker image ls 如果您使用本地docker镜像,可以直接进行步骤3镜像转换。 镜像转换 接下来,您需要将docker镜像转换为QingTian Enclave镜像,转换前可以通过(openssl或其他工具)创建私钥(private-key.pem)和证书(server.pem)。生成私钥和证书为可选项。*qt make-img*命令中的必要参数为docker源镜像和创建后生成的QingTian Enclave目标镜像。 # qt enclave make-img --docker-uri ubuntu --eif /home/docker/ubuntu.eif -- private-key /home/docker/private-key.pem--signing-certificate /home/docker/server.pem { "digest": "SHA384", "PCR0": "b8c59692da8a5bcb739a83d15a0ceca670bd78da06cb2250ec70548f72254e674419e9888db9c0364a9b88dd58017a62" "PCR8": "dbf4a7f9fab7f18619b5899c407081981ad6762fb9a809da78548821b5021965423181584acd7b201703376f1133a546" } 至此,QingTian Enclave可用的EIF镜像已制作完成。您会获得一组散列PCR0和PCR8,这些散列值用作预期的Enclave度量值,它们可用于 IAM 授权策略中的条件键,以实现对KMS API的条件访问控制。详情可见PCR简介。 父主题: 典型使用案例
  • 响应消息 响应参数 响应参数如表2所示。 表2 响应参数 参数 参数类型 描述 volumeAttachments Array of objects 云服务器挂载信息列表,详情请参见表3。 表3 volumeAttachments字段数据结构说明 参数 参数类型 描述 device String 挂载目录。 id String 挂载资源ID。 serverId String 所属云服务器ID。 volumeId String 挂载云磁盘ID。
  • 响应示例 { "volumeAttachments": [ { "device": "/dev/sdd", "id": "a26887c6-c47b-4654-abb5-dfadf7d3f803", "serverId": "4d8c3732-a248-40ed-bebc-539a6ffd25c0", "volumeId": "a26887c6-c47b-4654-abb5-dfadf7d3f803" }, { "device": "/dev/sdc", "id": "a26887c6-c47b-4654-abb5-dfadf7d3f804", "serverId": "4d8c3732-a248-40ed-bebc-539a6ffd25c0", "volumeId": "a26887c6-c47b-4654-abb5-dfadf7d3f804" } ] }
  • 请求示例 批量删除指定云服务器的2组标签。 POST https://{endpoint}/v1/{project_id}/cloudservers/{server_id}/tags/action { "action": "delete", "tags": [ { "key": "key1", "value": "value1" }, { "key": "key2", "value": "value3" } ] }
  • 请求消息 请求参数如表2所示。 表2 请求参数 参数 是否必选 参数类型 描述 tags 是 Array of objects 标签列表,详情参见表3 action 是 String 操作标识(仅支持小写):delete(删除) 表3 tags 字段数据结构说明 参数 是否必选 参数类型 描述 key 是 String 键。 不能为空。 同一资源的key值不能重复。 value 否 String 值。 可以为空字符串。
  • 错误码说明 当您调用API时,如果遇到“APIGW”开头的错误码,请参见API网关错误码进行处理。 状态码 错误码 错误信息 描述 处理措施 400 Ecs.0000 Request error. Try again later or contact customer service. 请求数据错误 请参考返回的error message信息检查请求体 400 Ecs.0001 Insufficient ECS quota. Contact customer service to increase quota. 租户云服务器配额不足 请参考返回的error message申请扩大相应资源的配额 400 Ecs.0002 A system exception occurred. Try again later or contact customer service. 提交任务失败 请联系技术支持进行定位 403 Ecs.0003 You do not have permission to perform this operation. Contact customer service to obtain permission. 帐户受限 请参考返回的error message,检查是否余额不足,帐号被冻结等 400 Ecs.0004 A system exception occurred. Try again later or contact customer service. 升权失败 请参考返回的error message,或者联系技术支持 400 Ecs.0005 Invalid parameter values. Contact customer service. 参数非法 请参考接口文档检查请求体是否为一个正确的json体 400 Ecs.0006 Invalid parameter values. Contact customer service. 市场镜像没有产品编号 请检查镜像参数 400 Ecs.0007 A system exception occurred. Try again later or contact customer service. 镜像相关属性非法 请调整规格或者镜像类型 400 Ecs.0008 A system exception occurred. Try again later or contact customer service. Flavor相关属性非法 请联系技术支持排查flavor注册是否合法 400 Ecs.0009 Another flavor must be used for resizing. Flavor未变更 变更云服务器规格时选择与原规格不同的Flavor 400 Ecs.0010 The private IP address is already being used. Select another IP address. 私有IP地址已经被使用 请更换Port 400 Ecs.0011 Ensure the password meets the password complexity requirements. 密码不符合系统要求复杂度 请检查密码的长度并修改 400 Ecs.0012 The subnet does not contain enough IP addresses. Release some IP addresses or select a different subnet. IP地址不足 请检查子网的FIP是否已经被使用完 400 Ecs.0013 The current EIP quota limit has been reached. Apply to increase the quota. EIP配额不足 EIP配额不足,请申请扩大EIP配额 400 Ecs.0014 Incorrect VPC, subnet, or security group parameter values. VPC参数不合法 请检查子网是否都属于同一个虚拟机私有云 400 Ecs.0015 Invalid disk type for this type of ECS. Select a valid disk type and try again. 该类型磁盘不适用于该类型云服务器 请检查卷的volume_type是否与Flavor匹配 400 Ecs.0016 You do not have permission to access this AZ. Request OBT permission and try again. 创建云服务器时,没有对应Flavor的公测权限。 变更云服务器规格时,没有对应Flavor的公测权限。 请申请公测权限或者更换其他规格。 400 Ecs.0017 The status of the selected disk does not meet the attachment requirements on the ECS. Select an available disk for attaching. 系统盘或数据盘所属云服务器和待挂载云服务器不同 请检查卷metadata中__system__server_id是否和待挂载的虚拟机uuid相同 400 Ecs.0018 The selected flavor has been sold out. Try another flavor. Flavor已售罄 请更换其他规格 400 Ecs.0019 The selected flavor has been canceled. Try another flavor. Flavor已下线 请更换其他规格 400 Ecs.0021 Insufficient EVS disk quota. Contact customer service to increase quota. 云硬盘配额不足 申请扩大云硬盘配额 400 Ecs.0022 Insufficient ECS group quota. Contact customer service to increase quota. 云服务器组超过用户配额 申请扩大云服务器组配额 400 Ecs.0023 project_id in token mismatches with project_id in url. token无效或者token中的tenantId和URL中的tenantId不匹配 申请合法的token或者检查URL中的项目ID 400 Ecs.0025 EVS is not authorized to obtain KMS keys for encrypting EVS disks. 未授权EVS获取KMS密钥加密云硬盘 请授权EVS获取KMS密钥加密云硬盘 400 Ecs.0027 The ECSs of this flavor cannot be created. Flavor属于私有规格,禁止使用。 请更换其他规格 400 Ecs.0028 The ECSs of this flavor cannot be created. 用户已加入该Flavor黑名单,禁止使用该规格 请更换其他规格 400 Ecs.0029 The flavor does not exist. Flavor不存在或已下线 请更换其他规格 400 Ecs.0030 The ECS has been frozen and does not support specifications modification. 云服务器被冻结 请检查账户是否被冻结或者联系技术支持 400 Ecs.0031 The image does not exist. 镜像不存在 请更换镜像 400 Ecs.0032 The image is not in Active state. 镜像状态错误,非Active状态 请更换镜像 400 Ecs.0034 The full-ECS backup does not exist or has been deleted. 整机备份不存在或已被删除. 请更换镜像 400 Ecs.0036 The flavor does not support automatic recovery. 当前规格不支持自动恢复 请更换规格 400 Ecs.0037 The flavor does not support SCSI disks. 当前规格不支持挂载SCSI类型的磁盘 请更换规格或者类型 400 Ecs.0038 The subnet does not exist. 子网不存在 请调整网络参数 400 Ecs.0039 The specified IP address does not belong to the subnet. 指定的IP不属于该子网 请修改指定的私有IP 400 Ecs.0041 Invalid description field. 描述字段不合法 请修改云服务描述字段 400 Ecs.0042 The number of attached data disks exceeds the maximum allowed limit. 挂载数据盘的个数超过限制 请调整挂载数据盘的个数 400 Ecs.0043 The disk type does not exist. 磁盘类型不存在 请修改磁盘类型 400 Ecs.0044 The disk of this type has been sold out. 该类型磁盘已售罄 请修改磁盘类型 400 Ecs.0045 The bandwidth exceeds the maximum allowed limit. 带宽大小超过限制 请调整带宽的大小 400 Ecs.0046 When creating an ECS using an image, ensure that the type of the attached data disk is the same as that required by the image. 云服务器的磁盘类型必须与快照镜像对应的磁盘一致 请调整磁盘类型 400 Ecs.0048 Ensure that the image status is Normal and that the status of the CSBS backup associated with the image is Available or Creating, and try again later. 整机镜像的状态不可用 请检查整机镜像的状态 400 Ecs.0049 The selected enterprise project has been disabled. Enable the project or select another project. 企业项目状态非法 请修改企业项目的状态 400 Ecs.0050 The number of NICs attached to the ECS exceeds the quota. 云服务器所挂网卡数超过限制。 请调整网卡的个数 400 Ecs.0051 Only SCSI disks can be attached to the ECSs of this flavor. 云服务器只能挂载scsi磁盘 请调整磁盘类型 400 Ecs.0052 Only SCSI system disks can be attached to the ECSs of this flavor. 云服务器只能挂载scsi系统盘 请调整系统盘的磁盘类型 400 Ecs.0053 Only SCSI data disks can be attached to the ECSs of this flavor. 云服务器只能挂载scsi数据盘 请调整数据盘的磁盘类型 400 Ecs.0057 The disk has already been attached to the ECS and you cannot repeatedly attach it. 云服务器已挂载当前磁盘 请替换一个新的磁盘挂载 400 Ecs.0058 You do not have permission to use a third-party image to create ECSs. 镜像的provideId和当前账号的不匹配 请检查账户权限及镜像 400 Ecs.0062 The flavor does not support the driver mode. 规格不支持设置网卡驱动类型 请更换规格 400 Ecs.0064 The VPC ID in the request is inconsistent with that in the main subnet ID. 请求体中的vpcId与主网卡的vpcId不一致 请调整网卡参数 403 Ecs.0066 This operation cannot be performed because real-name authentication has not been completed. 未实名认证受限 请检查账户是否未实名认证受限 403 Ecs.0067 Insufficient account balance. 余额不足受限 请检查账户是否余额不足受限 403 Ecs.0068 This operation cannot be performed by partners. 成为合作伙伴受限 请检查账户是否成为合作伙伴受限 403 Ecs.0069 You have not associated a payment method with your account. 未完善支付信息受限 请检查账户是否未完善支付信息受限 403 Ecs.0070 Insufficient budget. Contact the enterprise administrator and request for a budget increase. 企业部门账号预算不足受限 请检查账户是否企业部门账号预算不足受限 403 Ecs.0071 This operation cannot be performed because your account has been suspended. 黑产账号受限 请检查账户是否黑产账号受限 400 Ecs.0073 The system disk is being backed up. Wait until the execution is complete and try again. 系统卷处于卷备份过程中 系统卷处于备份中时,禁止删除系统卷 400 Ecs.0074 Window images do not support external users. 外部用户禁止创建windows虚拟机 外部用户(非内部用户、非第三方创建镜像)禁止购买windows镜像 400 Ecs.0075 Partners only support Windows images. 合作伙伴只支持购买windows镜像 合作伙伴只支持购买windows镜像 400 Ecs.0076 The spot block specification does not support the selected predefined duration. 购买的竞价实例时长超过最长限制 请调整购买竞价实例时长 400 Ecs.0077 The number of durations exceeds the maximum limit of the spot block ECS. 购买的“竞价实例时长”的个数超过最大限制 请调整购买“竞价实例时长”的个数 400 Ecs.0081 Scheduled deletion is not supported. 不支持定时销毁功能 请参考返回的error message信息检查请求体 400 Ecs.0082 Incorrect time format. 自动释放格式错误。需要使用 UTC 时间,格式为:yyyy-MM-ddTHH:mm:ssZ 请参考返回的error message信息检查请求体 403 Ecs.0083 The scheduled time has been reached. 自动销毁时间已经过期 请参考返回的error message信息检查请求体 400 Ecs.0084 Scheduled deletion is not supported. 包年/包月实例auto_terminate_time 必须为空 请参考返回的error message信息检查请求体 400 Ecs.0085 The server does not have the interface. 虚拟机没有该网卡 请更换网卡 400 Ecs.0086 The interface is not the primary interface. 网卡不是主网卡 请更换网卡 400 Ecs.0089 Tag policy compliance verification failed. Tag policy合规性校验不通过 请检查Tag policy策略,或者联系技术支持。 400 Ecs.0090 Image license type is BYOL, the BYOL feature is not supported at this time. 当前区域不支持BYOL镜像相关特性。 请更换镜像,或者联系技术支持。 400 Ecs.0100 The ECS status does not meet requirements. Make the ECS in the required status and try again. 云服务器状态不符合要求 云服务器状态不支持当前操作,请延后操作 400 Ecs.0101 The system disk is currently unresponsive. Try again later or contact customer service. 系统盘状态异常 具体原因请联系技术支持 400 Ecs.0102 The data disk is currently unresponsive. Try again later or contact customer service. 系统盘状态不支持卸载 请检查系统盘的状态 400 Ecs.0103 The disk can be attached to a server only if it exists and the state must be in the available. Make sure the disk state is available and try again. 云磁盘状态不可用 检查卷的状态或者联系技术支持更改卷状态 400 Ecs.0104 The number of EVS disks that can be attached to the ECS exceeds the maximum number allowed. Decrease the number of EVS disks to be attached and try again. 云服务器可挂载云硬盘槽位不足 请调整挂载磁盘数 400 Ecs.0105 No system disk found. Attach the system disk to the ECS and try again. 云服务器系统盘查询失败 请检查云服务器是否挂载有系统盘 400 Ecs.0106 A network exception occurred. Try again later or contact customer service. 网络状态异常 具体原因请联系技术支持进行定位 403 Ecs.0110 Contact the main account to obtain permission. 客户端禁止,权限不足 权限不足,请确认token权限,详情请参考接口返回的error message 400 Ecs.0111 The EVS disk has been detached from the ECS. Refresh the disk list and check the disk. 磁盘没有挂载至服务列表中 请检查所选磁盘信息是否已经挂载,或者更换新的磁盘 400 Ecs.0112 The ECS is not billed on a pay-per-use basis. 非按需类型云服务器不能迁移 非按需类型云服务器不能迁移,如有疑问请联系技术支持 404 Ecs.0114 The ECS does not exist. 云服务器不存在 请检查云服务器是否已经创建 400 Ecs.0118 The number of ECSs exceeds the maximum allowed limit. 批量操作的任务数超过最大限制 请检查批量操作任务中云服务器的数量 400 Ecs.0119 An encrypted disk with an unavailable key cannot be attached to an ECS. 云服务器无法挂载密钥已禁用的加密磁盘 请更改密钥的状态。 400 Ecs.0120 The yearly/monthly ECS cannot be rebuilt. 包年/包月虚拟机禁止rebuild 包年/包月虚拟机禁止rebuild,如有疑问请联系技术支持 400 Ecs.0121 The disk cannot be attached to the ECS because the disk and the ECS are in different failure domains. 挂卷失败 虚拟机和卷的故障域不一致 选择和虚拟机故障域匹配的卷挂载 400 Ecs.0201 Failed to create the NIC. Try again later or contact customer service. 创建网卡失败 请参考返回的error message,或者联系技术支持 400 Ecs.0202 Failed to create the system disk. Try again later or contact customer service. 创建系统盘失败 请参考返回的error message,或者联系技术支持 400 Ecs.0203 Failed to create the data disk. Try again later or contact customer service. 创建数据盘失败 请参考返回的error message,或者联系技术支持 400 Ecs.0204 Failed to create the ECS. Try again later or contact customer service. 创建云服务器失败 请参考返回的error message,或者联系技术支持 400 Ecs.0205 Failed to attach the data disk. Try again later or contact customer service. 挂载数据盘失败 请参考返回的error message,或者联系技术支持 400 Ecs.0207 Failed to modify the ECS specifications. Try again later or contact customer service. 变更云服务器规格失败 请参考返回的error message,或者联系技术支持 400 Ecs.0208 A system exception occurred. Try again later or contact customer service. 更新镜像metadata失败 请参考返回的error message,或者联系技术支持 400 Ecs.0209 Failed to modify the ECS specifications. Try again or contact customer service. 确认变更云服务器规格失败 请参考返回的error message,或者联系技术支持 400 Ecs.0210 A system exception occurred. Try again later or contact customer service. 创建浮动IP失败 请参考返回的error message,或者联系技术支持 400 Ecs.0211 Failed to create the NIC. Try again later or contact customer service. 创建网卡Qos失败 请参考返回的error message,或者联系技术支持 400 Ecs.0212 Failed to assign the private IP address. Try again later or contact customer service. 创建私有IP地址失败 具体原因请联系技术支持 400 Ecs.0213 Failed to update the port attributes. Try again later or contact customer service. 更新端口属性失败 请参考返回的error message,或者联系技术支持 400 Ecs.0214 Failed to create the network. Try again later or contact customer service. 创建网络失败 请参考返回的error message,或者联系技术支持 400 Ecs.0216 Failed to create the subnet. Try again later or contact customer service. 创建子网失败 请参考返回的error message,或者联系技术支持 400 Ecs.0217 Failed to attach the NIC. Try again later or contact customer service. 挂载端口失败 请参考返回的error message,或者联系技术支持 400 Ecs.0219 Failed to create the ECS. Try again later or contact customer service. 创建云服务器失败 请参考返回的error message,或者联系技术支持 400 Ecs.0221 Cold migration from a dedicated host to the same dedicated host is not supported. 迁移云服务器失败 请参考返回的error message,或者联系技术支持 400 Ecs.0226 Failed to start. 启动云服务器失败 请参考返回的error message,或者联系技术支持 400 Ecs.0227 Failed to reboot. 重启云服务器失败 请参考返回的error message,或者联系技术支持 400 Ecs.0301 Failed to query the ECS. Try again later or contact customer service. 查询云服务器失败 请参考返回的error message,或者联系技术支持 400 Ecs.0302 Failed to query the ECS quota of the tenant. Try again later or contact customer service. 查询租户云服务器配额失败 请参考返回的error message,或者联系技术支持 400 Ecs.0303 Failed to query the ECS specifications. Try again later or contact customer service. 查询规格失败 请参考返回的error message,或者联系技术支持 400 Ecs.0304 Failed to query the image. Try again later or contact customer service. 查询镜像失败 请联系技术支持确认镜像是否注册正确,或者联系技术支持确认其他原因 400 Ecs.0306 Failed to query the backup. Try again later or contact customer service. 查询备份失败 请参考返回的error message,或者联系技术支持 400 Ecs.0307 Failed to query the port. Try again later or contact customer service. 查询端口失败 请参考返回的error message,或者联系技术支持 400 Ecs.0308 Failed to query the ECS quota of the tenant. Try again later or contact customer service. 查询租户云服务器配额失败 请参考返回的error message,或者联系技术支持 400 Ecs.0309 Failed to create the NIC. Try again later or contact customer service. 查询网卡Qos失败 请参考返回的error message,或者联系技术支持 400 Ecs.0310 A system exception occurred. Try again later or contact customer service. 查询网络失败 请参考返回的error message,或者联系技术支持 400 Ecs.0311 Failed to obtain the disk type. Try again later or contact customer service. 查询卷类型失败 请参考返回的error message,或者联系技术支持 400 Ecs.0313 ECS group query failed. 查询云服务组失败 请参考返回的error message,或者联系技术支持 400 Ecs.0314 The key pair does not exist. Refresh the key pair list and check key pair 请求OpenStack查询keypair失败 请参考返回的error message,或者联系技术支持 400 Ecs.0315 Failed to call the nova API to query the auto recovery status. 查询云服务器是否设置auto recovery失败 请参考返回的error message,或者联系技术支持 400 Ecs.0319 Insufficient resources for this flavor. Try another flavor. flavor容量不足 申请扩大flavor容量 400 Ecs.0320 AZ query failed. 查询可用区失败 请参考返回的error message,或者联系技术支持 400 Ecs.0321 Console logs query failed. 查询云服务器控制台日志失败 请参考返回的error message,或者联系技术支持 400 Ecs.0322 Subnet query failed. 查询子网详情失败 请参考返回的error message,或者联系技术支持 400 Ecs.0323 Failed to query the NIC attached to the ECS. 查询虚拟机挂载网卡失败 请参考返回的error message,或者联系技术支持 400 Ecs.0401 Failed to release the port. Try again later or contact customer service. 回滚端口失败 请参考返回的error message,或者联系技术支持 400 Ecs.0402 Failed to release the system disk. Try again later or contact customer service. 回滚系统卷失败 请参考返回的error message,或者联系技术支持 400 Ecs.0403 Failed to release the ECS. Try again later or contact customer service. 回滚云服务器失败 联系技术支持定位回滚服务器失败原因 400 Ecs.0405 Failed to release the data disk. Try again later or contact customer service. 回滚数据盘失败 请参考返回的error message,或者联系技术支持 400 Ecs.0501 Failed to delete the ECS. Try again later or contact customer service. 删除云服务器失败 请稍后重新执行操作 400 Ecs.0502 Failed to delete the private IP address. Try again later or contact customer service. 删除私有IP失败 请参考返回的error message,或者联系技术支持 400 Ecs.0503 Failed to obtain the system disk. Try again later or contact customer service. 查询系统卷失败 请参考返回的error message,或者联系技术支持 400 Ecs.0507 Failed to delete the NIC. Try again later or contact customer service. 删除网卡失败 请检查网卡类型 400 Ecs.0510 Yearly/Monthly ECSs do not support changing OSs. 包年/包月弹性云服务器不支持变更操作系统 按包年包月计费的,且使用的市场镜像的云服务器不支持切换操作系统 400 Ecs.0513 server %s is the cycle order and not be deleted by ordinary user 普通用户不允许删除包年/包月弹性云服务器 包周弹性云服务器请执行退订操作 501 Ecs.0603 ther commands are being executed. Try again later. 当前已有其他命令执行,请稍后1分钟重试 请稍后1分钟重试 400 Ecs.0605 ECS locked. 云服务器被锁定 请检查云服务器是否被锁定,若想继续操作请先将云服务器解锁。 400 Ecs.0610 Failed to reset the ECS password. 重置密码失败 请稍后重新执行操作,或者联系技术支持 400 Ecs.0611 Batch operation failed. 批量请求操作失败 根据返回的详细错误信息,修改错误后重新进行请求处理 400 Ecs.0612 Failed to check whether plug-ins have been installed. 校验弹性云服务器是否安装插件请求失败 请稍后重新执行操作,或者联系技术支持 400 Ecs.0613 The ECS has no plug-ins installed. 弹性云服务器未安装插件 安装插件 404 Ecs.0614 The ECS does not exist. 弹性云服务器不存在 检查弹性云服务器是否存在 500 Ecs.0615 The thread list is empty. 服务器处理请求异常 系统内部错误。 请联系技术支持进行定位 400 Ecs.0616 Failed to update the ECS name. 弹性云服务器修改失败 请稍后重新执行操作,或者联系技术支持 400 Ecs.0617 Failed to modify attribute. Please try again later or contact customer service. 修改云服务器挂载的磁盘属性失败 请参考返回的错误信息,或者联系技术支持 400 Ecs.0618 Failed to change the IP address of the ECS NIC. 修改云服务器网卡IP失败 请参考返回的error message,或者联系技术支持 400 Ecs.0701 Failed to obtain the order or product. Try again later or contact customer service. 查询订单或者产品失败 请联系技术支持进行定位 400 Ecs.0702 Failed to get the demand price or spot price. Try again later or contact customer service. 查询价格失败 查询价格接口异常,请联系技术支持 400 Ecs.0703 The single instance price limit cannot be less than the spot price. 用户出价小于当前现价 用户出价小于竞价实例市场价格,请提高竞价实例出价 400 Ecs.0704 Spot ECSs do not support specifications modification. 竞价型实例不允许切换规格 竞价实例不允许切换规格 400 Ecs.0705 Automatic recovery cannot be enabled on spot ECSs. 竞价型实例不允许开启自动恢复 竞价实例不允许开启自动恢复 400 Ecs.0706 RIs cannot be split or combined. 合并拆分预留实例失败 请联系技术支持进行定位 400 Ecs.0707 The product has not been registered. 购买的该产品不存在 请联系技术支持进行定位 400 Ecs.0802 The specifications of an ECS created using a Red Hat image cannot be modified. 弹性云服务器不支持变更规格 特定镜像的弹性云服务器不支持变更规格 400 Ecs.0803 When modifying the specifications of an ECS created on a DeH, specify the DeH. DEH弹性云服务器变更规格需指定专属主机的ID 请修改变更规格请求体 400 Ecs.0804 The ECS flavor cannot be switched to the target flavor. Change the target flavor. 弹性云服务器不支持变更到目标规格 请更换其他规格 400 Ecs.0805 A large-memory ECS cannot be switched to a general computing ECS. 超大内存型 Flavor不能与普通Flavor互切 超大内存型 Flavor不能与普通Flavor互切 400 Ecs.0806 H2 ECSs do not support specifications modification. 高性能计算型II代实例不支持变更规格 高性能计算型II代实例不支持变更规格 400 Ecs.0807 The number of ECS NICs exceeds the maximum number allowed on the target ECS. Uninstall excess NICs. 弹性云服务器网卡个数超过目标规格云服务器网卡的挂载限制 请卸载多余网卡 400 Ecs.0808 The Xen ECS created using a UEFI image does not support specifications modification. UEFI镜像的XEN弹性云服务器不支持变更规格 UEFI镜像的XEN弹性云服务器不支持变更规格 400 Ecs.0809 The number of VBD disks exceeds the maximum number allowed on the target ECS. Uninstall excess disks. VBD磁盘数量超过目标规格弹性云服务器的挂载限制 请卸载多余磁盘 400 Ecs.0810 The ECS flavor is the same as the target flavor. 目标规格与弹性云服务器当前规格一样 请更换其他规格 400 Ecs.0811 Install the required drivers on the ECS and then change Xen to KVM. 当前规格不支持从xen切换到 kvm 请安装驱动脚本 400 Ecs.0812 Current flavor %s can not resize to flavor %s. 当前规格变更到目标规格需要执行驱动检查脚本 请执行驱动检查脚本 详细操作,请参见: KVM实例变更为QingTian实例(Linux) KVM实例变更为QingTian实例(Windows) 400 Ecs.0813 Change flavor %s to flavor %s is risky, the driver needs to be installed. 当前规格切换到目标规格存在风险 执行驱动检查脚本后,入参传force参数且值为true,忽略风险。 400 Ecs.0901 Yearly/Monthly DeHs cannot be allocated. 不支持创建包年/包月的DEH 请更换其他规格 400 Ecs.0902 Spot ECSs do not support Marketplace images. 竞价实例不支持使用市场镜像 请更换其他镜像 400 Ecs.0903 Spot ECSs do not support automatic recovery. 竞价实例不支持自动恢复 请更换其他规格 400 Ecs.0904 UEFI images cannot be used to create Xen ECSs. UEFI镜像不支持创建XEN实例 请更换其他规格 400 Ecs.0905 The number of tags exceeds the maximum allowed limit. 标签的个数超过限制 请减少标签的个数 400 Ecs.0906 Failed to comply with tag character set specifications. 标签的属性非法 请重新制定标签 400 Ecs.0907 Invalid tag character set. 标签字符集不合法 请重新制定标签 400 Ecs.0908 The tag key cannot be duplicate. 标签的键重复 请重新制定标签 400 Ecs.0909 The flavor does not support the disk type. 当前规格不支持该磁盘类型 请更换其他规格或者磁盘类型 400 Ecs.0910 Invalid NIC settings for creating a HANA ECS. 创建HANA实例的网卡参数不合法 请调整网卡参数 400 Ecs.0911 Invalid dedicated storage type of the disk. 磁盘的专属存储类型参数不合法 请调整专属存储类型参数 400 Ecs.0912 Invalid disk encryption key. 磁盘加密属性参数不合法 请调整磁盘加密属性参数 400 Ecs.0913 The number of ECSs to be created exceeds the maximum allowed limit 创建云服务器个数超过限制 请减少创建的云服务器个数 400 Ecs.0914 The length of the ECS name exceeds the maximum allowed limit. 云服务器名称长度超过限制 请调整云服务器名称参数 400 Ecs.0915 The length of the ECS name exceeds the maximum allowed limit. 云服务器名称包含非法字符 请调整云服务器名称参数 400 Ecs.0919 The NIC has been attached to another instance. 端口状态不允许挂载 请更换网卡端口。 400 Ecs.1000 A system exception occurred. Try again later or contact customer service. 调用Nova接口处理请求异常 系统内部调用异常,请稍后重试或请联系技术支持 400 Ecs.1001 A system exception occurred. Try again later or contact customer service. 访问OpenStack异常 OpenStack异常导致云服务器状态异常,请联系技术支持 400 Ecs.1002 A system exception occurred. Try again later or contact customer service. 访问OpenStack超时 如果您正在执行切换VPC、挂载/卸载网卡、挂载/卸载磁盘、切换/重装操作系统等操作,请关闭资源后再重试操作。 如果重试后仍超时,请联系技术支持。 400 Ecs.1100 A system exception occurred. Try again later or contact customer service. 访问IAM失败 请参考返回的error message,或者联系技术支持 400 Ecs.1200 A system exception occurred. Try again later or contact customer service. 访问VPC失败 请参考返回的error message,或者联系技术支持 400 Ecs.1201 A system exception occurred. Try again later or contact customer service. 访问VPC超时 任务超时,具体原因请联系技术支持 400 Ecs.1300 A system exception occurred. Try again later or contact customer service. 访问EVS超时 请参考返回的error message,或者联系技术支持 400 Ecs.7000 Check whether your account balance is sufficient for the order, whether there are orders pending payment, and whether the order is being processed. Try again later or contact customer service. 创建订单失败 请查看账户余额是否足够支付订单,是否有订单待支付以及是否订单处理中,或者联系技术支持 403 Pdp.0001 Policy doesn't allow %s to be performed. API鉴权失败 请参考API授权项列表,在IAM增加相关权限 202 Common.0024 exceeds flow over limit 请求流控 请求并发过高,请稍后重试。 400 Common.0002 The request body cannot be left blank. 请求消息体为空 请检查请求body体 400 Common.0011 Failed to query system tasks. 无效JobId 请确认JobId参数来源是否正确 400 Common.0018 The project ID in the URL is different from that in the token. token无效,token中的project_id和URL中的project_id不一致 请检查租户的token是否正确 400 Common.0020 A system exception occurred. Try again later or contact customer service. 任务重试失败 请联系技术支持 400 Common.0021 Sub job fail! 查询Job异常 请稍后重试,或联系技术支持 400 Common.0022 Mission fail! 提交Job异常 请联系技术支持 400 Common.0999 The system was broken, exit. 任务退出 请联系技术支持 400 Common.0025 Query job Error because %s. 查询Job异常 请稍后重试,或联系技术支持 400 Common.0026 Fail to get Region Info 查询AZ信息异常 请稍后重试,或联系技术支持 401 Common.0013 Invalid token. token不合法 请检查租户的token是否正确 500 Common.0001 A system exception occurred. Try again later or contact customer service. 系统异常 请联系技术支持 503 Common.1503 Api flow control Error because %s. API流控 正在执行的API过多,请稍后重试。
  • 背景信息 接口返回的错误码与Error Message不具有一一对应关系,表中只是列出比较常见的一种Error Message。 本服务接口以异步接口居多,有的错误码是在查询任务的返回体中体现的,http状态码有可能不是很准确。 本服务对网络、存储等服务具有强依赖性,Error Message显示依赖服务的错误消息时,处理措施需要联系技术支持。 在管理控制台进行操作时,如果显示错误码,错误码说明请参见《弹性云服务器用户指南》的常见问题“针对管理控制台的异常提示信息,应该如何处理”。
  • 下载OBS Browser+ 针对不同操作系统,OBS Browser+下载地址如表1所示。 表1 下载列表 支持平台 下载地址 Windows x32 OBSBrowserPlus-win32 OBSBrowserPlus-win32_sha256 Windows x64 OBSBrowserPlus-win64 OBSBrowserPlus-win64_sha256 Mac OBSBrowserPlus-Mac OBSBrowserPlus-Mac_sha256 OBS Browser+软件包下载地址是不带sha256后缀结尾的链接,带sha256后缀结尾的下载链接仅为对应软件包的完整性校验文件。例如:Windows x64版本的下载链接是OBSBrowserPlus-win64,它的校验文件下载链接则是OBSBrowserPlus-win64_sha256。 OBS Browser+最新版本将不支持Windows 7, Windows 8 和 Windows 8.1等旧版本的Windows,旧版Windows请使用OBSBrowserPlus_3.22.11-win64版本或OBSBrowserPlus_3.22.11-win32版本,并且3.22.11版本后续不再维护。
共100000条