您现在访问的是微软AZURE全球版技术文档网站,若需要访问由世纪互联运营的MICROSOFT AZURE中国区技术文档网站,请访问 https://docs.azure.cn.

Azure Redis 缓存高级层简介Introduction to the Azure Cache for Redis Premium tier

Azure Redis 缓存是一种分布式托管缓存,可提供对数据的超快访问,有助于生成高度可缩放且响应速度快的应用程序。Azure Cache for Redis is a distributed, managed cache that helps you build highly scalable and responsive applications by providing super-fast access to your data.

新的高级层可供企业立即使用,除了标准层的所有功能以外,它还包括其他优势,例如更好的性能、更大的工作负荷、灾难恢复、导入/导出和增强的安全性。The new Premium-tier is an Enterprise ready tier, which includes all the Standard-tier features and more, such as better performance, bigger workloads, disaster recovery, import/export, and enhanced security. 请继续阅读,以深入了解高级缓存层的其他功能。Continue reading to learn more about the additional features of the Premium cache tier.

与标准或基本层相比性能更佳Better performance compared to Standard or Basic tier

性能优于标准或基本层。Better performance over Standard or Basic tier. 相对于基本级别或标准级别,高级层的缓存部署在处理器速度更快且性能更高的硬件上。Caches in the Premium tier are deployed on hardware which has faster processors and gives better performance compared to the Basic or Standard Tier. 高级级别缓存的吞吐量更高,延迟更低。Premium tier Caches have higher throughput and lower latencies.

如果缓存大小相同,高级层中的吞吐量高于标准层。Throughput for the same sized Cache is higher in Premium as compared to Standard tier. 例如,就 53 GB 的吞吐量而言,P4(高级层)的缓存是每秒 250K 个请求,相比之下,C6(标准层)只有 150K 个。For example, the throughput of a 53 GB P4 (Premium) cache is 250K requests per second as compared to 150K for C6 (Standard).

有关高级缓存大小、吞吐量和带宽的详细信息,请参阅 Azure Redis 缓存常见问题解答For more information about size, throughput, and bandwidth with premium caches, see Azure Cache for Redis FAQ

Redis 数据持久性Redis data persistence

高级层允许将缓存数据暂留在 Azure 存储帐户中。The Premium tier allows you to persist the cache data in an Azure Storage account. 在基本/标准缓存中,所有数据只存储在内存中。In a Basic/Standard cache all the data is stored only in memory. 如果底层基础结构出现问题,可能会导致数据丢失。In case of underlying infrastructure issues there can be potential data loss. 我们建议使用高级级别中的 Redis 数据暂留功能来增加灵活性,防止数据丢失。We recommend using the Redis data persistence feature in the Premium tier to increase resiliency against data loss. Azure Redis 缓存提供可在 Redis 暂留中使用的 RDB 和 AOF(即将推出)选项。Azure Cache for Redis offers RDB and AOF (coming soon) options in Redis persistence.

有关配置暂留的说明,请参阅如何为高级 Azure Redis 缓存配置暂留For instructions on configuring persistence, see How to configure persistence for a Premium Azure Cache for Redis.

Redis 群集Redis cluster

如果想要创建大于 53 GB 的缓存,或者想要将数据通过分片的方式分散到多个 Redis 节点中,则可以使用在高级层中提供的 Redis 群集功能。If you want to create caches larger than 53 GB or want to shard data across multiple Redis nodes, you can use Redis clustering which is available in the Premium tier. 每个节点都包含一个由 Azure 管理的主/副缓存对,目的是提高可用性。Each node consists of a primary/replica cache pair managed by Azure for high availability.

Redis 群集可提供最大的缩放能力和吞吐量。Redis clustering gives you maximum scale and throughput. 增加群集中分片(节点)的数量会导致吞吐量线性提高。Throughput increases linearly as you increase the number of shards (nodes) in the cluster. 例如Eg. 如果创建了一个包含 10 个分片的 P4 群集,则可用吞吐量为 250K * 10 = 每秒 250 万个请求。If you create a P4 cluster of 10 shards, then the available throughput is 250K *10 = 2.5 Million requests per second. 有关高级缓存大小、吞吐量和带宽的更多详细信息,请参阅 Azure Redis 缓存常见问题Please see the Azure Cache for Redis FAQ for more details about size, throughput, and bandwidth with premium caches.

若要开始使用群集,请参阅如何为高级 Azure Redis 缓存配置群集功能To get started with clustering, see How to configure clustering for a Premium Azure Cache for Redis.

增强的安全性和隔离性Enhanced security and isolation

可通过公共 Internet 访问基本或标准层中创建的缓存。Caches created in the Basic or Standard tier are accessible on the public internet. 根据访问密钥来限制对缓存的访问。Access to the Cache is restricted based on the access key. 使用高级层可以进一步确保只有指定网络中的客户端可以访问缓存。With the Premium tier you can further ensure that only clients within a specified network can access the Cache. 可以在 Azure 虚拟网络 (VNet) 中部署 Azure Redis 缓存。You can deploy Azure Cache for Redis in an Azure Virtual Network (VNet). 可以使用 VNet 的所有功能,例如子网、访问控制策略和其他功能,进一步限制对 Redis 的访问。You can use all the features of VNet such as subnets, access control policies, and other features to further restrict access to Redis.

有关详细信息,请参阅 如何为高级 Azure Redis 缓存配置虚拟网络支持For more information, see How to configure Virtual Network support for a Premium Azure Cache for Redis.


导入/导出是一种 Azure Redis 缓存数据管理操作,可用于通过从高级缓存导入 Azure Redis 缓存数据库 (RDB) 快照以及将 Azure Redis 缓存数据库 (RDB) 快照导出到 Azure 存储帐户中的页 blob 来相应地将数据导入到 Azure Redis 缓存以及从 Azure Redis 缓存导出数据。Import/Export is an Azure Cache for Redis data management operation which allows you to import data into Azure Cache for Redis or export data from Azure Cache for Redis by importing and exporting an Azure Cache for Redis Database (RDB) snapshot from a premium cache to a page blob in an Azure Storage Account. 这会允许在不同 Azure Redis 缓存实例之间进行迁移,或者在使用之前使用数据填充缓存。This enables you to migrate between different Azure Cache for Redis instances or populate the cache with data before use.

导入可用于从任何云或环境中运行的任何 Redis 服务器引入与 Redis 兼容的 RDB 文件,包括在 Linux、Windows 上运行的 Redis 或任何云提供程序(如 Amazon Web Services 等)。Import can be used to bring Redis compatible RDB file(s) from any Redis server running in any cloud or environment, including Redis running on Linux, Windows, or any cloud provider such as Amazon Web Services and others. 导入数据是使用预先填充的数据创建缓存的简单方式。Importing data is an easy way to create a cache with pre-populated data. 在导入过程中,Azure Redis 缓存从 Azure 存储将 RDB 文件加载到内存中,再将密钥插入到缓存中。During the import process, Azure Cache for Redis loads the RDB files from Azure storage into memory and then inserts the keys into the cache.

使用导出可以将 Azure Redis 缓存中存储的数据导出到与 Redis 兼容的 RDB 文件。Export allows you to export the data stored in Azure Cache for Redis to Redis compatible RDB file(s). 可以使用此功能将一个 Azure Redis 缓存实例中的数据移到另一个 Azure Redis 缓存实例或另一个 Redis 服务器。You can use this feature to move data from one Azure Cache for Redis instance to another or to another Redis server. 在导出过程中,会在托管 Azure Redis 缓存服务器实例的 VM 上创建临时文件,并将该文件上传到指定的存储帐户。During the export process, a temporary file is created on the VM that hosts the Azure Cache for Redis server instance, and the file is uploaded to the designated storage account. 导出操作完成后,无论状态为成功还是失败,都会删除临时文件。When the export operation completes with either a status of success or failure, the temporary file is deleted.

有关详细信息,请参阅如何在 Azure Redis 缓存中导入和导出数据For more information, see How to import data into and export data from Azure Cache for Redis.


可以根据需要通过高级层重新启动缓存的一个或多个节点。The premium tier allows you to reboot one or more nodes of your cache on-demand. 这可以测试应用程序在故障时的还原能力。This allows you to test your application for resiliency in the event of a failure. 可以重新启动下列节点。You can reboot the following nodes.

  • 缓存的主节点Master node of your cache
  • 缓存的辅助节点Secondary node of your cache
  • 缓存的主节点和辅助节点Both primary and secondary nodes of your cache
  • 使用高级缓存来执行群集功能时,可以针对缓存中的各个分片重新启动主节点和/或辅助节点When using a premium cache with clustering, you can reboot the primary, secondary, or both nodes for individual shards in the cache

有关详细信息,请参阅重新启动重新启动常见问题For more information, see Reboot and Reboot FAQ.


现已为所有 Azure Redis 缓存层启动“重新启动”功能。Reboot functionality is now enabled for all Azure Cache for Redis tiers.

计划更新Schedule updates

可以通过计划更新功能指定缓存的维护时段。The scheduled updates feature allows you to designate a maintenance window for your cache. 指定维护时段后,会在此时段内进行任何 Redis 服务器更新。When the maintenance window is specified, any Redis server updates are made during this window. 要指定维护时段,请选择合适的日期,并指定每天的维护时段开始时间。To designate a maintenance window, select the desired days and specify the maintenance window start hour for each day. 请注意,维护时段使用 UTC 时间。Note that the maintenance window time is in UTC.

有关详细信息,请参阅计划更新计划更新常见问题For more information, see Schedule updates and Schedule updates FAQ.


仅在计划的维护时段进行 Redis 服务器更新。Only Redis server updates are made during the scheduled maintenance window. 维护时段不适用于 Azure 更新或 VM 操作系统更新。The maintenance window does not apply to Azure updates or updates to the VM operating system.


“异地复制”提供一种用于链接两个高级层 Azure Redis 缓存实例的机制。Geo-replication provides a mechanism for linking two Premium tier Azure Cache for Redis instances. 一个缓存指定为主链接缓存,另一个缓存指定为辅助链接缓存。One cache is designated as the primary linked cache, and the other as the secondary linked cache. 辅助链接缓存将变为只读,写入主缓存的数据将复制到辅助链接缓存。The secondary linked cache becomes read-only, and data written to the primary cache is replicated to the secondary linked cache. 此功能可用于跨 Azure 区域复制缓存。This functionality can be used to replicate a cache across Azure regions.

有关详细信息,请参阅如何为 Azure Redis 缓存配置异地复制功能For more information, see How to configure Geo-replication for Azure Cache for Redis.

伸缩到高级层To scale to the premium tier

若要伸缩到高级层,请直接在“更改定价层”边栏选项卡中选择一个高级层。To scale to the premium tier, simply choose one of the premium tiers in the Change pricing tier blade. 也可使用 PowerShell 和 CLI 将缓存伸缩到高级层。You can also scale your cache to the premium tier using PowerShell and CLI. 有关分步说明,请参阅如何缩放 Azure Redis 缓存如何自动执行缩放操作For step-by-step instructions, see How to Scale Azure Cache for Redis and How to automate a scaling operation.

后续步骤Next steps

创建缓存并探索高级层的新功能。Create a cache and explore the new premium tier features.