Manage AzureAD with Windows PowerShell # Manage User, Group

Manage Azure AD through Window PowerShell.

To manage AzureAD with PowerShell first you need to install Azure module in PowerShell.
Before installing Azure module you need to install later PowerShell, you can refer below link to download and install later PS.

Latest PowerShell

To install Azure module PowerShell Run below command.

Install-Module -name Azure



Now Install AzureAD module using below command

install-module -name AzureAD


 



Once installation done.

Run below command to check installed module details

Get-module AzureAD


Run below command to connect with AzureAD

Connect-AzureAD


Enter your Azure account details to connect with Azure portal.


To create manage ADUser, Group or Roles you need to create one Azure ADUser with Global Administrator .


Run below command to connect with AzureAD

 And login with newly created AzureAD User who have Global assignment.

Connect-AzureAD

Use below command to Store your password in incrypted state.

$password = ConvertTo-SecureString -String "P@ssw0rd@123" -AsPlainText -Force


To create UserID in AzureAD use below command.

New-AzADUser -DisplayName "Azure Powershell" -UserPrincipalName "Azurep@kraju947hotmail.onmicrosoft.com" -Passwor $password -MailNickname "Azurep"



To get list out the users created in AzureAD

Run Get-AzureADUser



To filter user starting with selected alphabets

Get-AzureAdUser -Filter "startswith(givenname,'ra')"


1. Cloud Identity -> User ID that we create in cloud Azure AD.
2. Directory Sync identities -> User ID that we create in on-premises and sync with AzureAD cloud.
3. Guest -> Guest account that is not available in On-Premises but we send invite to join like Google,        Hotmail accounts.

Use Cases of Windows PowerShell

Use Case 1: Get Information about Webserver = Get-WebServer
Use Case 2: Get Information about Processes in the computer =Get-processes
Use Case 3: Get list of services in the Computer = Get-service

Verb : Get

Noune:  WebServer, Processes and Service

PowerShell Command work on Verb+Noune

Out: data export

Format: Formatting

Set: Mofifications

Get: retrieve

4 comments:

  1. This comment has been removed by the author.

    ReplyDelete
  2. Such programming arrangements can follow all records and exchanges performed to guarantee a productive investment for the investor.
    ex-ponent.com

    ReplyDelete
  3. The decision of investment programming program on managing portfolio would rely upon the size and prerequisites of the business as well as the field-tested strategies and goals over the long run.
    ex-ponent

    ReplyDelete

Featured Post

HPE MSA 2040 configuration step by step

HPE MSA 2040 configuration Default IP range for HP SAN storage MSA 2040 is 10.0.0.1/2 You need to connect your laptop and storage with...