Get UPN and ImmutableID of All Office 365 Users

During troublesome Office 365 migrations you may want to get the ImmtableIDs and UPNs of all the users using 365 to troubleshoot single sign on issues. The Azure powershell below exports both pieces of information to a CSV.

Connect-MsolService

$onlineusers = Get-MsolUser -All | Select-Object UserprincipalName,ImmutableID,WhenCreated,LastDirSyncTime

$onlienusers | Export-Csv c:\temp\OnlineUser.csv -NoTypeInformation 

I used this powershell recently when a client had issues soft linking 365 with ADFS.

Allen White

Allen is a Consultant for ITPS in the North East of England and holds the following accreditations. MCSA, MCSE, MCTS, MCITP, CCA, CCSP, VCP 4,5 and HP ASE, AIS - Network Infrastructure.

Leave a comment

Categories

Vote!

What Web Browser Do You Use?

View Results

Loading ... Loading ...

Vote!

What do you prefer..VMware or Hyper-V?

View Results

Loading ... Loading ...