Monday, February 13, 2017

IPSec Site to Site VPN Debug Command

Trying to identify VPN issues between two sites.

I've got the following enabled:
logging enable
logging buffered informational
logging trap informational
logging asdm informational
logging host switch.link 192.168.x.x
logging host switch.link 192.168.x.x
logging rate-limit 50 1 level 6


Normally you only run the debug commands when you are actually troubleshooting something. What I will do if I don't have a loging server available is to change the logging buffered to debugging and in SecureCRT (which is the terminal emulator I'm using) save the output on the screen to a text file and then search through that text file for the peer IP of the VPN etc.

If you run debugging level on buffered, trap and host at the same time it will burden the ASA quite significantly if there is a lot of output.
The best thing would be to have a linux based log server where you can use tools like grep to search through the output.

Thursday, January 19, 2017

Exchange 2010 SP3 mailbox role installation with error exit code 87. Default mailbox database cannot mounted and copy status shown as "Service Down"



  • I am in the process of installing Exchange Server 2010 SP3 on a Windows Server 2012 server in order to rehome Exchange 2010 Public folder servers to new hardware. Everything went well with the installation process until I went to add the Mailbox server role, which is giving me the following error (from the log file):
    [01/04/2017 21:58:09.0090] [1] Executing: 
              $wevtutil= join-path (join-path $env:SystemRoot system32) wevtutil.exe;
              $manifestPath = [System.IO.Path]::Combine($RoleInstallPath, "Scripts\TSCrimsonManifest.man");
              Start-SetupProcess -Name:"$wevtutil" -Args:"im `"$manifestPath`" "
            
    [01/04/2017 21:58:09.0105] [2] Active Directory session settings for 'Start-SetupProcess' are: View Entire Forest: 'True', Configuration Domain Controller: 'TAM-FS2.tacomaartmuseum.org', Preferred Global Catalog: 'TAM-FS2.tacomaartmuseum.org', Preferred Domain Controllers: '{ TAM-FS2.tacomaartmuseum.org }'
    [01/04/2017 21:58:09.0105] [2] Beginning processing Start-SetupProcess -Name:'C:\Windows\system32\wevtutil.exe' -Args:'im "C:\Program Files\Microsoft\Exchange Server\V14\Scripts\TSCrimsonManifest.man" '
    [01/04/2017 21:58:09.0276] [2] Starting: C:\Windows\system32\wevtutil.exe with arguments: im "C:\Program Files\Microsoft\Exchange Server\V14\Scripts\TSCrimsonManifest.man" 
    [01/04/2017 21:58:09.0344] [2] Process standard output: 
    [01/04/2017 21:58:09.0344] [2] Process standard error: The value for channel property Type contains an invalid value. The parameter is incorrect.

    [01/04/2017 21:58:09.0347] [2] [ERROR] Unexpected Error
    [01/04/2017 21:58:09.0347] [2] [ERROR] Process execution failed with exit code 87.
    [01/04/2017 21:58:09.0350] [2] Ending processing Start-SetupProcess
    [01/04/2017 21:58:09.0350] [1] The following 1 error(s) occurred during task execution:
    [01/04/2017 21:58:09.0350] [1] 0.  ErrorRecord: Process execution failed with exit code 87.
    [01/04/2017 21:58:09.0350] [1] 0.  ErrorRecord: Microsoft.Exchange.Configuration.Tasks.TaskException: Process execution failed with exit code 87.
    [01/04/2017 21:58:09.0351] [1] [ERROR] The following error was generated when "$error.Clear(); 
              $wevtutil= join-path (join-path $env:SystemRoot system32) wevtutil.exe;
              $manifestPath = [System.IO.Path]::Combine($RoleInstallPath, "Scripts\TSCrimsonManifest.man");
              Start-SetupProcess -Name:"$wevtutil" -Args:"im `"$manifestPath`" "
            " was run: "Process execution failed with exit code 87.".
    [01/04/2017 21:58:09.0351] [1] [ERROR] Process execution failed with exit code 87.
    [01/04/2017 21:58:09.0351] [1] [ERROR-REFERENCE] Id=MailboxComponent___13A8A6B7DE0A4fe3BEB5CB1D86105DA3 Component=EXCHANGE14:\Current\Release\PIM Storage\Content Indexing
    [01/04/2017 21:58:09.0351] [1] Setup is stopping now because of one or more critical errors.
    [01/04/2017 21:58:09.0351] [1] Finished executing component tasks.
    [01/04/2017 21:58:09.0393] [1] Ending processing Install-MailboxRole

Although the installation ended with error exit code 87, the mailbox role seems installed already since all mailbox role's services are up and running... information store, mailbox replication services, etc. are installed and can be started with no issue. However, the default mailbox database cannot be mounted, copy status shows services down. We will have to fix it.

And the solution was:

  • Fix this by removing the registry key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\eventlog\Microsoft-Exchange-Troubleshooters/Operational and sub keys, then reinstall the mailbox rule once more time.  

That's nice, Microsoft, there is no KB about this.

Outlook 2016 - cannot view contents in shared mailbox inbox folders, but visible from OWA

There is a shared mailbox. users connect to the mailbox by adding it as an additional mailbox. It works fine. All suddenly, users reported they are no longer able to view contents of Inbox folders. " we don;t have any thing to display"

Here is the fix:

