Skip to content

Instantly share code, notes, and snippets.

@tostka
Created July 16, 2019 15:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tostka/5e01211039af2fabf1431fc5588a5833 to your computer and use it in GitHub Desktop.
Save tostka/5e01211039af2fabf1431fc5588a5833 to your computer and use it in GitHub Desktop.
# Confirm User has RemoteMailbox in OnPrem mail system
# Note: Preconnect to onprem EX remote ps & EXO
# To differentiate targets, I prefix _EXO_ cmdlets with [verb]-exo[noun])
# on-prem cmdlets are _un-prefixed_
$tAddress = "UserUPN@DOMAIN.com" ;
# pull local recipient type
$rcp = get-recipient $tAddress ;
$rcp | ft -a alias, primar*, recipientt* ;
$rmbx = get-remotemailbox -id $rcp.PrimarySmtpAddress ;
$rmbx | format-table -auto Name, RecipientTypeD*, userprin* ;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment