No response on "Run Command" option on Azure VM and Invoke-AzVMRunCommand (When I run the command, script with these mathods)

Sonu Kumar 11 Reputation points

Hello Guys,

We have multiple Azure VMs in environment but getting below issue on some of them.

Issue -

  1. When we run any command Or Script via "Run Command" option inside "Operations" of a Azure VM via Portal. And run any command like "Get-Service". The command always shows that "Executing" in output section. A complete black output windows and "Run" option grayed out which looks command executing but it never give result.
  2. On the same azure VM when we try to run any PowerShell script via command "Invoke-AzVMRunCommand" the same things happens.

Troubleshooting I tried :

No errors in VM agent logs on affected VM.
Extensions seems to be fine when I compared with non faulty VM

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,072 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. shiva patpi 13,131 Reputation points Microsoft Employee

    Hello @Sonu Kumar ,
    Can you try the same commands using CLI (instead of using the Azure Portal)?

    There are couple of examples mentioned in the above document. Check if you get responses using those commands.


    0 comments No comments

  2. Sonu Kumar 11 Reputation points

    Hi Shiva,

    Unfortunately same problem with Azure CLI . When we run same Power CLI command "az vm run-command invoke" on working VM it succeeded2. On Faulty server , command keep running