The way to change this option is the following:
 - menu "File"
 - "Account settings" -> "account settings..."
 - in the "E-mail" tab, select your account and then push the Change... button
 - push the "More settings..." button
 - go to the "Advanced" tab
 - in the "Cached Exchange Mode Settings" section, untick "Download shared folders"

If this options are already check, you need to do the opposite way to enabled both "Cached Exchange Mode Settings  and Download shared folders" options.

Thursday, October 6, 2016

Meetings appear in the calendar as Tentative but the user didn't receive the requests in the inbox or meeting responses from others don't appear in the inbox

We have had several calls recently. Majority of them are Mac Outlook 2016 users (we are running Exchange 2016). We found out solution 1 of the MS KB https://support.microsoft.com/en-us/kb/2966790 fixed the issues

 Users experience one or both the following symptoms in Outlook:
  • The user doesn't receive meeting requests in their inbox. However, the meetings appear in the user's calendar as Tentative.
  • When the user creates a meeting request, the user doesn't see meeting responses from attendees. However, tracking information for the meeting is updated in the user's calendar.
In this scenario, the user does not have a delegate set up.
CAUSE
This issue occurs if the meeting requests were processed incorrectly in the user's mailbox and they get delivered to the user's Deleted Items folder instead of the Inbox folder or the meeting requests were processed incorrectly as if a delegate was set up. 

This can occur if the Receive folder for the IPM.SCHEDULE.MEETING message class was changed to the /Schedule folder or if the PR_RULE_MSG_PROVIDER property of messages that have as message class of IPM.Rule.Version2.Message is set to Schedule+ EMS Interface.
SOLUTION
To resolve this issue, start by following the steps in Solution 1. Depending on the scenario, you may have to use the steps in Solution 2. You will not know which solution applies to the user until you start troubleshooting by using the steps in Solution 1. 

Note The exact steps will vary based on the version of the MFCMAPI tool that you're using. Use caution when you modify mailboxes by using MFCMAPI. Using this tool incorrectly can cause permanent damage to a mailbox.

Solution 1

  1. Download MFCMAPI from http://mfcmapi.codeplex.com/.
  2. Start MFCMAPI.
  3. On the Session menu, click Logon.
  4. Select the user's online mode Outlook profile, and then click OK.

    Note If the user doesn't have an online mode profile, create a profile. Or, on the Tools menu, click Options, and then make sure that both the Use the MBD_ONLINE flag when calling OpenMsgStore check box and the Use the MAPI_NO_CACHE flag when calling OpenEntry check box are selected.
  5. In the list, double-click the user's primary mailbox.
  6. In the new window that appears, on the MDB menu, point to Display, and then click Receive folder table.
  7. In the window, look for IPM.SCHEDULE.MEETING. Then, do one of the following:
    • If IPM.SCHEDULE.MEETING is not present, go to Solution 2. 
    • If IPM.SCHEDULE.MEETING is present, go to step 8 of this procedure.
  8. Expand the Root container.
  9. Right-click Schedule, click Advanced, and then click Set Receive Folder.
  10. Enter IPM.SCHEDULE.MEETING in the box.
  11. Click Delete Association, and then click OK.
  12. Repeat step 6 and 7 to make sure that the IPM.SCHEDULE.MEETING association is removed from the list.
  13. Test to see whether the user can receive meeting responses and meeting requests in their inbox.

Solution 2

  1. Download MFCMAPI from http://mfcmapi.codeplex.com/.
  2. Start MFCMAPI.
  3. On the Session menu, click Logon.
  4. Select the user's online mode Outlook profile, and then click OK.

    Note If the user doesn't have an online mode profile, create a profile. Or, on the Tools menu, click Options, and then make sure that both the Use the MBD_ONLINE flag when calling OpenMsgStore check box and the Use the MAPI_NO_CACHE flag when calling OpenEntry check box are selected.
  5. In the list, double-click the user's primary mailbox.
  6. Expand the Root container, and then expand Top of Information Store.
  7. Right-click Inbox, and then click Open Associated Contents Table.
  8. In the upper part of the window, scroll to locate the Message Class column.
  9. Click Message Class to sort the Message Class column.
  10. Look for all messages that have a message class of IPM.Rule.Version2.Message.
  11. Click each message that has a message class of IPM.Rule.Version2.Message, and then in the lower part of the window, look for a property that's called PR_RULE_MSG_PROVIDER.
  12. Check whether the PR_RULE_MSG_PROVIDER property has a value of Schedule+ EMS Interface.
  13. In the upper part of the window, delete messages whose PR_RULE_MSG_PROVIDER property have a value of Schedule+ EMS Interface.
  14. Test to see whether the user can receive meeting responses and meeting requests in their inbox.

Thursday, May 5, 2016


Create a DAG with Exchange 2013/2016 – Troubleshooting

Once you tried to create a DAG (database Availability Group) with Microsoft Exchange Server 2013 or Exchange 2016, you may get many errors when you tried to add DAG member. It happens to me since I tried to use no Exchange server as witness server and forgot to add Exchange Trusted system group to local Administrators group once I tried to create an Exchange 2016 DAG in the LAB

So you’ve installed two or more Exchange 2016 servers with the Mailbox role and you decide to create the DAG with those two servers. So you create a DAG with a name of LABDAG-16…so good so far, no errors

Now you decide to add the first member to your DAG. Here are the errors you may encounter:



First Issue:  ACCESS DENIED

