What if managing hundreds of users could be as easy as clicking a button?
Why Azure AD tenants and directories? - Purpose & Use Cases
Imagine you run a company with many teams, each using different apps and services. You try to manage all user accounts and permissions by writing down details on paper or spreadsheets.
Every time someone joins or leaves, you have to update multiple lists manually.
This manual way is slow and confusing. You might forget to remove access for someone who left, or give too many permissions by mistake.
It's hard to keep track of who can do what, and fixing errors takes a lot of time.
Azure AD tenants and directories organize all users and permissions in one secure place.
This lets you easily add or remove users, control access to apps, and keep everything safe and tidy without manual chaos.
UserList = ['Alice', 'Bob'] # Manually update permissions in multiple places
tenant = AzureAD.createTenant('MyCompany') tenant.addUser('Alice') tenant.assignRole('Alice', 'AppUser')
With Azure AD tenants, you can securely manage all users and apps in one place, saving time and avoiding mistakes.
A school uses Azure AD tenants to give students and teachers access to different learning apps, easily adding new users each semester and removing old ones without hassle.
Manual user management is slow and error-prone.
Azure AD tenants centralize user and permission control.
This makes managing access faster, safer, and simpler.
Practice
Solution
Step 1: Understand Azure AD tenant purpose and identify correct use case
An Azure AD tenant is a dedicated space for managing identities and access. It is not for hosting websites, storing VMs, or databases but for user and access management.Final Answer:
To manage users and control access within an organization -> Option BQuick Check:
Azure AD tenant = user and access management [OK]
- Confusing tenant with storage or hosting services
- Thinking tenant is a database service
- Assuming tenant manages virtual machines
Solution
Step 1: Recall Azure CLI commands for tenants and identify correct one
The command to list tenants is under 'az account' namespace, not 'az ad'. 'az account tenant list' lists all tenants you have access to.Final Answer:
az account tenant list -> Option DQuick Check:
List tenants = az account tenant list [OK]
- Using 'az ad tenant list' which is invalid
- Confusing 'az login' with tenant listing
- Using 'az tenant show' which does not exist
az account tenant list:
[{"tenantId": "1111-2222-3333-4444", "isDefault": true}, {"tenantId": "5555-6666-7777-8888", "isDefault": false}]
What does the isDefault field indicate?Solution
Step 1: Understand 'isDefault' meaning and eliminate incorrect options
'isDefault' marks which tenant is currently active in your Azure CLI session. It does not relate to user count, cost, or deletion status.Final Answer:
The tenant currently active for your Azure session -> Option CQuick Check:
isDefault = active tenant [OK]
- Thinking 'isDefault' means largest tenant
- Assuming it means deleted tenant
- Confusing it with billing or cost info
az ad tenant list but get an error saying the command is not found. What is the most likely cause?Solution
Step 1: Check command availability and verify other causes
'az ad tenant list' is not a valid Azure CLI command; tenant listing is under 'az account'. Login issues or no tenants would give different errors; CLI version too new is unlikely to remove commands.Final Answer:
The Azure CLI does not have a direct 'az ad tenant list' command -> Option AQuick Check:
Invalid command = no 'az ad tenant list' [OK]
- Assuming login error causes command not found
- Thinking no tenants causes command error
- Blaming CLI version without checking command docs
Solution
Step 1: Create new Azure AD tenant and add custom domain
Use the Azure portal to create a separate tenant for the subsidiary company. Within the new tenant, add the subsidiary's custom domain and verify ownership.Final Answer:
Create a new tenant in Azure portal, then add and verify the custom domain in that tenant -> Option AQuick Check:
New tenant + verify domain = correct process [OK]
- Adding domain to wrong tenant
- Assuming subscription creation creates tenant with domain
- Trying to rename existing tenant domain
Ready to prove it?
Pass the test and this pattern moves unknown
