skip to Main Content

Recreate virtual directories in Exchange Server

Today’s article will show how to recreate virtual directories in Exchange Server. After installing Exchange Server 2016 and looking in IIS Manager, we can see two sites configured. That’s the Default Web Site and the Exchange Back End. If there are issues and you like to reset virtual directories in Exchange Server, you’re at the right place. Read more on how to recreate virtual directories in Exchange Server.

Find and manage virtual directories in Exchange Server

To find and manage virtual directories, you can use:

  • IIS Manager
  • Exchange Management Shell (EMS)
  • Exchange Admin Center (EAC)

Why you want to recreate Exchange virtual directories

Sometimes you have to start from a clean slate, as it will fix most of the problems. Such as:

  • Permission problems
  • Blank screen
  • Missing files
  • Connectivity issues
  • Page errors

Recreate Exchange virtual directories Default Web Site

Start Internet Information Services (IIS) 6.0 Manager. Exchange Server installation creates two websites:

  • Default Web Site
  • Exchange Back End

Recreate virtual directories in Exchange Server IIS default

To recreate virtual directories in IIS, we will use PowerShell. We will get the virtual directory, remove the virtual directory, and create the virtual directory. The list is in alphabetic order:

  1. ActiveSyncVirtualDirectory (Microsoft-Server-ActiveSync)
  2. AutodiscoverVirtualDirectory (Autodiscover)
  3. EcpVirtualDirectory (ecp)
  4. MapiVirtualDirectory (mapi)
  5. OABVirtualDirectory (OAB)
  6. OwaVirtualDirectory (owa)
  7. PowerShellVirtualDirectory (PowerShell)
  8. WebServicesVirtualDirectory (EWS)

In our example, we will reset the virtual directories on Exchange Server EX01-2016. The internal and external URL is https://mail.exoip.com. We recommend changing the internal and external URLs to a generic namespace.

Read more: Exchange 2016 namespace design and planning »

Recreate ActiveSyncVirtualDirectory

Run Exchange Management Shell as administrator. Recreate Microsoft-Server-ActiveSync virtual directory.

Do you get errors when creating the Exchange virtual directory? Read the article An error occurred while creating the IIS virtual directory.

Recreate AutoDiscoverVirtualDirectory

Recreate Autodiscover virtual directory.

Learn more about Autodiscover in Exchange Server:

Recreate EcpVirtualDirectory

Recreate ecp virtual directory.

Recreate MapiVirtualDirectory

Recreate mapi virtual directory.

Recreate OABVirtualDirectory

Recreate OAB virtual directory.

Recreate OwaVirtualDirectory

Recreate owa virtual directory.

Recreate PowerShellVirtualDirectory

Recreate PowerShell virtual directory.

You must open PowerShell or PowerShell ISE and run the following cmdlets. That’s because you can’t recreate a PowerShell virtual directory if you are in a session (Exchange Management Shell). The first cmdlet will load the Microsoft Exchange Management Powershell Snapin.

Recreate WebServicesVirtualDirectory

Recreate EWS virtual directory.

Restart IIS or reboot the Exchange Server.

Verify virtual directories in Exchange Admin Center

Open your favorite browser and log in to Exchange Server Admin Center (EAC). The localhost link is https://localhost/ecp. In the feature pane, click servers and click in the tabs on virtual directories. Select the server that you recreated the virtual directories on.

Recreate virtual directories in Exchange Server EAC

The Exchange virtual directories are recreated and showing successfully. Did it work for you?

Keep reading: Recreate arbitration mailboxes in Exchange Server »

Conclusion

In this article, you learned how to recreate virtual directories in Exchange Server. We did reset Exchange virtual directories with PowerShell. The cmdlets did get the virtual directory, remove the virtual directory and, as of last, create the virtual directory. It’s always good to check the virtual directories in Exchange Admin Center to verify if they are created.

Did you enjoy this article? You may also like Recreate audit log mailbox in Exchange Server. Don’t forget to follow us and share this article.

ALI TAJRAN

ALI TAJRAN

ALI TAJRAN is a passionate IT Architect, IT Consultant, and Microsoft Certified Trainer. He started Information Technology at a very young age, and his goal is to teach and inspire others. Connect with ALI TAJRAN on social media. Read more »

This Post Has 0 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

Back To Top