A server-side database availability group administrative operation failed. Error The operation failed. CreateCluster errors may result from incorrectly configured static addresses. Error: An error occurred while attempting a cluster operation. Error: Cluster API ‘”CreateCluster() failed with 0×5. Error: Access is denied”‘ failed.. [Server: MBX1.domain.int]

Cause: the ECP wizard tried to add the first mailbox server to the DAG. During this process the wizard create a computer object in Active Directory (the CNO). This object doesn’t have the good rights. Exchange Trusted Subsystem had special permissions assigned and not “Full Control” on CNO (LABDAG-16).


Resolution: assign “Full Control” to Exchange Trusted Subsystem on the CNO of the DAG from Security Tab.



Second Issue: DNS Host Name

An Active Manager operation failed with a transient error. Please retry the operation. Error: The fully qualified domain name for node '' could not be found.

Cause: if you go in the property of the CNO, in the tab ‘general’, you will see the field “DNS name” empty. The ECP cannot find this information, that’s why you have this message.



Resolution: go ADUC, expand to Computers OU, in the property of the CNO (LABDAG-16), in the tab ‘attribute Editor’ tab and search for the “dNSHostName” attribute. Enter the FQDN of the CNO (LABDAG-16.DOMAIN.COM, for my case) and apply.

Third Issue: CNO not disable


A computer account named ' LABDAG-16' already exists and is enabled. The account must be disabled in order to be used by the database availability group.

Cause: the CNO is enable. To operate the ECP need to have the CNO disable. The ECP will enable the CNO itself.
Resolution: GO in Active Directory and disable the CNO
(LABDAG-16, for my case), and try it again.

How to Speed up mailbox migration to Exchange 2016

Moving mailboxes from 2010 to Exchange 2016 or Exchange 2016 can often go very slowly, even when the network and server resources are fast and abundant! 
The Exchange Mailbox Replication Service (MRS) has extensive resource throttling enabled by default in order to prevent mailbox moves from choking out the rest of the users.  Because of this you may see mailboxes with a status of RelinquishedWlmStall and if you look at the details of the Get-MoveRequestStatistics report you will see mailboxes have a lot of time sitting idle under the TotalStalledDueToWriteThrottle counter.

Microsoft tech support suggests making changes to the “MSExchangeMailboxReplication.exe.config” file located at “C:\Program Files\Microsoft\Exchange Server\V15\Bin”.  The values to look at, along with their default settings are:
MaxActiveMovesPerSourceMDB=”20″
MaxActiveMovesPerTargetMDB=”20″
MaxActiveMovesPerSourceServer=”100″
MaxActiveMovesPerTargetServer=”100″
MaxTotalRequestsPerMRS=”100″
ExportBufferSizeKB=”512″
We typically like to set these values so that about 10 mailboxes can be moved simultaneously.  The ExportBufferSizeKB we’ve used in the past is “10240”.  The Exchange Mailbox Replication Service should be restarted after these changes.
The other suggestion Microsoft has made is to disable content indexing on the target database so that the search index scanner isn’t overwhelmed by all the new messages needing to be indexed.  You’ll want to set it back once the migration is complete.
Set-MailboxDatabase “DB1” -IndexEnabled:$False
In our experience however, these first two suggestions do NOT have tremendous impact on the overall speed.  The following two options have proven to be the most effective for us.
Use the “-priority emergency” parameter on the mailbox moves.  This will give the move the highest priority in the MRS queue.  For example:
New-MoveRequest -Identity “user@domain.com” -TargetDatabase “DB1” -Priority emergency
If the priority flag and the MRS config editing doesn’t make the moves fast enough for you, then disable MRS throttling altogether!  To do this, change the “MRS” REG_DWORD key from 1 to 0 under this registry path:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\MSExchange ResourceHealth
Then restart the Exchange Mailbox Replication service.  Now your mailboxes will move without any throttling policy.  Once the mailbox migration is complete change the value back to 1 to re-enable MRS resource monitoring.


How to: Move Catalog Data in Exchange 2010


When you’ve moved an mailbox database, the old catalog data will stay on the old partition. This prevents deleting the specific partition. When you try to delete those files, you receive this error.


Error description:

The Catalog data folder stays in place after a database move path action. The folder couldn’t be cleaned up because it is in use by the Microsoft Exchange Search Indexing service


Solution:

First we have to temporarily disable the indexing on the particular mailbox database. Then we stop the indexing service of Exchange so we can delete the remaining files. The last step is to enable the indexing again.

Actions:
You can follow the next steps.

- Open the Exchange Management Shell and run the following command:

     Set-MailboxDatabase -Identity YourDBName -IndexEnabled $false

-Before moving / cleaning the catalog files, stop the service Microsoft Exchange Search Indexer
- Move the catalog files to the new database location or clean them up.
- Start the service Microsoft Exchange Search Indexer
- Open the Exchange Management Shell and run the following command:

Set-MailboxDatabase -Identity YourDBName  -IndexEnabled $true

Friday, March 18, 2016

How to get-MailboxDatabase size quickly

get-MailboxDatabase us-* -Status |select ServerName, Name, DatabaseSize > c:\usmbxDBsize.txt

This command will provide us a list of the mailbox DBs their names starting with "US-"

How to block spoofing email from Exchange 2013/2016 or Office 365

1. Sign in to Exchange Admin Center http://outlook.office365.com/ecp with an admin account.
2. Navigate to mail flow>rules and click the add icon to create a new rule.
3. Create a rule like this (don’t forget to click more options):
 
