Although the virtual directories for the various Exchange web services can be recreated via the "Exchange Admin Center", there are cases where this function reaches its limits.
I simulated such an error for this article. Even after resetting the directory for OWA with the Exchange Admin Center, OWA does not work:
Not everything can be done with the GUI.
Introduction
Exchange 2016 has two websites in the IIS. The "Default Web Site" website contains the Client Access service, which no longer exists as a separate Exchange role, but is still present. Exchange clients, such as Outlook and smartphones, connect to the virtual directories within the "Default Web Site". The virtual directories within the "Default Web Site" therefore form the front end for the clients/protocols.
The front end serves the clients as a proxy for the "Exchange back end", which has its own website within the IIS. The back end contains the actual logic, the front end only serves as a stateless proxy. The following screenshot shows the two websites:
The virtual directories can also be displayed in the Exchange Management Shell, for example the following command shows the virtual directory for OWA:
Get-OwaVirtualDirectory -Server TEX1
However, the command only displays the front end, which can be recognized by the "Name" parameter: Default Web Site. The following command can be used so that the corresponding counterpart is also displayed in the back end:
Get-OwaVirtualDirectory -Server TEX1 -ShowMailboxVirtualDirectories
The following command can be used to obtain a list of all corresponding commands for listing the virtual directories:
get-command get-*VirtualDirectory
So much for the theory for now. Various problems may make it necessary to recreate one or more of the virtual directories.
Create new virtual directories
This small example shows the creation of a new virtual directory for Outlook Web Access (Outlook on the Web, OWA). To simulate an error, I have simply deleted the virtual directory for OWA in the "Default Web Site" and in the "Exchange Back End" web page for this article:
Deleting the two directories then leads to an HTTP 404 error:
In my case, I now have to create new front-end and back-end directories for OWA. However, I have only deleted the directories in IIS. Exchange still assumes that the front-end and back-end exist. This can be checked with the following command:
Get-OwaVirtualDirectory -Server TEX1 -ShowMailboxVirtualDirectories
In this screenshot you can see that the OWA directory is missing in the IIS, but is still displayed in the Exchange Shell:
Exchange saves its part of the configuration in the Active Directory, as can be seen here:
So that the OWA front-end and back-end can be recreated, the directories must first be deleted from the Exchange configuration. The following command can be used for this:
Get-OwaVirtualDirectory -Server TEX1 -ShowMailboxVirtualDirectories | Remove-OwaVirtualDirectory
In principle, you could now recreate the directory for OWA if it were not for the IIS metabase. There are also entries here that prevent the virtual directory from being recreated. As a rule, the following error occurs if an attempt is made to recreate the OWA directory and there are remnants in the IIS metabase:
Error creating the virtual IIS directory 'IIS://TEX1.frankysweb.local/W3SVC/1/ROOT/owa' on 'TEX1'.
+ CategoryInfo : InvalidOperation: (TEX1\owa (Default Web Site):ADObjectId) [New-OwaVirtualDirectory], In
validOperationException
+ FullyQualifiedErrorId : [Server=TEX1,RequestId=a96fe949-f9e2-48b1-977d-e7a5f8cbc600,TimeStamp=18.10.2017 18:43:5
1] [FailureCategory=Cmdlet-InvalidOperationException] 5812692E,Microsoft.Exchange.Management.SystemConfigurationTa
sks.NewOwaVirtualDirectory
+ PSComputerName : tex1.frankysweb.local
To clean up the corpses in the IIS Metabase, the rather old tool "IIS Metabase Explorer" can be used. The tool can be downloaded here:
The "IIS Metabase Explorer" requires .NET Framework 3.5 functions, which may have to be installed later:
In the IIS Metabase Explorer, the "OWA" entries must be deleted under "LM -> W3SVC -> 1 -> ROOT" and "LM -> W3SVC -> 2 -> ROOT":
Note: The entry under "LM -> W3SVC -> 1 -> ROOT" stands for the front end, "LM -> W3SVC -> 2 -> ROOT" is the OWA back end.
Both entries for OWA can be deleted in the IIS Metabase:
Now the OWA directory can be recreated with the Exchange Management Shell:
New-OWAVirtualDirectory -WebSiteName 'Default Web Site' -Server TEX1
And the back end can now also be created again:
New-OWAVirtualDirectory -WebSiteName 'Exchange Back End' -Server TEX1 -Role "Mailbox"
The OWA website is already loading again:
However, the URLs must be entered again:
In my case, this is "https://outlook.frankysweb.com/owa"
The remaining settings, for example for authentication, must also be adjusted according to your requirements:
As already mentioned at the beginning, it is also possible to reset the virtual directories via EAC. However, only the front end is ever recreated. If, as described here, errors occur in the back end, the Exchange Administrative Center will not help.
The remaining directories can also be recreated in the way described here (EWS, Active Sync). The procedure is the same and only the corresponding CMDLets need to be used for the other directories. One small exception, however, is the PowerShell directory. This will be dealt with in the next article.
Hallo zusammen, ich habe einen Exchange 2019 aufgesetzt. Leider habe ich OWA zwar in Betrieb gehabt, allerdings durchgängig mit der Meldung, das keine Verschlüsselung aktiviert ist. ActicSync ging somit auch nicht. Bei meinen Bemühungen dies zu Realisieren habe ich im IIS so viele Anpassungen vorgenommen, das nun gar nichts mehr geht. Somit würde ich den IIS gerne wieder auf „Default“ zurücksetzen. Kann ich auf die obern genannte weise Ab dem Abschnitt in dem die virtuellen Verzeichnisse erstellt werden, diese mit den Standardwerten überschreiben, oder muss ich tatsächlich erst die drei Ordner in allen drei „Ablagen“ entfernen um sie neu zu installieren?
Ich habe nun die Ordner alle immer entfernt und neu erstellt. Das ging bei allen Ordnern gut Problemlos.
ECP, EWS, OAB, Microsoft-Server-ActiveSync. Und zwar im Default, wie auch im Back End
Leider habe ich noch eine Herausforderung. OWA lässt sich im Back End nicht wieder herstellen. Die Seite fehlt in allen drei Ansichten.
Die Fehlermeldung lautet,
„[PS] C:\Windows\system32>New-OwaVirtualDirectory -WebSiteName ‚Exchange Back End‘ -Server meiner.local -Role „Mailbox“
Das Webobjekt ‚Exchange‘ ist bereits vorhanden.
+ CategoryInfo : InvalidArgument: (meiner\owa (Exchange Back End):ADObjectId) [New-OwaVirtualDirectory], WebObjectAlreadyExistsException
+ FullyQualifiedErrorId : [Server=meiner,RequestId=d803c3c0-84f4-477f-86ab-87d66f9bfefe,TimeStamp=09.02.2024 09:43:40] [FailureCategory=Cmdlet-WebObjectAlreadyExis
tsException] 3594AAF0,Microsoft.Exchange.Management.SystemConfigurationTasks.NewOwaVirtualDirectory
+ PSComputerName : meiner.local“
Da ich sonst alle Verzeichnisse sauber weg und hin bekommen habe, kann nicht so viel falsch sein. Server ist ein Exchange 2019 CU13, inkl. aktueller Updates.
Über Hilfe wäre ich sehr dankbar, da ich mit dem Fehler „Das Webobjekt ‚Exchange‘ ist bereits vorhanden.“ nichts anfangen kann. Den Ablauf mit erst im IIS löschen, dann im ADSI-Editor und dann noch im Tool zusammen auf beiden Seiten und dann erst auf der Default Seite und danach auf dem Back End habe ich ebenfalls durchgeführt. Die Default Seite ist auch wieder da. die Back End Seite eben nicht. Dort ist nur der owa Ordner wie auf dem Bild oben.
Hallo!
Ich habe die Anleitung peinlichst genau befolgt um Autodiscover auf Exchange 15.1 2016 neu zu erstellen. Vor dem Neuerstellen habe ich im ADSI Editor und ISS Metabase Editor alles mit Autodiscover entfernt. Leider endet der Befehl zur Neuerstellung wie folgt:
New-AutodiscoverVirtualDirectory -WebSiteName ‚Exchange Back End‘ -Server server -Role „Mailbox
“
Das Active Directory-Objekt für das virtuelle Verzeichnis ‚IIS://Server.WIR.at/W3SVC/2/ROOT/Autodiscover‘
auf ‚SERVER‘ konnte nicht erstellt werden. Möglicherweise ist es bereits in Active Directory vorhanden. Entfernen Sie
das Objekt aus Active Directory, und erstellen Sie es anschließend neu.
+ CategoryInfo : InvalidOperation: (SERVER\Autodiscover (Exchange Back End):ADObjectId) [New-Autodiscover
VirtualDirectory], InvalidOperationException
+ FullyQualifiedErrorId : [Server=SERVER,RequestId=49e3c8b5-fc2d-451c-9366-88c237dc7275,TimeStamp=15.01.2023 08:42
:55] [FailureCategory=Cmdlet-InvalidOperationException] 78C179A1,Microsoft.Exchange.Management.SystemConfiguration
Tasks.NewAutodiscoverVirtualDirectory
+ PSComputerName : server.WIR.at
Ich wäre über jeden Tipp sehr dankbar!
Hallo Daniel, Hattest du das Problem noch beheben können?
Hattest du noch mal im ADIS-Editor geguckt, das der Ordner weg ist?
Bei Autodiscover gibt es wohl noch einen weiteren Wert,
New-AutodiscoverVirtualDirectory -Server „Servername“ -BasicAuthentication $true -WindowsAuthentication $true
Set-ClientAccessServer -Identity „Servername“ -AutodiscoverServiceInternalUrl https://autodiscover.Servername.local/Autodiscover/Autodiscover.xml
Gruß Wolf
Wieder mal großes Lob an Franks Seite – ohne die wären viele Exchange-Admins um einiges schlechter dran auf dieser Welt (und man kann nicht jedem unterstellen, dass er seine Hausaufgaben nicht macht…). Auch mich ereilte der 403 im Browserfenster nach einem Update, und hier erfuhr man doch tatsächlich Hintergründe und eine profunde Lösung.
Was dem Verfasser nicht anzulasten ist, was aber zu stundenlanger Arbeit führt: Stand heute (10/2021) ist bei Microsoft KEIN Resource Toolkit mehr im Download zu bekommen, das sind nur noch DOCs. Da alle Welt nur per Link zu MS verweist, hat man quasi gar keine Chance, das noch herbeizuschaffen. Also zusehen, dass man sich das irgendwie, irgendwo, irgendwann schon mal heruntergeladen und gespeichert hat!
Super ! Herzlichen Dank an dich Alex
Hallo Frank,
tolle Arbeit, die Du hier leistest. Chapeau.
Ich arbeite mich nun schon seit Tagen durch sämtliche Dokus von Dir zur Migration Exchange 2010 zu 2016 und stolpere von einem Problem zum nächsten. Vielleicht kannst du mir helfen ?
Zum Einen fehlt im IIS der komplette „Exchange Backend“ Pfad, bei mir ist nur die Default Web Site vorhanden.
Deshalb bin ich nun auch auf diese Seite Webseite von Dir gestoßen.
Zum Anderen fehlt im DNS der komplette Eintrag: _mcds.server.local, unterhalb der Forward Lookup Zone. Innerhalb der server.local Zone ist _mcds vorhanden.
Im ADSI Editor sind die Einträge auch alle vorhanden. Von extern funktioniert mit autodiscover soweit alles, da hab ich den Test über https://www.testexchangeconnectivity.com/ durchlaufen lassen.
OWA und Active Sync funktinieren ebenfalls produktiv.
Die DNS “ _mcds.server.local“ Eintrag und der IIS „Exchange Backend“ Eintrag sind doch aber für eine erfolgreiche Migration notwendig!
Wie kann ich diese fehlenden Einträge erstellen ?
LG Andi
Hallo Andi,
schreib es doch mal in das neue Forum: https://www.frankysweb.de/community
Gruß,
Frank
Hallo Zusammen,
leider finde ich nirgendwo mehr das „Internet Information Services (IIS) 6.0 Resource Kit Tools“ oder Metabase Explorer !
Hat jemand einen funktionieren Link zum Download oder stell ich mich nur „deppert“ an :-)
Danke !!!!!
Tom aus Augsburg
https://download.cnet.com/Internet-Information-Services-IIS-6-0-Resource-Kit-Tools/3000-2381_4-10735391.html
http://download.microsoft.com/download/7/8/2/782c25d3-0f90-4619-ba36-f0d8f351d398/iis60rkt.exe
aus dem Archive.org gefischt
^^Link Jetzt leider auch down
Nimm diesen Link:
https://web.archive.org/web/20170330222336/http://download.microsoft.com/download/7/8/2/782c25d3-0f90-4619-ba36-f0d8f351d398/iis60rkt.exe
Hallo Frank,
ich schließe mich hier meinem Vorredner ausnahmslos an
Wieder einmal hat mir Deine Seite so ziemlich als Einzige im Web kompetent weitergeholfen!
Es ist einfach sehr traurig, dass Microsoft es anscheinend nicht schafft, ein Exchange CU zu veröffentlichen, ohne dass man sich irgendwas zerschießt… Selbe lässt sich leider auch bei diversen Serverrollen berichten (Stichwort WSUS …).
Von dem her, alle Daumen nach oben für diese Seite hier!
LG, Andy
Vielen lieben Dank!
Musste das ECP Verzeichnis komplett zurücksetzen und dies war die einzigste Anleitung die mir deutlich weiter geholfen hat.
Ich hatte ein paar Tage geschwitzt, und andere Beiträge im Internet haben nicht geholfen, danke, dass du so tief in die Materie gehst!
Großes Lob!!!