Hey Thomas, this was awesome! Thank you so much for carefully going through the example. This will be a very useful way for us to better manage our environment.
Amazing video, Thomas! Thank you! I've been wondering if it's possible to use this method through runbooks, but I believe that there is not command "code". Would be great if we could create something like a string into own code to write the ps1 file.
Brilliant video. Quick question, if you want to call the script from a runbook, where do you store the script. Can you upload the script to blob and call from there?
This is brilliant!...I did try run command in automation run book but the only problem is that it is not displaying the output result after running the script ..Any idea how I can get that?
Great video. I have been trying to use the same method to execute an existing python script on VM. But it says that Python is not installed, although it is. Any clue?
Thank you for this video it is great! Is it possible for example to run 'az version' on the remote vm? when I try this with scripts like you did I fail because 'az' is not recognized, but on the VM itself with Remote Desktop Connection it works
Hi, would it be possible to show an example of running a VM in interactive mode? This will help in setting up a testing pipeline which is going to pull latest automation scripts from azure git-repo into the vm, and then lanch the automation testing tool. Which will execute functional tests. I am struggling with invoking the vm/agent through the pipeline. Then I have to run automation tests on that agent/vm
@@Thomas_Maurer i have an issue with Parallel Script ForEach-Object : Parameter set cannot be resolved using the specified named parameters. At line:4 char:15 + $myAzureVMs | ForEach-Object -Parallel { + ~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : MetadataError: (:) [ForEach-Object], ParameterBindingException + FullyQualifiedErrorId : AmbiguousParameterSet,Microsoft.PowerShell.Commands.ForEachObjectCommand do you familiar with this ?
I think there is time out of 90 mins to run powershell script using this command on azure vm. Is there any alternative to this which can run for more than 90 mins. We need to run powershell scripts on vm which takes around 3 to 4 hrs.
Your video was HELFUL Thomas, INDEEED!!! thanks a lot Bro!!!! You´re a rockstar!!!!
thank you!
This video is gold! Thanks, Thomas!
Glad it was helpful!
Hey Thomas, this was awesome! Thank you so much for carefully going through the example. This will be a very useful way for us to better manage our environment.
Thank you for the feedback. Great to hear!
Amazing video, Thomas! Thank you!
I've been wondering if it's possible to use this method through runbooks, but I believe that there is not command "code". Would be great if we could create something like a string into own code to write the ps1 file.
Nice information ❤❤❤
Brilliant video. Quick question, if you want to call the script from a runbook, where do you store the script. Can you upload the script to blob and call from there?
Yes
This is brilliant!...I did try run command in automation run book but the only problem is that it is not displaying the output result after running the script ..Any idea how I can get that?
Is that fake bamboo tree behind you from Ikea? haha I have the same one.
Great video. I have been trying to use the same method to execute an existing python script on VM. But it says that Python is not installed, although it is. Any clue?
You need to install python on the hybrid worker nodes.
Thanks 🙂
You're welcome!
Thank you for this video it is great! Is it possible for example to run 'az version' on the remote vm? when I try this with scripts like you did I fail because 'az' is not recognized, but on the VM itself with Remote Desktop Connection it works
I needed a script to run at start up so off to find another video.
Hi, would it be possible to show an example of running a VM in interactive mode?
This will help in setting up a testing pipeline which is going to pull latest automation scripts from azure git-repo into the vm, and then lanch the automation testing tool. Which will execute functional tests.
I am struggling with invoking the vm/agent through the pipeline. Then I have to run automation tests on that agent/vm
@srajpoot1981 , Were you able to achieve what you mentioned above? I have a similar requirement and would be eager to know how you did it.
hi Thomas Maurer
is there any option if we can run this script for certain VMs we want instead of the entire resources group?
Yes I have a blog about that here: www.thomasmaurer.ch/2021/03/how-to-run-scripts-against-multiple-azure-vms-by-using-run-command/
@@Thomas_Maurer i have an issue with Parallel Script
ForEach-Object : Parameter set cannot be resolved using the specified named parameters.
At line:4 char:15
+ $myAzureVMs | ForEach-Object -Parallel {
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : MetadataError: (:) [ForEach-Object], ParameterBindingException
+ FullyQualifiedErrorId : AmbiguousParameterSet,Microsoft.PowerShell.Commands.ForEachObjectCommand
do you familiar with this ?
@@zzaidi_ what PowerShell version are you using?
Do you take powershell scripting coding
I am getting error at line 2: $out = Invoke-AzVMRunCommand "Cannot Index into a null array". How to resolve that ?
I think there is time out of 90 mins to run powershell script using this command on azure vm. Is there any alternative to this which can run for more than 90 mins. We need to run powershell scripts on vm which takes around 3 to 4 hrs.
Hi Thomas,
Thanks for a informative video, can you please let me know how do i run the "Invoke-AzVMRunCommand" through a function app or logic app.
yes you can do that :)
😁
You did not show the rest api way
Yes but we have some good docs on that on Microsoft Learn.