With this rule, emails from outside your organization with your domain to your organization will be blocked.

Wednesday, May 27, 2015

failed to uninstall last Exchange 2013

If you have to uninstall the first and last Exchange 2013 server in your org and failed with following errors:

Error:Uninstall can't continue. Database Mailbox Database XXXXXXXXX1 : This mailbox database contains one or more mailboxes, mailbox plans, archive mailboxes, public folder mailboxes or arbitration mailboxes. To get a list of all mailboxes in this database, run the command Get-Mailbox -Database . To get a list of all mailbox plans in this database, run the command Get-MailboxPlan. To get a list of archive mailboxes in this database, run the command Get-Mailbox -Database -Archive. To get a list of all public folder mailboxes in this database, run the command Get-Mailbox -Database -PublicFolder. To get a list of all arbitration mailboxes in this database, run the command Get-Mailbox -Database -Arbitration. To disable a non-arbitration mailbox so that you can delete the mailbox database, run the command Disable-Mailbox . To disable an archive mailbox so you can delete the mailbox database, run the command Disable-Mailbox -Archive. To disable a public folder mailbox so that you can delete the mailbox database, run the command Disable-Mailbox -PublicFolder. Arbitration mailboxes should be moved to another server; to do this, run the command New-MoveRequest . If this is the last server in the organization, run the command Disable-Mailbox -Arbitration -DisableLastArbitrationMailboxAllowed to disable the arbitration mailbox.

This is because you have one of the following:
  • Still have folders in your Public Folders
  • Still have Mailboxes in your Mailbox Datbases
  • Still have Mailbox Databses
Exchange 2013 uses a number of different types of mailboxes as seen below. Even if you have removed all of your users mailboxes you must still remove these mailboxes:

DISCOVERY MAILBOX
DiscoverySearchMailbox {D919BA05-46A6-415f-80AD-7E09334BB852}
MONITORING MAILBOXES
HealthMailbox62256620620346798029c55bfe0fcc5d
HealthMailboxb67c72c285f54c30bad37dd37eec361a
HealthMailbox721771958fa64a53aa78527c02caf55b
HealthMailbox995793b82c2c4a14b6173e54371179ec
HealthMailboxc8603cb9bb41442e8b402db42f93dc16
ARBITRATION MAILBOXES
SystemMailbox{1f05a927-c403-4250-9f07-c5e43605c1ac}
SystemMailbox{bb558c35-97f1-4cb9-8ff7-d53741dc928c}
SystemMailbox{e0dc1c29-89c3-4034-b678-e6c29d823ed9}
FederatedEmail.4c1f4d8b-8179-4148-93bf-00a95fa1e042
Migration.8f3e7716-2011-43e4-96b1-aba62d229136

These mailboxes must be removed before you can actually uninstall Exchange 2013  You can remove these mailboxes from the ECP however if you you may need to use the command below to allow you to remove the arbitration mailoxes, this command allows you to disable them
Get-Mailbox -Arbitration -Database <MailboxDatabase> | Disable-Mailbox -Arbitration -DisableLastArbitrationMailboxAllowed
Replacing the Mailboxdatabase information with your own. Once removed if you start to unistall Exchange 2013 the uninstallation should complete

and last

Get-mailbox  -Database <mailboxdatabase > |disable-mailbox

after that try to uninstall your Exchange 2013 server again.

Good Luck!

Thursday, April 2, 2015

How to check DAG Replication Status

get-DatabaseAvailabilityGroup USDAG-10 | %{ $_.Servers | %{ GetMailboxDatabaseCopyStatus -Server $_ } }

Friday, March 20, 2015

Exchange 2010 How to re-index mailbox database

 Note: Do the below if it happens all users on the DB. If just for one user, move the user to other DB to see if the issue is gone.

Exchange 2010 re-index mailbox database
Users may report that searching Outlook for non-cached or online mode mailboxes isn't getting the right results or not returning results past a certain date. Also OWA may return "The action couldn't be completed.  Try again later." when trying to search. You need to reindex your mailbox database(s). 
1. Run Repair-ExchangeSearchSymLinks.ps1. It isn't included in the normal scripts folder under the Exchange program files, you can copy this to a text document and save it as Repair-ExchangeSearchSymLinks.ps1.
01write-host "Attempting to repair symbolic links"
02 
03write-host "Stopping msftesql-exchange and msexchangesearch services"
04stop-service -Force msexchangesearch
05stop-service -Force msftesql-exchange
06 
07$rval = get-PSSnapin -Name Microsoft.Exchange.Management.PowerShell.Setup -ea SilentlyContinue
08if(!$rval)
09{
10 add-PSSnapin -Name Microsoft.Exchange.Management.PowerShell.Setup -ea SilentlyContinue
11}
12 
13write-host "Installing symbolic links"
14Install-ContentIndexingService –HubOnlyFilterRegistration
15 
16if(!$rval)
17{
18 Remove-PSSnapin -Name Microsoft.Exchange.Management.PowerShell.Setup -ea SilentlyContinue
19}
20 
21write-host "Starting msftesql-exchange and msexchangesearch services"
22start-service msexchangesearch
23start-service msftesql-exchange
24 
25write-host "Symbolic links restored."
26write-host "Please run test-exchangesearch to verify installation."
Or you can get it from Microsoft here if you don't trust me and place it in the Exchange Server\V14\Scripts folder. Open Exchange Management Shell (remember you might need to run EMS elevated and run Set-ExecutionPolicy Unrestricted first), change path to the scripts folder then run:
.\Repair-ExchangeSearchSymLinks.ps1
 
