简体   繁体   English

主区域关闭时如何写入 Azure 存储?

[英]How to write to Azure storage when the primary region down?

Our application uses RA-GZRS for storage which enables to read data from the secondary when the primary is down, but can't write to it.我们的应用程序使用 RA-GZRS 进行存储,当主服务器关闭时,它可以从辅助服务器读取数据,但无法写入。

Is there a solution which enables application to do both read from and write to storage in the event of an Azure region going down?如果 Azure 区域出现故障,是否有一种解决方案可以使应用程序同时读取和写入存储?

In Azure Storage, there can be only one region (primary) where you can write.在 Azure 存储中,只能有一个区域(主)可以写入。 The other region (secondary) will always be read only.另一个区域(次要)将始终是只读的。

One possible solution would be to do a manual failover so that the secondary region of your account becomes the primary and then you should be able to write to it.一种可能的解决方案是进行手动故障转移,以便您帐户的次要区域成为主要区域,然后您应该能够对其进行写入。 However, please be aware that the manual failover comes with a lots of caveats and make sure you understand those.但是,请注意手动故障转移有很多注意事项,并确保您理解这些。

You can read more about those things here: https://docs.microsoft.com/en-us/azure/storage/common/storage-initiate-account-failover?tabs=azure-portal#important-implications-of-account-failover .您可以在此处阅读有关这些内容的更多信息: https://docs.microsoft.com/en-us/azure/storage/common/storage-initiate-account-failover?tabs=azure-portal#important-implications-of-account -故障转移

Please go through this .请通过go 。 To quote from the article:引用文章:

If the primary region becomes unavailable, you can choose to fail over to the secondary region.如果主要区域不可用,您可以选择故障转移到次要区域。 After the failover has completed, the secondary region becomes the primary region, and you can again read and write data .故障转移完成后,次要区域成为主要区域,您可以再次读取和写入数据 For more information on disaster recovery and to learn how to fail over to the secondary region, see Disaster recovery and storage account failover.有关灾难恢复的详细信息以及如何故障转移到次要区域,请参阅灾难恢复和存储帐户故障转移。

The tutorial here tells you how to build a highly available application that automatically switches between endpoints on a failure. 此处的教程将告诉您如何构建一个高可用性应用程序,该应用程序可在发生故障时在端点之间自动切换。 It uses a circuit breaker pattern.它使用断路器模式。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如果主区域关闭,则在RAGRS Azure存储队列的辅助区域中将消息标记为已完成 - Marking message as completed in secondary region of RAGRS Azure Storage Queue if primary regions is down Azure表存储主区域发生故障时,CloudTableClient.BaseUri.AbsoluteUri值是否会更改? - Does CloudTableClient.BaseUri.AbsoluteUri value changes when Azure Table Storage Primary region fails? 如何为Azure存储设置区域 - How to set a region for Azure Storage Azure 异地复制存储以允许在次要区域中写入 - Azure Geo-replicated Storage to Allow Write in Secondary Region Azure - 如何指定异地冗余存储的次要区域? - Azure - how to specify the secondary region for geo redundant storage? Windows Azure-如何更改表存储帐户的区域? - Windows Azure - how do you change the region of a Table Storage account? 如何将数据写入Azure存储表 - how to write data to azure storage tables 如何以编程方式在 Azure Blob 存储中写入数据? - How to write data in Azure Blob storage programmatically? 当主Azure SQL数据库出现故障时如何配置警报? - How to configure the alert whenever the primary Azure SQL Database goes down? 多区域Azure存储数据复制 - Multi region Azure Storage data replication
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM