Scripting and Command Line Tools

Azure provides two command line tools – PowerShell and Cross-Platform CLI – for you to manage your Azure subscriptions, accelerate your development and automate tasks via scripting, no matter whether you are on Windows, Mac or Linux.

If you have any feedback on Azure PowerShell or Azure Cross-Platform CLI, we’d love to hear it.

How can we improve the Azure command line tools and scripting experience?

You've used all your votes and won't be able to post a new idea, but you can still search and comment on existing ideas.

There are two ways to get more votes:

  • When an admin closes an idea you've voted on, you'll get your votes back from that idea.
  • You can remove your votes from an open idea you support.
  • To see ideas you have already voted on, select the "My feedback" filter and select "My open ideas".
(thinking…)

Enter your idea and we'll search to see if someone has already suggested it.

If a similar idea already exists, you can support and comment on it.

If it doesn't exist, you can post your idea so others can support it.

Enter your idea and we'll search to see if someone has already suggested it.

  1. Generate PowerShell Script from actions user takes in Azure Management Portal.

    When a user performs one or more action in the Azure Management Portal that results in an activity in Azure the equivalent PowerShell scriptlet should be generated and the user be allowed to download it. This is similar to other Microsoft products that provide PowerShell script access for actions completed via the UI.

    379 votes
    Vote
    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)
      You have left! (?) (thinking…)
      5 comments  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →

      This is a great idea. We are thinking about adding such functionality to the Portal. No confirmed plan yet. Thanks.

    • Windows Azure VM Documentor

      This script should export the VM configuration like roles, drive configuration, memory, CPU, network settings to a csv file and Visio

      194 votes
      Vote
      Sign in
      Check!
      (thinking…)
      Reset
      or sign in with
      • facebook
      • google
        Password icon
        I agree to the terms of service
        Signed in as (Sign out)
        You have left! (?) (thinking…)
        under review  ·  1 comment  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
      • Endpoint Notification / Audit

        I would like a powershell script that will go out and discovery any/all configured endpoints (anytime a VM in IaaS is using an Azure public IP). Produce a list of all endpoints, with IPs and ports.

        This is to prevent the use of public endpoints on VMs running in Azure when we have a VPN into a private vNET. The code below almost does what I'm looking for but not able to get back every port.

        foreach ($item in Get-AzureService)
        {
        Get-AzureVM -ServiceName $item.Label -Name $item.Label| where {$_.PowerState -eq "Started"}
        @{
        #Name = "RDP";
        Expression = { ($_ | Get-AzureEndpoint…

        158 votes
        Vote
        Sign in
        Check!
        (thinking…)
        Reset
        or sign in with
        • facebook
        • google
          Password icon
          I agree to the terms of service
          Signed in as (Sign out)
          You have left! (?) (thinking…)
          2 comments  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →

          We will see whether there is a way to do this with the Current Windows Azure PowerShell and if not, what it would take to provide such functionality.

        • Create PowerShell scripts to configure monitoring and alert

          Create PowerShell scripts to configure the monitoring level (minimal or verbose), the Metrics that appear in the Dashboard and the Alerts on that Metrics.

          42 votes
          Vote
          Sign in
          Check!
          (thinking…)
          Reset
          or sign in with
          • facebook
          • google
            Password icon
            I agree to the terms of service
            Signed in as (Sign out)
            You have left! (?) (thinking…)
            1 comment  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
          • Powershell Cmdlet for Azure Mobile Services

            Should have a set of cmdlets for Azure Powershell to manage Azure Mobile Services in the same way you manage websites and cloud services.

            34 votes
            Vote
            Sign in
            Check!
            (thinking…)
            Reset
            or sign in with
            • facebook
            • google
              Password icon
              I agree to the terms of service
              Signed in as (Sign out)
              You have left! (?) (thinking…)
              0 comments  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
            • PowerShell scripts for Azure ServiceBus management features

              I was looking the PowerShell CmdLet reference for managing the Azure ServiceBus. Although there is a REST API available, I would like to have CmdLets for creating/deleting queues, topics, subscriptions and manage rules.

              Is this planned or scheduled in a future release?

              31 votes
              Vote
              Sign in
              Check!
              (thinking…)
              Reset
              or sign in with
              • facebook
              • google
                Password icon
                I agree to the terms of service
                Signed in as (Sign out)
                You have left! (?) (thinking…)
                1 comment  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
              • Add more info to Login-AzureRMAccount in case of issue

                For ASM model we have useful info if login was not successful if we have issue with firewall.
                But ARM just "swallowing" exception without any explanation. Example in attachment

                30 votes
                Vote
                Sign in
                Check!
                (thinking…)
                Reset
                or sign in with
                • facebook
                • google
                  Password icon
                  I agree to the terms of service
                  Signed in as (Sign out)
                  You have left! (?) (thinking…)
                  0 comments  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
                • powershell timeout

                  For all Azure Powershell commands that perform the API function of "Put Blob", such as Set-AzureDeployment, Set-AzureStorageBlobContent, and New-AzureDeployment, add a command parameter for the "timeout" URI parameter passed via the API. Currently, any such Powershell command results in a static "timeout" value of 90 (seconds) being passed via the API.

                  Impact: Being able to define a "timeout" would be valuable for clients using PowerShell that have larger packages, slower connections, or the need to troubleshoot storage exceptions during storage or deployment operations.

                  24 votes
                  Vote
                  Sign in
                  Check!
                  (thinking…)
                  Reset
                  or sign in with
                  • facebook
                  • google
                    Password icon
                    I agree to the terms of service
                    Signed in as (Sign out)
                    You have left! (?) (thinking…)
                    1 comment  ·  Flag idea as inappropriate…  ·  Admin →
                  • Powershell Support for Azure storage Table

                    We heavily use Azure storage table and we don't support for managing and querying Azure storage tables. I am in support and not so in C#, but good at powershell.

                    Can we get some sample scripts on like querying the Azure storage table based on .net class that are available for Azure storage table.

                    24 votes
                    Vote
                    Sign in
                    Check!
                    (thinking…)
                    Reset
                    or sign in with
                    • facebook
                    • google
                      Password icon
                      I agree to the terms of service
                      Signed in as (Sign out)
                      You have left! (?) (thinking…)
                      1 comment  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
                    • cost monitoring script

                      It would be great to have an API to monitor cost within Azure.
                      Each team within an organization is given a cloud service and possibly a storage account.
                      Using powershell we can track/monitor cost per team and raise alerts if the cost becomes too high.

                      23 votes
                      Vote
                      Sign in
                      Check!
                      (thinking…)
                      Reset
                      or sign in with
                      • facebook
                      • google
                        Password icon
                        I agree to the terms of service
                        Signed in as (Sign out)
                        You have left! (?) (thinking…)
                        0 comments  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
                      • create the Powershell (if possible CLI tools also) for Windows RT

                        Wouldn't it be great for IT Pro's / Admins to have the Powershell CMDLet on Windows RT too?

                        18 votes
                        Vote
                        Sign in
                        Check!
                        (thinking…)
                        Reset
                        or sign in with
                        • facebook
                        • google
                          Password icon
                          I agree to the terms of service
                          Signed in as (Sign out)
                          You have left! (?) (thinking…)
                          0 comments  ·  Flag idea as inappropriate…  ·  Admin →

                          Would love to see how many people actually do this on a daily basis. Also, this requires all the code we use in PowerShell to be PCL. Doable but need to understand the value first.

                        • Network and Firewall Logs

                          It would be ideal if we could get the logs from the network and firewalls. I see that there are diagnostics available for the VPN but it would be ideal to see activity on the firewall and be able to put those logs into System Center or a syslog server or a system like LogRhythm for security analysis.

                          17 votes
                          Vote
                          Sign in
                          Check!
                          (thinking…)
                          Reset
                          or sign in with
                          • facebook
                          • google
                            Password icon
                            I agree to the terms of service
                            Signed in as (Sign out)
                            You have left! (?) (thinking…)
                            1 comment  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
                          • Ensure the Powershell cmdlets are suitable for scripting, not just interactive use, by supporting the Get-OperationStatus cmdlet

                            The Codeplex versions of the PowerShell cmdlets supported Get-OperationStatus, which caused the script to wait until a previous operation was complete. This allowed scripting of deployments.

                            Without this the PowerShell cmdlets are of little use for continuous deployment scripting.

                            17 votes
                            Vote
                            Sign in
                            Check!
                            (thinking…)
                            Reset
                            or sign in with
                            • facebook
                            • google
                              Password icon
                              I agree to the terms of service
                              Signed in as (Sign out)
                              You have left! (?) (thinking…)
                              1 comment  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →

                              We understand the needs. Will think about besides expose the cmdlet, what else do we need to make it good for scripting.

                            • Cleanup Services, VM's & VHD's deployed under a Cloud Service

                              <#
                              # PowerShell script to delete all VM's created under a Cloud Service.
                              It also delete the VHDs from the storage
                              #>

                              $subscription = Read-Host "Enter your Subscription Name"
                              Select-AzureSubscription –Default $subscription
                              Get-AzureService |
                              Select-Object @{"Label"="ServiceName";Expression={$_.Label}} |
                              Out-GridView -Title "Select VM Deployments to Remove" -PassThru |
                              ForEach-Object { Remove-AzureDeployment -ServiceName $_.ServiceName -Slot Production -DeleteVHD -Force
                              Remove-AzureService -ServiceName $_.ServiceName -Force }

                              15 votes
                              Vote
                              Sign in
                              Check!
                              (thinking…)
                              Reset
                              or sign in with
                              • facebook
                              • google
                                Password icon
                                I agree to the terms of service
                                Signed in as (Sign out)
                                You have left! (?) (thinking…)
                                0 comments  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
                              • Deploy Multiple Domain joined Azure VM's in a new or existing Cloud Service

                                <#
                                # .SYNOPSIS
                                The script is designed to create Multiple Azure VM's and join them to the specified domain while creation.
                                Using this script you can achieve:
                                1.Create Multiple Azure VM's under the same Cloud Service
                                2.Add additional Azure VM's under an already created Cloud Service

                                Requirements:
                                1.Azure Powershell Module installed in the machine.
                                2.Your Subscription Name, you need to specify the subscription name while using the script.
                                3.Pre-created Affinity Group, you need to specify the name while using the script.
                                4.Pre-created Storage in Azure, you need to specify the storage name while using the script.
                                5.Pre-created Virtual Network in…

                                12 votes
                                Vote
                                Sign in
                                Check!
                                (thinking…)
                                Reset
                                or sign in with
                                • facebook
                                • google
                                  Password icon
                                  I agree to the terms of service
                                  Signed in as (Sign out)
                                  You have left! (?) (thinking…)
                                  0 comments  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
                                • Remove Azure VNet Using PowerShell Script

                                  Hi Guys,

                                  I am trying to remove the vnet from my subscription using power shell script but I am not able to find any way. I am also refer some blog for the same and I am not able to find it.

                                  So can you suggest me, How can I remove vnet using power shell?

                                  12 votes
                                  Vote
                                  Sign in
                                  Check!
                                  (thinking…)
                                  Reset
                                  or sign in with
                                  • facebook
                                  • google
                                    Password icon
                                    I agree to the terms of service
                                    Signed in as (Sign out)
                                    You have left! (?) (thinking…)
                                    0 comments  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
                                  • Identify the co-administrators in with a powershell cmdlet

                                    Need a way to view the administrators and co-administrators within a subscription

                                    11 votes
                                    Vote
                                    Sign in
                                    Check!
                                    (thinking…)
                                    Reset
                                    or sign in with
                                    • facebook
                                    • google
                                      Password icon
                                      I agree to the terms of service
                                      Signed in as (Sign out)
                                      You have left! (?) (thinking…)
                                      1 comment  ·  Powershell  ·  Flag idea as inappropriate…  ·  Admin →
                                    • Support Worker Role in Powershell

                                      Poweshell has all the ability of a .NET program and it's quick and easy to write a script. Allow us to create a worker role in Powershell.

                                      10 votes
                                      Vote
                                      Sign in
                                      Check!
                                      (thinking…)
                                      Reset
                                      or sign in with
                                      • facebook
                                      • google
                                        Password icon
                                        I agree to the terms of service
                                        Signed in as (Sign out)
                                        You have left! (?) (thinking…)
                                        2 comments  ·  Flag idea as inappropriate…  ·  Admin →

                                        Just to make sure I understand it correctly. So the idea is having a work role implemented in PowerShell scripts so that people can run PowerShell scripts in a cloud service?

                                      • unable to use azure powershell with dreamspark

                                        I get the following error:
                                        Get-AzureWebsite : Communication could not be established. This could be due to an
                                        invalid subscription ID. Note that subscription IDs are case sensitive.

                                        Get-AzureWebsite : ForbiddenError: The server failed to authenticate the request.
                                        Verify that the certificate is valid and is associated with this subscription.
                                        In Zeile:1 Zeichen:1
                                        But the ID is correct

                                        9 votes
                                        Vote
                                        Sign in
                                        Check!
                                        (thinking…)
                                        Reset
                                        or sign in with
                                        • facebook
                                        • google
                                          Password icon
                                          I agree to the terms of service
                                          Signed in as (Sign out)
                                          You have left! (?) (thinking…)
                                          1 comment  ·  Flag idea as inappropriate…  ·  Admin →
                                        • API or PowerShell cmdlet that allow us to create subscriptions programmatically

                                          The isolation provided at the subscription level can solve several business problems. If we were able to automate the creation of a subscription as part of the deployment, it would allow us to deploy an entire project into our tenant/account without manual tasks.
                                          Parameters or Portal settings could be used for things like credit card and administrators.

                                          9 votes
                                          Vote
                                          Sign in
                                          Check!
                                          (thinking…)
                                          Reset
                                          or sign in with
                                          • facebook
                                          • google
                                            Password icon
                                            I agree to the terms of service
                                            Signed in as (Sign out)
                                            You have left! (?) (thinking…)
                                            0 comments  ·  Flag idea as inappropriate…  ·  Admin →
                                          ← Previous 1 3
                                          • Don't see your idea?

                                          Scripting and Command Line Tools

                                          Feedback and Knowledge Base