2017-04-03 3 views
0

저는 우분투 컴퓨터에 Powershell을 설치했습니다. 내가 PowerShell을에 Login-AzureRmAccount를 입력 할 때, 나는 다음과 같은 오류가 발생합니다 : 내가 Get-Module -ListAvailable -Name Azure -Refresh를 입력하면우분투 : 'Login-AzureRmAccount'가 cmdlet의 이름으로 인식되지 않습니다.

PS> Login-AzureRmAccount                        
Login-AzureRmAccount : The term 'Login-AzureRmAccount' is not recognized as the name of a cmdlet, function, script file, or operable program. 
Check the spelling of the name, or if a path was included, verify that the path is correct and try again. 
At line:1 char:1 
+ Login-AzureRmAccount 
+ ~~~~~~~~~~~~~~~~~~~~ 
    + CategoryInfo   : ObjectNotFound: (Login-AzureRmAccount:String) [], CommandNotFoundException 

, 나는 어떤 결과를 얻을하지 않았다.

PowerShell을 버전 :

powershell -version 
powershell v6.0.0-alpha.17 

방법 위의 오류를 해결하기 위해?

+0

"Get-Module -ListAvailable"을 시도하면 모든 모듈을 볼 수 있으며 하늘색을 볼 수 있습니다. 그렇지 않으면 설치되지 않습니다. – Aravind

+0

안녕하세요, 당신의 우분투 버전은 무엇입니까? 우분투 14.0.4 또는 16? –

답변

3

는 먼저 푸른 PowerShell을 모듈을 설치해야합니다 : 이것은 내 테스트입니다

#Azure RM NetCore Preview Module Install 
powershell Install-Module AzureRM.NetCore.Preview 
powershell Import-Module AzureRM.NetCore.Preview 

.

[email protected]:/home# powershell 
PowerShell 
Copyright (C) 2016 Microsoft Corporation. All rights reserved. 

PS /home> Login-AzureRmAccount            
VERBOSE: To sign in, use a web browser to open the page https://aka.ms/devicelogin and enter the code F2RKUXRNE to authenticate. 

자세한 내용은이 link를 참조하십시오.

+0

이제 작동합니다. 먼저 PowerShell 버전을 설치하는 용도는 무엇입니까? – karan

+0

무엇을 의미합니까? –

+0

"powershell Install-Module AzureRM.NetCore.Preview"및 "powershell Import-Module AzureRM.NetCore.Preview"를 실행해야하는 이유는 무엇입니까? – karan

관련 문제