2. Next run the ResetSearchIndex.ps1 script, this one is included in the Exchange program files scripts folder so no need to download. You can run it against a specific database or against all of them as per the commands below:

.\ResetSearchIndex.ps1 -All    .\ResetSearchIndex.ps1 databasename
 
You should see event id 109 for each database stating that an index has been created and sometime later event id 110 for each database as the indexing finishes.

Thursday, March 19, 2015

How to: Move Catalog Data in Exchange 2010

How to: Move Catalog Data in Exchange 2010
 
 
When you've moved an mailbox database, the old catalog data is still present on the old partition. This prevents deleting the specific partition. When you try to delete those files, you receive this error.
 
Error description:
The Catalog data folder stays in place after a database move path action. The folder couldn't be cleaned up because it is in use by the Microsoft Exchange Search Indexing service
 
Solution:
First we have to temporarely disable the indexing on the particular mailbox database. Then we stop the indexing service of Exchange so we can delete the remaining files. The last step is to enable the indexing again.
 
Actions:
You can follow the next steps.
 
- Open the Exchange Management Shell and run the following command:

         Set-MailboxDatabase -Identity databasename -IndexEnabled $false

 -Before moving / cleaning the catalog files, stop the service Microsoft Exchange Search Indexer
         - Move the catalog files to the new database location or clean them up.
         - Start the service Microsoft Exchange Search Indexer
        - Open the Exchange Management Shell and run the following command:

    Set-MailboxDatabase -Identity databasename -IndexEnabled $true

Thursday, February 26, 2015

how to get mailbox counts per Mailbox Database quickly

How to get mailbox counts per Mailbox Database quickly

get-mailbox -resultsize unlimited | group-object -property Database -noelement

Wednesday, July 2, 2014

How to get public path via email address

You may have issue to find a public folder path that you know the email address of the PF:

Here is the cmdlet you need to find out the path:

1. Set-AdServerSettings -ViewEntireForest $true -PreferredGlobalCatalog gc1.contoso.com
2. Get-PublicFolder cmdlet to find the path via the PF's email address:

Get-MailPublicFolder AccountsPayable@domain.com | Get-PublicFolder

you will see output something like below:

Name                                                        Parent Path
----                                                             -----------
Accounts Payable                                     \Accounting\US\Americas Choice

Monday, June 9, 2014

Missing Autodiscover information in your Exchange Autodiscover XML Response?

