AD Contacts are not sync with MSX 2016

Olivier Travelletti
Olivier Travelletti used Ask the Experts™
on
Dear Experts, I have a synchronisation problem between our "one and only" DC (WS 2016 Std.) and also "one and only" Exchange 2016. We are opening and editing contacts in AD but they are not automatically synchronized with our exchange. Both are new installation and maybe I've made something wrong or didn't understand the way they are communicating. Please be indulgent, I'm not the best SYS Admin ;-)

Have a great stressfree day and thank you for reading my problem

Best Regards Olivier
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
AlexA lack of information provides a lack of a decent solution.

Commented:
Olivier,

Firstly, and I'm sure/hope you understand the rather precarious position you're in with a single domain controller. That goes, you're screwed, simple as.


https://docs.microsoft.com/en-us/previous-versions/office/exchange-server-2010/bb124237(v=exchg.141)?redirectedfrom=MSDN

You need to sync it yourself and mail enable the contact. It's all in the above link.
Alan CoxSr. Architect | Consulting

Commented:
are they mail enabled? https://docs.microsoft.com/en-us/powershell/module/exchange/users-and-groups/enable-mailcontact?view=exchange-ps
I generally create and edit contacts in Exchange EAC not Active directory.
AlexA lack of information provides a lack of a decent solution.
Commented:
If you have a list of contacts, I can script how you can enable them all at hte same time.

$Contacts = Get-content c:\temp\listofcontacts.txt

Foreach ($contact in $contacts){
Enable-MailContact -Identity $Contact -ExternalEmailAddress EllenAdams@Contoso.com}

Open in new window


that should do it, you just need the names of your contacts, if you don't know how to get them let me know.

Actually

ADObject -Filter 'objectClass -eq "contact"'

Open in new window

OWASP: Forgery and Phishing

Learn the techniques to avoid forgery and phishing attacks and the types of attacks an application or network may face.

Sr. Architect | Consulting
Commented:
Import-CSV c:\contacts.csv | ForEach-Object {New-MailContact -Name $_.Name -ExternalEmailAddress $_.ExternalEmailAddress -OrganizationalUnit $_.OrganizationalUnit}

 CSV headers name, ExternalEmailAddress, organizationalUnit
Olivier TravellettiSystem Administrator

Author

Commented:
Hi Alex / Hi Alan

Thank you very much for the quick answers. Yes, Alan, I know how dangerous the fact that we have now just one DC. This is on my radar. I will try to run the export all the contacts and run the script. The editing from contacts are made from an employee without knowledge of Exchange. That's why I've created a snapin with delegate control on the OU.

I wish you a merry christmas and a happy new year :-)

Greetings from Switzerland

Olivier
Alan CoxSr. Architect | Consulting

Commented:
you as well. keep us posted.
Olivier TravellettiSystem Administrator

Author

Commented:
Olivier TravellettiSystem Administrator

Author

Commented:
@Alan, could you please make a script with that file? Do you need more Infos?
Alan CoxSr. Architect | Consulting

Commented:
I'll need name (display name), External Email address and Organizational unit path in CSV headers
Alan CoxSr. Architect | Consulting

Commented:
These are just raw contacts with no External email address so exchange won't see them (no mail attributes). So I would need a csv with at least an externalemailaddress column and OU (where you want contacts to be in Active Directory, Finally a Name Column so the 'display name' will appear correctly in GAL.
Olivier TravellettiSystem Administrator

Author

Commented:
Dear Alan

I'm really sorry for that. I didn't proof the file. It was a long day yesterday. I will do it tomorrow morning.

Kindly Olivier
Olivier TravellettiSystem Administrator

Author

Commented:
Dear Alan/Alex

I've found what I exactly need. This Powershell script has done it for all the objects contatcs:

get-contact -organizationalunit testou -RecipientTypeDetails Contact -Filter 'WindowsEmailAddress -ne $null' |
 foreach { enable-mailcontact -Identity $_ -ExternalEmailAddress $_.WindowsEmailAddress.toString() }

Please feel free to share it if you want

Best Regards Olivier Travelletti

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial