<

7 Steps to AutoDiscover Heaven

Published on
28,994 Points
17,094 Views
24 Endorsements
Last Modified:
Approved
Community Pick
Since I couldn't find anything on the internet that describes how to do a complete Autodiscover reset, I thought I'd write one...

I have spent quite a bit of time testing this in an Exchange 2007 SP3 lab and have fixed an Autodiscover problem on an Exchange 2010 SP1 production environment with the following steps, so it should also work for you.  Please try and be on the latest Service Packs for Windows and Exchange as this will solve lots of issues for you and is better for supportability.

This is my first article, so bear with me. If you find this article useful then please vote for it.

Autodiscover complete reset:

1

Open EMS and do "Get-AutoDiscoverVirtualDirectory | Remove-AutodiscoverVirtualDirectory"

2

Open windows Explorer and rename the ":\Program Files\Microsoft\Exchange Server\ClientAccess\autodiscover" folder on your CAS server/s

3

Copy 'Autodiscover' folder from <Exchange install or SP source files, whatever version you have installed>\setup\serverroles\clientaccess\autodiscover to the ClientAccess folder mentioned in Step 2

4

Edit the web.config file in the ":\Program Files\Microsoft\Exchange Server\ClientAccess\autodiscover" folder on your CAS servers and replace "%ExchangeInstallDir%" with "<drive>:\Program Files\Microsoft\Exchange Server\" or whereever you have your "Exchange Server" Folder is. If you are running Exchange 2010 then replace it with "<drive>:\Program Files\Microsoft\Exchange Server\V14\". Be sure to replace <drive> with the drive letter where Exchange is installed.

5

On the CAS server/s open Windows Explorer and right-click on the ":\Program Files\Microsoft\Exchange Server\ClientAccess\autodiscover" folder and the go into it's Properties-->Security-->Permissions and Add 'Authenticated Users' to the Autodiscover folder NTFS Permissions with 'Read', 'Read & Execute' and 'List folder contents' permissions. Press OK.

6

Open EMS and do "New-AutoDiscoverVirtualDirectory" (you shouldn't have to specify any additional parameters to create it on a single CAS)

7

Open and Command Prompt and do "IISReset" (I am not sure you have to do this, but I always like to after so many changes)
Now going to your server on https://<Internal_CAS_Name_on_Certificate>/autodiscover/autodiscover.xml should result in a credentials prompt, after typing in valid credentials you should get a "ErrorCode=600 Invalid Request page". Which is what you want and means things are working as they should do. "Test-OutlookWebServices |fl" in EMS should now work too.

Other Useful info:
If "get-ClientAccessServer |fl" show the AutoDiscoverServiceInternalUri is blank(Null) then Test-OutlookWebServices will give you a "Index was out of range" error. So basically this means your SCP (Service Connection Point) is blank and doesn't know where to forward your Autodiscover Service request to. So be sure to set a valid internal URL with "get-ClientAccessServer | Set-ClientAccessServer -AutoDiscoverServiceInternalUri "https://<Internal_CAS_Name_on_Certificate>/autodiscover/autodiscover.xml"
If the AutoDiscoverSiteScope value is empty(Null) or assigned to an invalid site then this appears not to cause any issues (in a test environment).
If you are really struggling with your SCP you can delete it and the setting the value of AutoDiscoverServiceInternalUri like in the above bullet point will recreate it for you OR use Split DNS and an internal SRV record
HTTP logs are under C:\Inetpub\logs\logfiles\w3svc1 on Windows 2008, but you shouldn't need them after the reset
If you want detailed Error display in IE when testing from the CAS server = add reg key HKLM\SOFTWARE\Microsoft\Fusion\EnableLog (DWORD) =1 to the registry on the CAS server

By now you should be rid of your Error 500, Error 404 etc. If not, drop a post on this article and I will try and help you.

If you have any questions or queries or additional info then feel free to post it below.

Cheers

MegaNuk3
24
Comment
Author:MegaNuk3
14 Comments
LVL 76

Expert Comment

by:Alan Hardisty
Good article - I can see this being very helpful to the EE Community at large.  Nice work.

Yes vote from me.

Alan : )
0
LVL 23

Expert Comment

by:Suliman Abu Kharroub
Nice article ...  vote yes.
0
LVL 10

Expert Comment

by:Muzafar Momin
good article : vote from me too
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

LVL 17

Expert Comment

by:Viral Rathod
Really Good Article ,you are a Autodiscover Champ.

Keep it up..vote from me too :)
0
LVL 31

Author Comment

by:MegaNuk3
@viralrathod - thanks
0
LVL 1

Expert Comment

by:ralfalpert
Thanks for the article, Great Help
0
LVL 31

Author Comment

by:MegaNuk3
@ralfalpert - thanks
0

Expert Comment

by:centerized
This looks like a great solution.  Can anyone tell me what effects this will have on a live Exchange 2010 system with Outlook 2007 & 2003 clients?  Will users get errors or need to have their Outlook profiles reconfigured?  Thank you!
0
LVL 31

Author Comment

by:MegaNuk3
It won't have any effect on Outlook 2003 clients as they don't use autodiscover.

As for Outlook 2007 clients, you wouldn't be doing the above procedure unless you were having autodiscover issues, so after performing the above the Outlook 2007 clients will be able to contact autodiscover and retrieve settings(this normally happens after outlook is started)
0
LVL 23

Expert Comment

by:Stelian Stan
Very helpful. Thanks.
0

Expert Comment

by:harbz96
Hello,
Have done all these steps - worked fine.
But still get IIS 8.0 Error

HTTP Error 500.0 - Internal Server Error

Page appear when i try to access  https://exchangeasever.purtills.local/autodiscover/autodiscover.xml

get-ClientAccessServer |fl

shows uri to be https://exchangeasever.purtills.local/autodiscover/autodiscover.xml 

Help is needed thanks. :)
0

Expert Comment

by:masheo
Thank you for this, I found it very useful.
0
LVL 1

Expert Comment

by:ghost123
Hi,

Looks to be a great article but after following the steps, we are still getting

HTTP Error 404.0 - Not Found

The resource you are looking for has been removed, had its name changed, or is temporarily unavailable.

Physical Path points to - C:\inetpub\wwwroot\autodiscover\autodiscover.xml

Ideas?

Thanks
0

Expert Comment

by:Jesper Rex
I only needed to to follow Step 4 and change the Web.Config to use the actual path, instead of %ExchangeInstallDir%

This saved my day ;)
0

Featured Post

Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

Join & Write a Comment

This video tutorial shows you the steps to go through to set up what I believe to be the best email app on the android platform to read Exchange mail.  Get the app on your phone: The first step is to make sure you have the Samsung Email app on your …
Check How effective MS Exchange Expert thinks Exchange Mailbox Recovery by SysTools IS. Visit the Official site to get detailed information:- https://www.systoolsgroup.com/exchange-recovery.html (https://www.systoolsgroup.com/exchange-recovery.h…
Other articles by this author

Keep in touch with Experts Exchange

Tech news and trends delivered to your inbox every month