We had issue with Outlook anywhere that cannot be configured automatically reported from remote site. When we use Remote Connectivity Analyzer (https://www.testexchangeconnectivity.com/) to test Outlook Autodiscover, all the External URL (items below the <Type>EXPR</Type> lines) was missing.

After carefully checking the output, our EXPR type output is as follow:

Type>expr</Type>
 <Server>exchange.contoso.com</Server>
 <ASUrl>https://exchange.contoso.com/EWS/Exchange.asmx</ASUrl>
 <OOFUrl>https://exchange.contoso.com/EWS/Exchange.asmx</OOFUrl>
 <OABUrl>https://exchange.contoso.com/OAB/83099da3-46bc-49e3-9e35-4353f0f95268/</OABUrl>
 <UMUrl>https://exchange.contoso.com/EWS/UM2007Legacy.asmx</UMUrl>
 <Port>0</Port>
 <DirectoryPort>0</DirectoryPort>
 <ReferralPort>0</ReferralPort>
 <SSL>On</SSL>
 <AuthPackage>Basic</AuthPackage>
 <EwsUrl>https://exchange.contoso.com/EWS/Exchange.asmx</EwsUrl>
 <SharingUrl>https://exchange.contoso.com/EWS/Exchange.asmx</SharingUrl>
 <EcpUrl>https://exchange.contoso.com/ecp/</EcpUrl>
 <EcpUrl-um>?p=customize/voicemail.aspx&amp;exsvurl=1</EcpUrl-um>
 <EcpUrl-aggr>?p=personalsettings/EmailSubscriptions.slab&amp;exsvurl=1</EcpUrl-aggr>
 <EcpUrl-mt>PersonalSettings/DeliveryReport.aspx?exsvurl=1&amp;IsOWA=&lt;IsOWA&gt;&amp;MsgID=&lt;MsgID&gt;&amp;Mbx=&lt;Mbx&gt;</EcpUrl-mt>
 <EcpUrl-ret>?p=organize/retentionpolicytags.slab&amp;exsvurl=1</EcpUrl-ret>
 <EcpUrl-sms>?p=sms/textmessaging.slab&amp;exsvurl=1</EcpUrl-sms>
 </Protocol>
 <Protocol>


and normal output should be as follows:

<Type>EXPR</Type>
 <Server>exchange.contoso.com</Server>
 <ASUrl>https://exchange.contoso.com/EWS/Exchange.asmx</ASUrl>
 <OOFUrl>https://exchange.contoso.com/EWS/Exchange.asmx</OOFUrl>
 <OABUrl>https://exchange.contoso.com/OAB/83099da3-46bc-49e3-9e35-4353f0f95268/</OABUrl>
 <UMUrl>https://exchange.contoso.com/EWS/UM2007Legacy.asmx</UMUrl>
 <Port>0</Port>
 <DirectoryPort>0</DirectoryPort>
 <ReferralPort>0</ReferralPort>
 <SSL>On</SSL>
 <AuthPackage>Basic</AuthPackage>
 <EwsUrl>https://exchange.contoso.com/EWS/Exchange.asmx</EwsUrl>
 <SharingUrl>https://exchange.contoso.com/EWS/Exchange.asmx</SharingUrl>
 <EcpUrl>https://exchange.contoso.com/ecp/</EcpUrl> ;
 <EcpUrl-um>?p=customize/voicemail.aspx&amp;exsvurl=1</EcpUrl-um>
 <EcpUrl-aggr>?p=personalsettings/EmailSubscriptions.slab&amp;exsvurl=1</EcpUrl-aggr>
 <EcpUrl-mt>PersonalSettings/DeliveryReport.aspx?exsvurl=1&amp;IsOWA=&lt;IsOWA&gt;&amp;MsgID=&lt;MsgID&gt;&amp;Mbx=&lt;Mbx&gt;</EcpUrl-mt>
 <EcpUrl-ret>?p=organize/retentionpolicytags.slab&amp;exsvurl=1</EcpUrl-ret>
 <EcpUrl-sms>?p=sms/textmessaging.slab&amp;exsvurl=1</EcpUrl-sms>
 </Protocol>
 <Protocol>


Do you see the difference between ours and normal Type>expr</Type> vs <Type>EXPR</Type>?

lowercase expr vs Uppercase EXPR.
Oups, EXPR is case sensitive here!!!
Check our Exchange configuration

>get-OutlookProvider -id expr |FL


RunspaceId           : a86dfb0a-3f3f-4b39-a264-cd6cd993853d
CertPrincipalName    :
Server               :
TTL                  : 1
OutlookProviderFlags : None
AdminDisplayName     :
ExchangeVersion      : 0.1 (8.0.535.0)
Name                 : expr
DistinguishedName    : CN=expr,CN=Outlook,CN=AutoDiscover,CN=Client Access,CN=contoso,CN=Microsoft Exchange,CN=Serv
                       ices,CN=Configuration,DC=contoso,DC=com
Identity             : expr
Guid                 : 57b60bde-e415-4ce2-b618-5a2425a230e7
ObjectCategory       : contoso.com/Configuration/Schema/ms-Exch-Auto-Discover-Config
ObjectClass          : {top, msExchAutoDiscoverConfig}
WhenChanged          : 3/3/2014 2:53:33 AM
WhenCreated          : 3/3/2014 2:41:58 AM
WhenChangedUTC       : 3/3/2014 7:53:33 AM
WhenCreatedUTC       : 3/3/2014 7:41:58 AM


As you can see above it seems some admin created Identity             : expr WhenCreated          : 3/3/2014 2:41:58 AM.
This is the root cause of the issue and the following cmdlet that helped us to fix the issue

Remove-OutlookProvider -Identity expr
New-OutlookProvider -Name EXPR

After that, run the following command to verify and test Outlook Anywhere works fine after that.

 >get-OutlookProvider -id expr |FL

RunspaceId           : 0c0cf3a8-ad17-432c-8b8d-0d6daabe64df
CertPrincipalName    :
Server               :
TTL                  : 1
OutlookProviderFlags : None
AdminDisplayName     :
ExchangeVersion      : 0.1 (8.0.535.0)
Name                 : EXPR
DistinguishedName    : CN=EXPR,CN=Outlook,CN=AutoDiscover,CN=Client Access,CN=contoso,CN=Microsoft Exchange,CN=Serv
                       ices,CN=Configuration,DC=randomhouse,DC=com
Identity             : EXPR
Guid                 : 49918614-cafb-4193-9f06-bdb2287c31f1
ObjectCategory       : contoso.com/Configuration/Schema/ms-Exch-Auto-Discover-Config
ObjectClass          : {top, msExchAutoDiscoverConfig}
WhenChanged          : 6/4/2014 2:55:02 PM
WhenCreated          : 6/4/2014 2:45:24 PM
WhenChangedUTC       : 6/4/2014 6:55:02 PM
WhenCreatedUTC       : 6/4/2014 6:45:24 PM


By the way, for those who ran the test and got the following error:

"The EXCH provider section is missing from the Autodiscover response" message and Exchange 2010 Outlook Anywhere (RPC over HTTP) not working

here is the fix for this:

The EXCH provider section is missing from the Autodiscover response"
 
I'm sure, you already checked all Internal / External URL settings
But, have you checked your Mailbox Database settings and see what do you have configured as RPCClientAccessServer? You can do this by running the following cmdlet:
 
Get-MailboxDatabase | fl Server, RPCClientAccessServer
 
If your RPCClientAccessServer is not set or set not exactly as it supposed to be, you can  correct this as illustrated in the following example:
 
Set-MailboxDatabase -Identity "MYMBXDB-1″ -RpcClientAccessServer outlook.contoso.com
 
Note: In this case outlook.contoso.com is a FQDN name of my Network Load balancer



Tuesday, May 27, 2014

How to use OAB Global Web Distribution in Exchange Server 2010


In Today's post I am going over a nice feature that is not used a lot in most of the customers that I worked with which is the Global web Distribution for OAB.
In the default OAB we will see something like this for the Default Offline Address Book. In a normal situation we would go there and enable the Web-based distribution and add the servers which is totally fine when you have a few servers and you don't change a lot.
However let's think for a moment in environment with lots of sites where all sites have Exchange Servers, or in multi-tenancy environment where several servers are added/removed in a monthly basis. For our environment, once we tried to add new server, it takes forever to get our server list
The automatic solution!
There is a neat solution called GlobalWebDistributionEnabled on each Offline Address Book. What this feature does is that configures automatic any new CAS server to receive the OAB which is great. If you want to do that
 
In order to get the information about any given OAB we can run the following cmdlet:
Get-OfflineAddressBook | Select Name,Version,AddressLists,Global* | fl
Cool, eh? If you want to enable that we just need to run the following cmdlet
Set-OfflineAddressBook –Identity '\Default Offline Address Book' –GlobalWebDistributionEnabled $True
Now if an administrator goes there to try to add something that is going to be the message that you won't able to add the server since you have GlobalWebDistributionEnabled.
Note: The Public folder distribution method is not impacted by this procedure so it's up to you whether you enable or not such feature.

Thursday, March 6, 2014

Configure the Autodiscover Service to Use AD Site Affinity

Set-ClientAccessServer -Identity "ServerName" -AutodiscoverSiteScope "Site-A","Site-B","Site-C"

Monday, January 13, 2014

Upgrade Distribution List from Exchange 2003 to Exchange 2010

Issue: We run issue with very strange mail routing. We are still in mixed mode with Exchange 2003 and Exchange 2010. One of users reported email delay happened to a specific DL.

Troubleshooting Steps:

After login to one of the mailboxes who received the email and found out very interesting routing behavior from the message headers:

Message was sent from an internal 3rd application, via port 25's PMTA. The message reached Exchange 2010 hub first, then forwarded to Legacy Exchange 2003 Connectors, then sent back to the Exchange 2010 Hub and back to users' mailbox on Exchange 2010.

The delay happened with some disk issue on one of legacy Exchange 2003 connector servers. First though could be due to the DL that has not be upgraded to Exchange 2010. Spent some time to upgrade all DLs at our Domains that all mailboxes have been upgraded to 2010 for a while. Working with scripts to remove space from alias, incorrect characters from DL alias such as "@", "(" or ")", BTW, here is the cmdlet I used to remove space, @, (, or ):

Get-DistributionGroup -ResultSize unlimited | foreach {$_.alias = $_.alias -replace '\s|,|\.'; $_} | Set-DistributionGroup
for removing space from alias or

Get-DistributionGroup  -ResultSize unlimited | foreach {$_.alias = $_.alias -replace '\s|,|\.' -replace '\(|,|\.' -replace '\)|,|\.' -replace  '\@|,|\.'; $_} | Set-DistributionGroup

Then run force upgrade of the DLs:

Get-DistributionGroup –ResultSize Unlimited | Set-DistributionGroup –ForceUpgrade

After that, you may still get some issue with some of DLs that you may have to manually upgrade.

All of DLs have been upgraded and the issue still existing.

After digging, and found out one of the Legacy Exchange 2003 Connector servers were running out of space. fixed the issue, reboot all Ex2003 connector servers and Exchange 2010 hub servers. Delay issue has been resolved, however, the strange email routing issue still existing.

Get-DistributionGroup   |FL printed output to file and focused on print out of the DL we had the issue.

Finally I found the settings of the DL was specified with the legacy Exchange 2003 server that we had issue as expansion server. After removed the expansion server, The strange routing issue has been resolved.

Here is the cmdlet I used to change all possible DLs that may have such settings:

Get-DistributionGroup –ResultSize Unlimited | Set-DistributionGroup -ExpansionServer $Null

Keyword: DistributionGroup upgrade, Exchange 2003 connector, Routing issue, Expansion Server of DL.



Tuesday, October 29, 2013

How to Disable Autodiscover in Outlook 2010/2013


There is an MS KB article to reference and Outlook 2007 and 2010 ADM files http://support.microsoft.com/kb/2612922. The ADM files attached to the article were great because they gave a way to disable the different methods Outlook uses to determine autodiscover in Outlook 2007 and 2010. Outlook (generically) uses 5 methods to determine discoverer.
  1. SCP object lookup
  2. Root domain query based on your primary SMTP address
  3. Query for the AutoDiscover domain
  4. HTTP redirect
  5. SRV record query in DNS
Unfortunately Outlook 2013 is a little new and MS doesn't have a nice preconfigured ADM. That's ok because the exact same methods for autodiscover are used in 2013 as they were in previous version.
We can create a reg file for 2013 by exporting the key that gets created when the ADM is applied via GPO for 2010 and just changing the registry path. So instead of:
HKEY_CURRENT_USER\Software\Policies\Microsoft\Office\14.0\Outlook\AutoDiscover
I changed it to:
HKEY_CURRENT_USER\Software\Policies\Microsoft\Office\15.0\Outlook\AutoDiscover
You can change the various options from the registry file as well. They are:
"ExcludeScpLookup"=dword:00000001
"ExcludeHttpsRootDomain"=dword:00000000
"ExcludeHttpsAutoDiscoverDomain"=dword:00000000
"ExcludeHttpRedirect"=dword:00000000
"ExcludeSrvRecord"=dword:00000000
Above the SCP lookup is disabled.
 

Friday, October 18, 2013

How to use the ADModify.NET tool to add an X.500 proxy address to multiple accounts

How to use the ADModify.NET tool to add an X.500 proxy address to a user account
Admodify2.1 nolonger support X500 tab entry, thus we will have to use custom tab.
 
X500 addresses are useful once we migrated volume of mailboxes from another organization and we enabled GAL sync between Exchange organizations before migration. Lack of the lagacyExchangeDN of old organization or x500 address, migrated users may get NDR once they tried to reply to existing emails to certain users.
  1. Click the Custom tab.
  2. Under Custom Attribute Set, follow these steps:
  3. Click to select the Make a customized attribute modification check box.
  4. In the Attribute Name box, type proxyAddresses.
  5. In the Attribute Value box, type the X.500 address.

    For example, if you want an X.500 address of /o=OldOrganization/ou=OldSite/cn=Recipients/cn=mailNickname, type the following in the Attribute Value box:
    X500:/o=OldOrganization/ou=OldSite/cn=Recipients/cn=%'mailNickname'%


    In this example, we use the %'mailNickname'% variable because we assume that the mailNickname attribute in the new organization matches the mailNickname attribute in the old organization. If these attributes do not match, use another variable.

    Note If the migrated user account is from an Active Directory directory service environment, use the Adsiedit tool to locate the old legacyExchangeDN attribute of the user. Then, use the old legacyExchangeDN attribute for the X.500 address.
  6. Click Multivalued Append, and then click Go.
 
 
 

Use Poolmon to identify Exchange 2010 mailbox server memory leaking issue

We have four hardware identical Cisco UCS servers that installed as Exchange mailbox servers mailbox role and joined DAG replication partners. Two local servers are working fine. However, two remote servers keeping running out of memory and we had to reboot these two servers at regular base (once a month) until we used Poolmon to identify the cause of the memory leaking, a known Cisco NIC teaming bug. Poolmon was able to identify with tag Team caused memory leaking that consumed more than 5 GB nonpaged memory before the server running out of available memory less than 20MB of 96 GB physical RAM and Hard Faults per sec pager constantly reached 100.
 
Once poolmon identify tag Team, then we used the following string to find the driver that caused the memory leaking:
 
findstr /m /l team *.sys either of system32  or \system32\drivers directory.
 
for more info, please read the following links:
 
 

Wednesday, October 2, 2013

How to Disable Attachment Filtering on Exchange 2010 Edge Transport

We had an interesting issue recently where our Exchange 2010 Edge Transport server was erroneously stripping out .docx, .xlxs, and .pdf files. 
 
There is a Microsoft KB to address the issue, however, it doesn't work for us.
 

The attachmentfilteragent has been enabled by default, and I wanted it off, so we needed to add an exception for our receive connector. It's not as straightforward as you would expect though to turn off attachment filtering on an Exchange 2010 Edge Transport server.
 
The first step is to see if there are any connectors on the attachment filter exception list presently.  To do so, run this command:
 

Get-AttachmentFilterListConfig
 
About the fifth line down you should see "ExceptionConnectors" which probably has nothing next to it. 
You can only turn off attachment filtering by referencing the GUID, so now we need to get the GUID of the relevant receive connector. 
 

Get-ReceiveConnector  | Format-List
 
This will give us all the properties of our Receive Connector, including the GUID, which will be listed about 10 lines up from the bottom. Now that we have the GUID, we can run the command to add the receive connector to the list of exceptions for attachment filtering by running this:
 

Set-AttachmentFilterListConfig –ExceptionConnectors [GUID]
 
Replacing [GUID] with the GUID we retrieved in the previous step.
 
Finally, run Get-AttachmentFilterListConfig again and check the Exceptions line, you should now see your receive connector listed there.
 
reference link:
 

Monday, August 5, 2013

Move Public Folder Content from One Public Folder Database to Another Public Folder Database

Use the MoveAllReplicas.ps1 script to move all public folder content from one server to another server
 

To move all public folders in a public folder database on one server to a public folder database on another server, use the MoveAllReplicas.ps1 script. This script replaces a server with a new server in the replication list for all public folders, including system folders. For more information about using public folder scripts, see Scripts for Managing Public Folders in the Exchange Management Shell.

This example moves all public folder content from Server01 to Server02.

cd $EXscripts

.\MoveAllReplicas.ps1 -Server Server01 -NewServer Server02
 
If you are move from Exchange 2007 to Exchange 2010, you had better run the scripts from Exchange 2010 servers.
 
However, I would prefer you run the following script first, and make sure all public folders including system folders are replicated to new server first,
 
1. run Get-PublicFolder -Server OldPFServername -Recurse | FL Name,Replicas
 
If there is any issue, fix it first, say, some of old PF folders may contain leading or trialing whitespace that no longer support in new Exchange server.
 

WARNING: The Name property
contains leading or trailing whitespace, which must be removed.
 

2. use AddReplicaToPFRecursive.ps1 to replicate all Folders to new server
 
[PS] C:\Program Files\Microsoft\Exchange Server\V14\Scripts>.\AddReplicaToPFRecursive.ps1
 

AddReplicaToPFRecursive.ps1 -Server "MyEx2007Server" -TopPublicFolder "\" -ServerToAdd "MyEx2010Server"
 
3.\AddReplicaToPFRecursive.ps1 -Server "MyEx2007Server" -TopPublicFolder "\NON_IPM_Subtree" -ServerToAdd "MyEx2010Server"
 
The above command will add replica of all public folders to exchange 2010 public folder database.
Once the replica is added you can move the replica from Exchange 2007 to Exchange 2010. To do this execute the below EMS command:

4. .\MoveAllReplicas.ps1 -Server "MyEx2007Server" -NewServer "MyEx2010Server"