Address policy using -recipientfilter useless?
I've created an address policy which gives a new user an SMTP address other than the default if the word Consultant or Temp appears in his or her title:new-emailaddresspolicy -name 'Temps and Consultants' -recipientfilter {(title -like '*temp*') -or (title -like '*consultant*')} -enabledprimarysmtpaddresstemplate "%g.%s@mydomain.com"Trouble is, if you make a new user using the console OR using create-mailbox, you can't give the user a title until it has already created the mailbox, and since the new user doesn't have a title yet this Priority 1 address policy never gets applied. Am I doing this wrong or are policies based on attributes you can only set AFTER the mailbox is created useless?
November 25th, 2008 3:30am

Although I am not too sure about your recipient filter, mainly whether the Wildcards will be accepted / considered, the policy should work fine. In some cases you may have to manually apply the policy after editing the Title Field in order to update the email address - to test, I would use more explicit (no wildcard) recipient filter. On another note, why not use one of the CustomAttribute fields instead of Title since you are in any case manually updating the field after user creation and you could use a static designatin which would never appear to normal users/ in the GAL?
Free Windows Admin Tool Kit Click here and download it now
November 25th, 2008 9:19am

The filter is fine; I can see all of my existing consultants and temps if I hit "Preview." Manually applying the policy isn't the answer because I don't want to give the user creating the temps that much power. And you can't update any of the CustomAttribute fields when creating a new user any more than you can populate the Title field. I want this process to be completely automated - that doesn't seem possible in 2007.
November 26th, 2008 3:13am

Hi, Please post the detail error which occur during creating the mailbox. I try to reproduce the issue,below is the result: Exchange version: Exchange 2007 sp1 with rollup 5 installed. Accept domain: xzhang.com (default one) acceprtdomain.com Cmdlt to new email address policy: new-emailaddresspolicy -name 'test '-recipientfilter {(title -like '*test1*')} -enabledprimarysmtpaddresstemplate %g.%s@acceptdomain.com Change priority to 1 After that, I run cmdlt below to apply the policy: Update-EmailAddressPolicy -Identity "test" Create new mailbox named test1, sucessfully. If I misunderstand the issue,please feel free to let me know.
Free Windows Admin Tool Kit Click here and download it now
November 26th, 2008 12:36pm

I don't get an error. I appreciate your effort but as I stated above, I don't want to apply the policy manually - I don't want to give the person creating the user that much power. But I guess I have no choice.
November 27th, 2008 5:18am

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

Other recent topics Other recent topics