Questions tagged [azure-powershell]

The Azure module for PowerShell allows administrators to accomplish management tasks for Azure resources. The Az wrapper module includes only stable modules, the AzPreview wrapper module includes all PowerShell modules for Azure allowing to manage resources in all Azure services.

The Azure Modules for PowerShell allows administrators to accomplish many Azure management tasks through a series of cmdlets. The modules include the new Az module and the older AzureRM module (due to retire by Feb 2024).

References:

  1. Overview of Azure PowerShell

  2. PowerShell Module Browser: Search for PowerShell modules and cmdlets.

2843 questions
0
votes
1 answer

Not able to delete the Rewrite Rule Set from Azure Application Gateway

I am trying to delete the Rewrite Rule Set using AZ CLI and PowerShell but getting the below error. I tried creating the Rewrite Rule Set again and tried removing all the rules but when I am trying to delete it it is not working. Please…
0
votes
1 answer

Getting errors in azure powershell:

when i use in local i get this error : Az : The term 'Az' 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…
0
votes
1 answer

How to grant a service principal permissions to run Get-AZroleassignments? from azure devops pipeline

I want to get information about a service principal in an Azure PowerShell task in my DevOps pipeline using Get-AzRoleAssignment. Also, After getting the Az-roleAssignment, I want to do : New-AZroleasssignment. but I get this…
0
votes
0 answers

Azure IoT Hub: Configure Managed Identity via Powershell cmdlets

I create an Azure IoT Hub with Powershell cmdlets, using New-AzIotHub, somewhat similar to this. I want to use managed identity (system assigned) for my endpoints, and I can configure it properly in the Azure Portal: Looking through the docs, I…
abc
  • 2,285
  • 5
  • 29
  • 64
0
votes
2 answers

How to save a Azure Function output as csv file to Blob storage

I'm running a PowerShell script in Azure function (Timer Trigger) which will fetch PowerBI workspace data from Azure and it will store to Blob storage. I want the output data of the Azure function to be stored in csv format in Blob. Currently…
0
votes
1 answer

Supress logs while running Azure Powershell commands

I an running Azure Powershell commands where I will be adding the Network rules to storage account, diagnostic logs storage account and Keyvault and I am using the following Azure…
MathGeek
  • 511
  • 6
  • 17
0
votes
1 answer

Enable-AzDataCollection error while opening azure powershell

I am getting the following error while connecting the azure powershell and everytime I run command I get error reading or writing history file. Please can someone help me on this. Here is error i'm getting when I open the azure…
NIKI
  • 1
  • 3
0
votes
2 answers

Error while running Set-AzDiagnosticSetting command

I created a Service principal in azure and assigned my service principal to the custom role which I have created with set of permission in that particular subscription. With the service principal, I am able to create a key vault, Storage account,…
akhil
  • 1,649
  • 3
  • 19
  • 31
0
votes
2 answers

Azure Cloud Services Extended Support Deploy using New-AzCloudService powershell. Set swappable cloud service

Few days ago I moved my service from Azure Cloud Services classic to Cloud Services extended support. The latest doesn't have Production/Staging slots. There is a new swap mechanism that is activated if during a deploy we configured the "swappable…
mt_serg
  • 7,487
  • 4
  • 29
  • 45
0
votes
1 answer

JMESPath starts_with function fails using Azure Cli

In Microsoft Lab 09 > Exercise 4 > Task 1 > 2 it is instructed to list resource groups running the following command az group list --query "[?starts_with(name,'az400m10l01-RG')].name" --output tsv If I do run it, I get the following error ].name…
eliassal
  • 343
  • 5
  • 20
0
votes
1 answer

ERROR: Please run 'az login' to setup account

I'm facing this error on azure Devops pipeline. I've a power-shell script which I've triggered from my pipeline. Here's the ps script: $rgName = "fdevcusaks04-rg" $clusterName = "fdevcusaks04" $aksMcRg=…
0
votes
1 answer

Upload file using SFTP in PowerShell

I am trying the below command but didn't get any output: echo "put C:\Users\abhishek.chawla\Desktop\AbhishekC_bills.zip deployment/AbhishekC_bills.zip" | sftp TESTSHELTER@shelter-ftp.outlinesys.com Do I need to add the password too? If yes, then…
0
votes
1 answer

Invoke-ProcessTable : The provided application id is invalid

This is what I've got in my Invoke-ProcessTable powershell script (snippet) # create pscredential object $credObject = New-Object -TypeName System.Management.Automation.PSCredential ` -ArgumentList $ServicePrincipal,…
0
votes
0 answers

System.String[] Error while exporting csv for Azure Policy Assignment

I wrote the below powershell script to get all Azure policy assignment within an azure subscription but when I try to export the result using Export-CSV, I get a System.String[] error for the NotScope row. Get-AzResourceGroup | Select-Object …
0
votes
1 answer

managed identity for this assignment does not have the appropriate permissions to remediate these resources. Edit Assignment page and re-save it

I have a requirement of creating policy assignment from policy initiative and do remediation. I can create assignment using the below command. $newRgAssignment = New-AzPolicyAssignment -Name $assigName -PolicySetDefinition $policySet…
user6264
  • 175
  • 1
  • 7
  • 22
1 2 3
99
100