In this article, you learn how to configure a zone-redundant Azure Cache instance using the Azure portal.
Azure Cache for Redis Standard, Premium, and Enterprise tiers provide built-in redundancy by hosting each cache on two dedicated virtual machines (VMs). Even though these VMs are located in separate Azure fault and update domains and highly available, they're susceptible to data center-level failures. Azure Cache for Redis also supports zone redundancy in its Standard, Premium, and Enterprise tiers. A zone-redundant cache runs on VMs spread across multiple Availability Zones. It provides higher resilience and availability.
PrerequisitesTo create a cache, follow these steps:
Sign in to the Azure portal and select Create a resource.
On the New page, select Databases and then select Azure Cache for Redis.
On the Basics page, configure the settings for your new cache.
Setting Suggested value Description Subscription Select your subscription. The subscription under which to create this new Azure Cache for Redis instance. Resource group Select a resource group, or select Create new and enter a new resource group name. Name for the resource group in which to create your cache and other resources. By putting all your app resources in one resource group, you can easily manage or delete them together. DNS name Enter a globally unique name. The cache name must be a string between 1 and 63 characters that contains only numbers, letters, or hyphens. The name must start and end with a number or letter, and can't contain consecutive hyphens. Your cache instance's host name will be <DNS name>.redis.cache.windows.net. Location Select a location. Select a region near other services that use your cache. Cache type Select a Premium or Enterprise tier cache. The pricing tier determines the size, performance, and features that are available for the cache. For more information, see Azure Cache for Redis Overview.Standard tier caches are always created as zone redundant using Automatic Zonal Allocation in the regions that support availability zones.
For Premium tier caches, select Advanced in the Resource menu. In regions that support zones, Zone redundancy for this tier can be enabled using couple of ways.
For an Enterprise tier cache, select Advanced in the Resource menu. For Zone redundancy, select Zone redundant (recommended).
Configure your settings for clustering and/or RDB persistence.
Note
Zone redundancy doesn't support Append-only File (AOF) persistence with multiple replicas (more than one replica).
Select Create.
It takes a while for the cache to be created. You can monitor progress on the Azure Cache for Redis Overview page. When Status shows as Running, the cache is ready to use.
Azure Cache for Redis automatically allocates zones to the cache on behalf of the user based on the number of nodes per shard and region's zonal support such that the cache is spread across multiple zones for high availability.
With this type of allocation, users don't need to worry about choosing zones manually. The actual zones that are allocated to the cache are abstracted from the user. Azure ensures that the cache's primary and replica nodes are spread across different zones for high availability.
The REST API spec for different types of zonal allocation can be found at: Create - ZonalAllocationPolicy.
If the property ZonalAllocationPolicy
is not passed in the request, Azure assigns its value for caches based on the region's zonal supportability and capacity.
The supported values for the property ZonalAllocationPolicy
are:
This value can be passed to let Azure allocate zones automatically to the cache.
In the regions that support zones, it is selected as default option for caches starting with 2024-11-01 API version if ZonalAllocationPolicy
isn't passed in the request.
Users are allowed to pass this value only for Premium caches and can be passed in the request body while manually selecting the zones.
Users are allowed to pass this value only for Premium caches. This is the only value supported in the regions that don't support zones.
It is selected as default option for caches if ZonalAllocationPolicy
isn't passed in the request in cases:
Important
Automatic Zonal Allocation can't be modified once enabled for a cache.
Important
ZonalAllocationPolicy
in the request, Azure will create a non-zonal cache which user can verify by checking the ZonalAllocationPolicy
property in the response.
ZonalAllocationPolicy
in the request body while creating the cache as it will enable Azure to choose the best option among Automatic, NoZones for the cache based on the region's zonal supportability and capacity. Otherwise, users can pass ZonalAllocationPolicy
if they want to explicitly use a specific zonal allocation policy.Zone redundancy is available only in Azure regions that have Availability Zones. See Azure regions with Availability Zones for the latest list.
Why can't I select all three zones during cache create?A Premium cache has one primary and one replica node by default. To configure zone redundancy for more than two Availability Zones, you need to add more replicas to the cache you're creating. The total number of availability zones must not exceed the combined count of nodes within the cache, including both the primary and replica nodes.
Can I update my existing Standard or Premium cache to use zone redundancy?Yes, updating an existing Standard or Premium cache to use zone redundancy is supported in-place. Users can enable it by navigating to the Advanced settings on the Resource menu and selecting Allocate Zones automatically check-box followed by the save button. You can't disable zone redundancy once you enable it.
For more details, look into Migrate an Azure Cache for Redis instance to availability zone support
This can also be done by passing ZonalAllocationPolicy
as Automatic
in the request body while updating the cache. For more information regarding the update process using REST API, see Update - ZonalAllocationPolicy.
ZonalAllocationPolicy
to any other value than Automatic
isn't supported.Important
Automatic Zonal Allocation can't be modified once enabled for a cache.
Important
Enabling Automatic Zonal Allocation for an existing cache (which is created with a different zonal allocation) is currently NOT supported for Geo Replicated caches or caches with VNet injection.
When your cache uses zone redundancy configured with multiple Availability Zones, data is replicated from the primary cache node in one zone to the other nodes in another zone. The data transfer charge is the network egress cost of data moving across the selected Availability Zones. For more information, see Bandwidth Pricing Details.
Next StepsLearn more about Azure Cache for Redis features.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4