The Scenario: You fail over Exchange but your replica has a corrupt copy of the Exchange database. The problem is that WANSync will the excpect you to "replicate" the data back before it will allow you to failover (or failback). But, you don't want to replicate back a corrupt database. While you can of course start up the services on the old master and turn off the services on the old replica (the one that was supposed to be the new master), your Active Directory will not be in a working state. Why? Part of switchover Exchange is that it rewrites every AD user object that has a mailbox to reflect the new server as being the location for the user's mailbox. If you were to bring back up the old master and nothing more, all user objects in AD with a mailbox will have the mailbox location attribute pointing to the replica, the server with the corruped database. The following commands are how you manually failback an Exchange scenario, or to be more correct, you are not really failing or switching anything to do with the Exchange server itself, you are really only modifying all the user accounts in AD to point to a specific Exchange server, that is all that is being done. You should manage Exchange at this point with Exchange tools... The Process: Log onto the Exchange server you wish to use. The old master, the one that does not have a corrupt database because you were just using it... Open a Command Prompt and change directory to the WANSync directory: cd /d c:\program files\xosoft\wansync\ First you must ensure that all WANSync scenarios dealing with Exchange are stopped. The can be done with a command, but, it you are not comfortable doing it this way, do it from the WANSync manager, there is no difference. Also note that the scenario should be stopped anyway, since automatic reverse replication is not enabled on any of CTSs WANSync scenarios. The command line method is: ws_cli.exe -r scenario_name -m stop Now, the main part, this command will simply go into AD and change each user object's mailbox location to reflect the Exchange server with the good database. ws_ex2ex.exe -p -a -z -s "MASTER_EXCH_SERVER_NAME" -t "REPLICA_EXCH_SERVER_NAME" This command is designed for manual failover, thus MASTER is the one that is supposed to be up and working but has failed. In the case of a manual, failback, the master will be the one that was switch over to, but didn't work, so it is the master technically as far as WANSync's "state" is concerned. Also think of the meaning of the command line switches: -s = source - bad server -t = target - good server In the command above, the MASTER is a WANSync word, when your Exchange server is down, that may not be as clear so also think of the word MASTER to mean, the Exchange Server that is bad... The REPLICA, will be known as the Exchange Server that does work. Remember, this command is actually not doing anything to the Exchange Servers themselves, it is actually contacting Active Directory and modifying all the user accounts, it will also display the user objects as the command runs. The following command will stop Exchange Services and set them to manual. In an emergency situation, just open up the services.msc console and do it via GUI. But just FYI, the following command used to be used in a script and run from the MASTER because failing over was the process of STOPPING the services on the MASTER so that the REPLICA was the new MASTER (this command is run on the server that you want the services stoped on): ws_ex2ex.exe -r stop -b manual Now, when you run the command the MODIFIES all the user objects in AD, the ws_ex2ex.exe utility will BIND to one DC and do just that. But, replication will not occur immediately, just as we all expect from AD. The old script used to force replication by running the following command from the 2003 system tools MSI, but in a real world situation, just user AD Sites and Services and force replication via GUI: repadmin.exe /syncall DC_NAME "dc=coopertsmith,dc=com" /e repadmin.exe /syncall DC_NAME "cn=configuration,dc=coopertsmith,dc=com" /e You must run the command and specify each DC: repadmin.exe /syncall NOLA1 "dc=coopertsmith,dc=com" /e repadmin.exe /syncall NOLA1 "cn=configuration,dc=coopertsmith,dc=com" /e repadmin.exe /syncall NOLA2 "dc=coopertsmith,dc=com" /e repadmin.exe /syncall NOLA2 "cn=configuration,dc=coopertsmith,dc=com" /e repadmin.exe /syncall COOP05 "dc=coopertsmith,dc=com" /e repadmin.exe /syncall COOP05 "cn=configuration,dc=coopertsmith,dc=com" /e repadmin.exe /syncall COOP06 "dc=coopertsmith,dc=com" /e repadmin.exe /syncall COOP06 "cn=configuration,dc=coopertsmith,dc=com" /e The following command is not related to a failed Exchange switchover, but if you ever find that your public folders are homed to the wrong server, use the following command to rehome all the folders to the MASTER, note that you should never have both servers listed as replicas: ws_ex2ex.exe -p -z -s "MASTER_EXCH_SERVER" -t "REPLICA_EXCH_SERVER" Summary: o Make sure all Exchange Services are set to run with the working server, that is, working server Exchange Services running, corrupted server services stopped. o Make sure the scenarios are stopped (the should be already but verify). o Log onto the working Exchange server (technically not required, either will work), Open a Command Prompt: cd /d c:\program files\xosoft\wansync\ ws_ex2ex.exe -p -a -z -s "CORRUPT_EXCH_SERVER" -t "WORKING_EXCH_SERVER" o Open up AD Sites and Services on any DC, replicate all AD connections. o Done. Note: The ws_ex2ex.exe command that switches the Exchange servers is not really doing anything to Exchange as I said. This is so true that if you were to make a TYPO in the command for instance, target of -t "ABC", all the user's mailboxes would then point to a server named ABC, so don't make a TYPO. The -s (source) switch is there because the command searches for all users mailboxes that currently point to the source server, and then reswrites them to point to the target (-t). This would be in case you have say a 3rd Exchange server, that way user accounts who have a mailbox on EXCHANGE3, are not modified at all. While this may seem like extra information, it is helpful to understand what is really going on because in the event you have to actually perform this operation, you will be much more comfortable and less prone to making a mistake if you actually understand what you are doing.