Azure门户中自动化帐户中的Powershell Runbook故障 [英] Powershell Runbook failure in Automation Account in Azure Portal

查看:87
本文介绍了Azure门户中自动化帐户中的Powershell Runbook故障的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,


我正在尝试在门户网站的azure自动化帐户中运行powershell Runbook,但是一旦完成这项工作,我就会收到以下错误。


请帮我解决这个问题。



解决方案

您好Sayyad,


感谢您的联系!


从错误的初步分析来看,似乎没有创建文件'C:\ Passass\passwordnew.txt'是由于Get-credential命令行开关的使用不正确。


Get-credential命令行开关始终提示用户输入,您无法提供文件作为输入。 


请在下方查看Get-credential的正确用法。


https://docs.microsoft.com/en-us/powers hell / module / microsoft.powershell.security / get-credential?view = powershell-6


希望这会有所帮助!


Hi All,

I am trying to run the powershell runbook in my azure automation account in portal but I am getting the below error once completed the job.

Please help me out on this.

解决方案

Hi Sayyad,

Thanks for reaching out!

From the preliminary analysis of the errors, it seems that the file 'C:\Passwords\passwordnew.txt' is not getting created and that is because of the incorrect use of Get-credential commandlet.

The Get-credential commandlet always prompts for user input and you cannot provide a file as an input to it. 

Please see the correct usage of Get-credential below.

https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.security/get-credential?view=powershell-6

Hope this helps!


这篇关于Azure门户中自动化帐户中的Powershell Runbook故障的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