Have script to change primary smtp address I'd like comments on.
Everyone, I have this script; see below, that will add/change a primary SMTP address. Id like everyones comment on it because it just seems too simple. We are thinking of adding a different primary smtp address such as first initial, last name , other than the standard of 8 char to left of the @ sign. Ive tested it ok on our lab exchange server and it worked.but like I said it just seems to simple. Tiny.. Start-Transcript c:\temp\mailboxcreatelog.txt Import-CSV c:\temp\input.csv | %{ Set-mailbox -Identity $_.DisplayName -EmailAddressPolicyEnabled $false Set-Mailbox -Identity $_.DisplayName -PrimarySmtpAddress $_.primarysmtpaddress }
June 15th, 2012 12:31pm

if you have it working in your lab and production is simliar I don't see any reason for it not to work. script seems clean and I think it shuold do the job. Lasse Pettersson http://anewmessagehasarrived.blogspot.com
Free Windows Admin Tool Kit Click here and download it now
June 15th, 2012 5:59pm

if you have it working in your lab and production is simliar I don't see any reason for it not to work. script seems clean and I think it shuold do the job. Lasse Pettersson http://anewmessagehasarrived.blogspot.com
June 15th, 2012 6:09pm

Lasse, thanks for the encouragement...just seems to simple... tiny..
Free Windows Admin Tool Kit Click here and download it now
June 15th, 2012 6:34pm

Lasse, thanks for the encouragement...just seems to simple... tiny..
June 15th, 2012 6:43pm

I would highly suggesting changing your EAP to use the new format instead of disabling EAP enforcement on the objects. If you only want the new e-mail address to go to certain objects use filters, the Custom Attributes fields are great for this. In general e-mail addresses should be change via EAPs not directly. Without EAPs there is no way to enforce standard formatting of addresses. Admins will need to remember to set the e-mail address as needed when creating new users too if the default\matching EAP isn't configured to have the desired format.If this post helps to resolve your issue, please click the "Propose as Answer" If you find it helpful , mark it as helpful by clicking on "Vote as Helpful" button at the top of this message. By marking a post as Answered, or Helpful you help others find the answer faster. If you need an expert migration consultant to assist your organization feel free to contact me directly. Jason Sherry | Blog | Hire Me | Twitter: @JasonSherry Microsoft Infrastructure Architect, MCSE: M, MCTIP, Microsoft Exchange MVP
Free Windows Admin Tool Kit Click here and download it now
June 16th, 2012 5:56pm

I would highly suggesting changing your EAP to use the new format instead of disabling EAP enforcement on the objects. If you only want the new e-mail address to go to certain objects use filters, the Custom Attributes fields are great for this. In general e-mail addresses should be change via EAPs not directly. Without EAPs there is no way to enforce standard formatting of addresses. Admins will need to remember to set the e-mail address as needed when creating new users too if the default\matching EAP isn't configured to have the desired format.If this post helps to resolve your issue, please click the "Propose as Answer" If you find it helpful , mark it as helpful by clicking on "Vote as Helpful" button at the top of this message. By marking a post as Answered, or Helpful you help others find the answer faster. If you need an expert migration consultant to assist your organization feel free to contact me directly. Jason Sherry | Blog | Hire Me | Twitter: @JasonSherry Microsoft Infrastructure Architect, MCSE: M, MCTIP, Microsoft Exchange MVP
June 16th, 2012 5:58pm

Disable address policy can be a good thing in some cases and can be bad in some cases. One thing I hate is when there is conflict with email addresses, then policy simply add a sequence number afterwards with out telling. Lasse Pettersson http://anewmessagehasarrived.blogspot.com
Free Windows Admin Tool Kit Click here and download it now
June 17th, 2012 4:07am

Disable address policy can be a good thing in some cases and can be bad in some cases. One thing I hate is when there is conflict with email addresses, then policy simply add a sequence number afterwards with out telling. Lasse Pettersson http://anewmessagehasarrived.blogspot.com
June 17th, 2012 4:10am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics