Introduction

Let’s understand about mailbox plans today, these can be helpful in modifying mailbox and casmailbox settings of new accounts in Exchange Online. These were introduced in Exchange Online 2 years back and There are 2 cmdlets related to mailbox plans :

  • Set-CASMailboxPlan is used to modify properties of Set-CASMailbox
  • Set-MailboxPlan is used to modify properties of for Set-Mailbox cmdlet
Get-MailboxPlan |select name
Get-CASMailboxPlan |select name

You can see similarity that Name is identical for MailboxPlan and CASMailboxPlan. It is said that MailboxPlan is interlinked with corresponding CASMailboxPlan and it’s connection is unbreakable. Below table will tell you which plan should be modified to modify setting of mailboxes:

Subscription or licenseMailbox plan display name
Exchange Online KioskExchangeOnlineDeskless
Office 365 Enterprise E1
Exchange Online Plan 1
ExchangeOnline
Office 365 Enterprise E3
Office 365 Enterprise E5
Exchange Online Plan 2
ExchangeOnlineEnterprise
Office 365 Business EssentialsExchangeOnlineEssentials

Also, what would happen if mailbox is created without licenses, at that point default mailbox plan is used. Hence make one mailbox plan as default using below command :

Set-MailboxPlan -Identity ExchangeOnlineEnterprise-7392534d-e1f4-4592-bf2d-540eb657b35d -IsDefault

Now, you know the basic of Mailbox Plan, Let’s go ahead with disabling imap4 and pop3, please check this article.

How to modify parameters of a Mailbox Plan ?

I have Office Enterprise E3 plan hence mailbox plan name starting with ExchangeOnlineEnterprise* need to be modified (refer table).

FYI, Mailbox plan doesn’t modify setting of an existing mailbox, hence we don’t need to worry that it will affect existing mailbox.

PS C:\WINDOWS\system32> Get-CASMailboxPlan ExchangeOnlineEnterprise-7392534d-e1f4-4592-bf2d-540eb657b35d |fl imapenabled, popenabled
PS C:\WINDOWS\system32> Get-CASMailbox |select displayname, primarysmtpaddress, popenabled, imapenabled    
PS C:\WINDOWS\system32> Set-CASMailboxPlan ExchangeOnlineEnterprise-7392534d-e1f4-4592-bf2d-540eb657b35d -ImapEnabled $false -PopEnabled $false      

PS C:\WINDOWS\system32> Get-CASMailboxPlan ExchangeOnlineEnterprise-7392534d-e1f4-4592-bf2d-540eb657b35d |fl imapenabled, popenabled

Now, create a new mailbox for verification :

Create a test user account

$PasswordProfile = New-Object -TypeName Microsoft.Open.AzureAD.Model.PasswordProfile

$PasswordProfile.Password = "Type Password Here"                                                                         

New-AzureADUser -DisplayName VerifySetting -UserPrincipalName VerifySetting@learnsj.onmicrosoft.com -UsageLocation India -PasswordProfile $PasswordProfile -AccountEnabled $true                                                                      

Assign License

$license = New-Object -TypeName Microsoft.Open.AzureAD.Model.AssignedLicense

$license.SkuId = (Get-AzureADSubscribedSku | Where-Object -Property SkuPartNumber -Value "SPE_E3" -EQ).SkuID

$licenses.AddLicenses = $license                                                                

Set-AzureADUserLicense -ObjectId "VerifySetting@learnsj.onmicrosoft.com" -AssignedLicenses $licenses

Verification

You can see now, that user VerifySetting@learnsj.onmicrosoft.com has imap4 and pop3 disabled and setting of other mailboxes didn’t change.

Get-CASMailbox |select displayname, primarysmtpaddress, popenabled, imapenabled  

Thank you for reading, I hope you liked it.