Create a distribution group using PowerShell
Create about 20 distribution group scripts in batch.
Add-PSSnapin Microsoft.Exchange.Management.PowerShell.SnapInNew-DistributionGroup-Name XXXX-ManagedBy XXX-Type Distribution-Alias Public-MemberJoinRestriction Closed-MemberDepartRestriction Closed-RequireSenderAuthenticationEnabled $false
Because I am more accustomed to using ISE, so I need to import the management module of Exchange2016 first, the following is 2010.
Add-PSSnapin Microsoft.Exchange.Management.Powershell.E2010
Explain several important parameters by the way
Set up the administrator, you can use Name
ManagedBy
Set alias
Alias
Set that only administrators can add and remove distribution group members
MemberJoinRestriction Closed-MemberDepartRestriction Closed
Set up that everyone can send mail to this group.
RequireSenderAuthenticationEnabled $false
Check after you set it up.
Get-DistributionGroup-Identity XXXX | fl