![](/img/trans.png)
[英]az cmd “account clear” fails after “az storage blob upload-batch”
[英]az storage account: 'blob-service-properties' is not in the 'az storage account' command group
我想使用 CLI 啟用版本控制,更改 Azure 存儲帳戶中的提要。 我從 Microsoft 文檔https://docs.microsoft.com/en-us/cli/azure/storage/account/blob-service-properties?view=azure-cli-latest獲得了以下命令。
az storage account blob-service-properties update -n sdffsjhiwezzaz --enable-change-feed true --enable-versioning true --enable-delete-retention true --delete-retention-days 100
並得到以下錯誤
az storage account: 'blob-service-properties' is not in the 'az storage account' command group. See 'az storage account --help'.
請告訴我如何使用 Azure CLI 啟用版本控制和 ChangeFeed
我能夠成功運行命令。 請確保您安裝了最新版本的 CLI。
當我運行az --version
命令時,我看到的是:
azure-cli 2.2.0
command-modules-nspkg 2.0.3
core 2.2.0
nspkg 3.0.4
telemetry 1.0.4
此外,對於更改提要,您需要注冊訂閱此功能,因為它目前處於預覽狀態。 您可以在此處找到有關它的說明: https://docs.microsoft.com/en-us/azure/storage/blobs/storage-blob-change-feed?tabs=azure-portal#register-your-subscription-preview 。
我正在使用 azure-cli 2.27.1,發現這行得通。 不,語法略有不同
az storage blob service-properties update --account-name mystorageaccount --delete-retention true --delete-retention-period 5
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.