2017-04-11 133 views
2

我正在设置生产版本并因此在门户中创建所有新服务。我正在努力创建一个存储帐户,这将允许我创建Azure表。目前我正在使用NLOG Azure存储,并且在需要时总是创建表(如果我手动删除它们,请重新运行我的应用程序,它将重新创建)。Azure门户中缺少表存储

如果我尝试手动创建表我得到一个错误(见下面的代码)

CloudStorageAccount storageAccount = CloudStorageAccount.Parse(Configuration.AzureStorageConnectionString); 
// Create the table client. 
CloudTableClient tableClient = storageAccount.CreateCloudTableClient(); 
CloudTable table = tableClient.GetTableReference("TestTable"); 
// Create the CloudTable if it does not exist 
bool test = table.CreateIfNotExists(); 

我很容易,但无法创造斑点用表。我们以前的(分段)存储帐户是在旧门户上创建的,如果这有所作为?

这里是我的配置:

<add key="AzureStorageConnectionString" value="DefaultEndpointsProtocol=https;AccountName=productionhalostorage;AccountKey=abc;EndpointSuffix=core.windows.net" 
    xdt:Transform="Replace" 
    xdt:Locator="Match(key)" /> 

忽略XDT的我使用慢猎豹维护我们的configs。

+1

你能分享你得到的错误吗? – Aravind

回答

2

请检查有问题的存储帐户的类型。它应该是Standard存储帐户,而不是Blob Storage帐户,因为Blob Storage帐户不支持表。

如果账户类型为Standard,请检查该账户的冗余类型。它不应该是ZRSPremium LRS,因为这些冗余类型也不支持表。

+0

好东西!非常感谢! – David