你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

Azure Stack Edge Blob 存储要求

本文列出了能够与 Azure Stack Edge Blob 存储配合使用的 Azure API、Azure 客户端库和工具的版本。 Azure Stack Edge Blob 存储提供了具有 Azure 一致语义的 blob 管理功能。 本文还总结了已知 Azure Stack Edge Blob 存储与 Azure 存储服务的区别。

建议在连接到 Azure Stack Edge Blob 存储之前仔细审阅这些信息,然后在必要时再回头查阅。

存储差异

功能 Azure 存储 Azure Stack Edge Blob 存储
Azure 文件 支持基于云的 SMB 和 NFS 文件共享 不支持
存储帐户类型 常规用途和 Azure Blob 存储帐户 仅常规用途 v1
Blob 名称 1024 个字符(2048 个字节) 880 个字符(1760 个字节)
块 blob 最大大小 4.75 TiB(100 MiB X 50,000 块) 适用于 Azure Stack Edge 的 4.75 TiB(100 MiB x 50,000 块)
页 blob 最大大小 8 TiB 1 TiB
页 Blob 页面大小 512 字节 4 KiB

支持的 API 版本

以下版本的 Azure 存储服务 API 可以与 Azure Stack Edge Blob 存储配合使用。

Azure Stack Edge 2.1.1377.2170 及更高版本

支持的 Azure 客户端库

对于 Azure Stack Edge Blob 存储,有特定的客户端库和特定的终结点后缀要求。 Azure Stack Edge Blob 存储终结点与最新版 Azure Blob 存储 REST API 没有完全的奇偶一致性;请参阅 Azure Stack Edge 支持的 API 版本。 对于存储客户端库,需要了解与 REST API 兼容的版本。

Azure Stack Edge 2.1.1377.2170 及更高版本

Azure Stack Edge Blob 存储支持以下 Azure 客户端库版本。

客户端库 支持的版本 链接 终结点规范
.NET 11.0.0 NuGet 包:
通用:https://www.nuget.org/packages/Microsoft.Azure.Storage.Common/11.0.0
Blob:https://www.nuget.org/packages/Microsoft.Azure.Storage.Blob/11.0.0
队列:https://www.nuget.org/packages/Microsoft.Azure.Storage.Queue/11.0.0
GitHub 版本:https://github.com/Azure/azure-storage-net/releases/tag/v11.0.0
app.config 文件
Java 12.0.0-preview.3 Maven 包:https://mvnrepository.com/artifact/com.azure/azure-storage-file/12.0.0-preview.3
GitHub 版本:https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/storage
连接字符串设置
Node.js 2.8.3 NPM 链接:https://www.npmjs.com/package/azure-storage(运行:npm install azure-storage@2.7.0
GitHub 版本:https://github.com/Azure/azure-storage-node/releases/tag/v2.8.3
服务实例声明
C++ 5.2.0 NuGet 包:https://www.nuget.org/packages/wastorage.v140/5.2.0
GitHub 版本:https://github.com/Azure/azure-storage-cpp/releases/tag/v5.2.0
连接字符串设置
PHP 1.2.0 GitHub 版本:
通用:https://github.com/Azure/azure-storage-php/releases/tag/v1.2.0-common
Blob:https://github.com/Azure/azure-storage-php/releases/tag/v1.2.0-blob
通过 Composer 安装(若要了解更多内容,请参阅下面的详细信息。)
连接字符串设置
Python 1.1.0 GitHub 版本:
通用:https://github.com/Azure/azure-storage-python/releases/tag/v1.0.0-common
Blob:https://github.com/Azure/azure-storage-python/releases/tag/v1.1.0-blob
服务实例声明
Ruby 1.0.1 RubyGems 包:
通用:https://rubygems.org/gems/azure-storage-common/versions/1.0.1
Blob:https://rubygems.org/gems/azure-storage-blob/versions/1.0.1
GitHub 版本:
通用:https://github.com/Azure/azure-storage-ruby/releases/tag/v1.0.1-common
Blob:https://github.com/Azure/azure-storage-ruby/releases/tag/v1.0.1-blob
连接字符串设置

通过 Composer 安装 PHP 客户端 - 当前

若要通过 Composer 安装 PHP 客户端,请执行以下操作:

  1. 使用以下代码在项目的根目录中创建名为 composer.json 的文件(示例使用 Azure 存储 Blob 服务)。

    {
    "require": {
    "Microsoft/azure-storage-blob":"1.2.0"
    }
    
  2. composer.phar 下载到项目根目录。

  3. 运行:php composer.phar 安装。

终结点声明

在 Azure Stack Edge Blob 存储 SDK 中,终结点后缀 <device serial number>.microsoftdatabox.com 标识 Azure Stack Edge 域。 若要详细了解 blob 服务终结点,请转到使用 Azure Stack Edge Pro GPU 通过存储帐户传输数据

示例

.NET

对于 Azure Stack Edge Blob 存储,终结点后缀在 app.config 文件中指定:

<add key="StorageConnectionString"
value="DefaultEndpointsProtocol=https;AccountName=myaccount;AccountKey=mykey;
EndpointSuffix=<<serial no. of the device>.microsoftdatabox.com  />

Java

对于 Azure Stack Edge Blob 存储,终结点后缀在连接字符串的设置中指定:

public static final String storageConnectionString =
    "DefaultEndpointsProtocol=http;" +
    "AccountName=your_storage_account;" +
    "AccountKey=your_storage_account_key;" +
    "EndpointSuffix=<serial no. of the device>.microsoftdatabox.com ";

Node.js

对于 Azure Stack Edge Blob 存储,终结点后缀在声明实例中指定:

var blobSvc = azure.createBlobService('myaccount', 'mykey',
'myaccount.blob. <serial no. of the device>.microsoftdatabox.com ');

C++

对于 Azure Stack Edge Blob 存储,终结点后缀在连接字符串的设置中指定:

const utility::string_t storage_connection_string(U("DefaultEndpointsProtocol=https;
AccountName=your_storage_account;
AccountKey=your_storage_account_key;
EndpointSuffix=<serial no. of the device>.microsoftdatabox.com "));

PHP

对于 Azure Stack Edge Blob 存储,终结点后缀在连接字符串的设置中指定:

$connectionString = 'BlobEndpoint=http://<storage account name>.blob.<serial no. of the device>.microsoftdatabox.com /;
AccountName=<storage account name>;AccountKey=<storage account key>'

Python

对于 Azure Stack Edge Blob 存储,终结点后缀在声明实例中指定:

block_blob_service = BlockBlobService(account_name='myaccount',
account_key='mykey',
endpoint_suffix=’<serial no. of the device>.microsoftdatabox.com’)

Ruby

对于 Azure Stack Edge Blob 存储,终结点后缀在连接字符串的设置中指定:

set
AZURE_STORAGE_CONNECTION_STRING=DefaultEndpointsProtocol=https;
AccountName=myaccount;
AccountKey=mykey;
EndpointSuffix=<serial no. of the device>.microsoftdatabox.com

后续步骤