Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
408 views
in Technique[技术] by (71.8m points)

Connecting Azure account from PowerShell is not happening due to error in description

Connecting Azure account from PowerShell is not happening due to error in description.

PS C:WINDOWSsystem32> Connect-AzAccount
WARNING: Unable to acquire token for tenant '36ff3f25-cbe8-48b8-ba26-58974869160e'
WARNING: Unable to set default context 'Microsoft.Azure.Commands.Common.Authentication.Abstractions.AzureContext'.
Connect-AzAccount : Run Connect-AzAccount to login.
At line:1 char:1
+ Connect-AzAccount
+ ~~~~~~~~~~~~~~~~~
    + CategoryInfo          : CloseError: (:) [Connect-AzAccount], PSInvalidOperationException
    + FullyQualifiedErrorId : Microsoft.Azure.Commands.Profile.ConnectAzureRmAccountCommand

How to resolve this?

question from:https://stackoverflow.com/questions/66052607/connecting-azure-account-from-powershell-is-not-happening-due-to-error-in-descri

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

If it runs normally before, it is recommended to manually delete the two files AzureRMContext.json and AzureRmContextSettings.json. You can find them in the C:UsersAdministrator.azure folder. Or run command Clear-AzContext.

enter image description here


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...