Did anything change in the implementation the past few weeks? This documentation used to work, but now getting this error despite all the arguments being correct. The app registration client ID --aad-client-app-id
) noted in the error message definitely exists in the target --aad-tenant-id
.......
```
az aks create \
--resource-group myk8rg \
--kubernetes-version 1.13.5 \
--enable-rbac \
--name $CLUSTER_NAME \
--admin-username myadmin \
--ssh-key-value ~/.ssh/myadmin.id_rsa.pub \
--dns-name-prefix $CLUSTER_NAME \
--node-vm-size Standard_DS2_v2 \
--node-count 1 \
--max-pods 50 \
--network-plugin kubenet \
--service-cidr 10.0.0.0/16 \
--dns-service-ip 10.0.0.10 \
--docker-bridge-address 172.17.0.1/16 \
--vnet-subnet-id $SUBNET_ID \
--service-principal $SP_ID \
--client-secret $SP_PASSWORD \
--aad-server-app-id $AD_SERVER_APP_ID \
--aad-server-app-secret $AD_SERVER_APP_SECRET \
--aad-client-app-id $AD_CLIENT_APP_ID \
--aad-tenant-id $AD_TENANT_ID
Operation failed with status: 'Bad Request'. Details: Service principal clientID: XXXX not found in Active Directory tenant XXXXX, Please see https://aka.ms/aks-sp-help for more details.
Note the clientID: referenced in the error is the value of argument `--aad-client-app-id`
bash-4.4$ az --version
azure-cli 2.0.61 *
acr 2.2.3 *
acs 2.3.20 *
advisor 2.0.0
ams 0.4.3 *
appservice 0.2.16 *
backup 1.2.2 *
batch 4.0.0 *
batchai 0.4.8 *
billing 0.2.1
botservice 0.1.9 *
cdn 0.2.1 *
cloud 2.1.1
cognitiveservices 0.2.5
command-modules-nspkg 2.0.2
configure 2.0.20 *
consumption 0.4.2 *
container 0.3.15 *
core 2.0.61 *
cosmosdb 0.2.9 *
dla 0.2.5
dls 0.1.8 *
dms 0.1.3
eventgrid 0.2.2 *
eventhubs 0.3.4 *
extension 0.2.4 *
feedback 2.1.4 *
find 0.3.1 *
hdinsight 0.3.2 *
interactive 0.4.2 *
iot 0.3.7 *
iotcentral 0.1.6
keyvault 2.2.13 *
kusto 0.2.1 *
lab 0.1.6 *
maps 0.3.4
monitor 0.2.11 *
network 2.3.5 *
nspkg 3.0.3
policyinsights 0.1.2 *
profile 2.1.4 *
rdbms 0.3.9 *
redis 0.4.2 *
relay 0.1.4
reservations 0.4.2
resource 2.1.12 *
role 2.4.3 *
search 0.1.1
security 0.1.1
servicebus 0.3.4 *
servicefabric 0.1.15 *
signalr 1.0.0
sql 2.2.0 *
sqlvm 0.1.1
storage 2.3.2 *
telemetry 1.0.2
vm 2.2.17 *
Python location '/usr/local/Cellar/azure-cli/2.0.61/libexec/bin/python'
Extensions directory '/Users/xxxx/.azure/cliextensions'
Python (Darwin) 3.7.3 (default, Apr 8 2019, 14:57:53)
[Clang 10.0.1 (clang-1001.0.46.3)]
Legal docs and information: aka.ms/AzureCliLegal
```
⚠Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
Thanks for the feedback! We are currently investigating and will update you shortly.
Possibly related to #32873 and https://github.com/Azure/azure-cli/issues/9585
@bitsofinfo please following the above issues for updates.
@MicahMcKittrick-MSFT The issue this points to is not the same issue as is described by @bitsofinfo. This issue is about the Azure AAD integration with AKS. This did work in the past, but it doesn't anymore.
I got past the error by deleting the cached sp secrets file located here C:\Users\username.azure\aksServicePrincipal.json. I hope this helps someone.
Still encountering the exact same issue!
Not sure why this kind of thread is being closed with no valid solution, just redirecting to other issue doesn't solve it.
-> https://github.com/Azure/azure-cli/issues/9585
-> https://github.com/MicrosoftDocs/azure-docs/issues/32873
"Thanks for that. I am following that issue as well so we can see what the CLI team can do :)"
WTH!?
Most helpful comment
I got past the error by deleting the cached sp secrets file located here C:\Users\username.azure\aksServicePrincipal.json. I hope this helps someone.