Azure / azure-cli

Azure Command-Line Interface
MIT License
4.01k stars 2.98k forks source link

az monitor autoscale create no longer working #9191

Closed bmukes closed 5 years ago

bmukes commented 5 years ago

Describe the bug When attempting to run az monitor autoscale create I always get the same error message error retrieving default location: Resource group '{resource group name}' could not be found.

To Reproduce Create a S2 (2) instance service plan for Windows.

Attempt to create an AutoScale as shown below I am using the ID of the service plan for the --resource parameter.

az monitor autoscale create --min-count 2 --max-count 4 --count 2 --resource "/subscriptions/{your subscription id}/resourceGroups/fse-bdy-prod-eu-rg/providers/Microsoft.Web/serverfarms/fse-bdy-prod-eu-sp" --tags OrganizationIdentifier="bdy" ProductName="fse" ResourceType="App Service AutoScale"

Expected behavior This worked without issue last week under cli version 2.0.61 and my scripts have not changed. I have even tried the command manually as indicated above. I even updated the CLI from 2.0.61 to 2.0.63 and the results are the same.

Environment summary I have telemetry turned off within the config file because creating an application gateway was never returning. I also tried removing the collect_telemetry entry same result. Here is my CLI config file [cloud] name = AzureCloud

[core] first_run = yes collect_telemetry = false

Powershell:

Name Value
PSVersion 6.1.2
PSEdition Core
GitCommitId 6.1.2
OS Microsoft Windows 10.0.17763
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0

AZ Version az --version

Column1 Column2
azure-cli 2.0.63
acr 2.2.5
acs 2.3.22
advisor 2.0.0
ams 0.4.5
appservice 0.2.18
backup 1.2.4
batch 4.0.0
batchai 0.4.8
billing 0.2.1
botservice 0.1.10
cdn 0.2.3
cloud 2.1.1
cognitiveservices 0.2.5
command-modules-nspkg 2.0.2
configure 2.0.22
consumption 0.4.2
container 0.3.16
core 2.0.63
cosmosdb 0.2.10
deploymentmanager 0.1.0
dla 0.2.5
dls 0.1.9
dms 0.1.3
eventgrid 0.2.3
eventhubs 0.3.4
extension 0.2.5
feedback 2.2.1
find 0.3.2
hdinsight 0.3.3
interactive 0.4.3
iot 0.3.8
iotcentral 0.1.6
keyvault 2.2.14
kusto 0.2.2
lab 0.1.7
maps 0.3.4
monitor 0.2.13
network 2.3.7
nspkg 3.0.3
policyinsights 0.1.2
privatedns 1.0.0
profile 2.1.5
rdbms 0.3.10
redis 0.4.2
relay 0.1.4
reservations 0.4.2
resource 2.1.14
role 2.6.0
search 0.1.1
security 0.1.1
servicebus 0.3.4
servicefabric 0.1.17
signalr 1.0.0
sql 2.2.2
sqlvm 0.1.1
storage 2.4.1
telemetry 1.0.2
vm 2.2.19
Python location 'C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\python.exe'
Extensions directory 'C:\Users\bdm0609.azure\cliextensions'

Python (Windows) 3.6.6 (v3.6.6:4cf1f54eb7, Jun 27 2018, 02:47:15) [MSC v.1900 32 bit (Intel)]

Additional context No Additional context

tjprescott commented 5 years ago

Thanks for the detailed report @bmukes. I will take a look.

tjprescott commented 5 years ago

I was not able to repro this. Does the resource group it complains about in fact exist?

bmukes commented 5 years ago

Yes the resource group exists.

But I think I have it figured out. I tested using a different Directory + subscription ‘InsTech FSPOC PROD’ and EVERYTHING WORKS But not under Directory + subscription ‘InsTech POC-2 Test’ I AM GETTING THE ERROR.

I was testing all last week using Directory + subscription ‘InsTech POC-2 Test’ and everything worked, but obviously something has changed within the subscription since last week. I will ask the owner of subscription to contact Microsoft Support because the command az monitor autoscale create does work.

Thanks for your help in this matter


Brian Mukes | Architect | INSURANCE TECHNOLOGIEShttp://www.insurancetechnologies.com/ t: +1 719.442.6400 | f: +719.442.0600

From: Travis Prescott notifications@github.com Sent: Wednesday, April 24, 2019 4:57 PM To: Azure/azure-cli azure-cli@noreply.github.com Cc: Mukes, Brian BMukes@InsuranceTechnologies.com; Mention mention@noreply.github.com Subject: Re: [Azure/azure-cli] az monitor autoscale create no longer working (#9191)

I was not able to repro this. Does the resource group it complains about in fact exist?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/Azure/azure-cli/issues/9191#issuecomment-486457851, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AAU2RRMGUBJK5ZMVC73MAXTPSDQTLANCNFSM4HIGX7SA.

Confidential and proprietary information may be contained in this communication, including attachments. If you are not the intended recipient, you must not use, copy, disclose, distribute or retain this communication or any part of it. Any unauthorized use, dissemination of the information, or copying of this message is prohibited. If you are not the intended addressee, please notify the sender immediately by return e-mail and permanently delete this message and any attachments.