Monday, December 6, 2010
Exchange 2003: Decommissioning an Exchange 5.5 Environment
1. Check that a client inside the site (administrative group) can download the OAB.
2. Check that a client inside the site can see free busy information within the site.
3. Check that a client outside the site can see free busy information within the site to be decommissioned.
Ensure the Site Replication Service is started on each Exchange 2003 SRS:
1. On each Exchange 2003 SRS server, open Services MMC console and ensure Microsoft Exchange Site Replication Service is started.
Verify no mailboxes remain on the Exchange 5.5 server (this is expected to have already been performed):
1. Open Microsoft Exchange Administrator on the Exchange 5.5 server
2. Expand the siteConfigurationServersExpand the server to be decommissionedPrivate Information StoreMailbox Resources.
3. Ensure there are no mailboxes listed other than System Attendant and Directory Service.
4. Remove any other mailboxes or move them to an Exchange 2003 server using Exchange System Manager.
Verify all required public folders have replicated to an Exchange 2003 server in the site (this is expected to have already been performed):
1. Log into the Exchange 2003 SRS server and open the EXDEPLOY folder from the Exchange 2003 installation files.
2. Run PFMIGRATE.WSF /S:EX55SVR /T:EX2K3SVR /R to determine if there are any public folders not yet replicated to 2003.
3. If necessary, run PFMIGRATE.WSF /S:EX55SVR /T:EX2K3SVR /A /N:100 to add Exchange 2003 to the replica list of any non-replicated public folders.
4. Replicate the ADC public folder agreement and then Active Directory
5. Open Exchange System ManagerAdministrative GroupsSite NameFolders.
6. For each of the folders that were updated (see the PFMIGRATE log file), check under the Status tab that the folder has the expected number of items listed.
Remove all public folders from the Exchange 5.5 server:
1. See http://technet.microsoft.com/en-us/library/bb124112(EXCHG.65).aspx
2. Log into the Exchange 5.5 server to be decommissioned.
3. Start Microsoft Exchange AdministratorSite NameServersServer to be decommissionedPublic Information StorePropertiesAge Limits.
4. Ensure there are no public folder instances listed except system folders.
5. If this is the last server in the site, there should only be site-specific folders listed.
6. If there are public folders listed then run PFMIGRATE.WSF /S:EX55SVR /T:EX2K3SVR /D to remove the public folder replicas from Exchange 5.5 wherever there is already a replica on Exchange 2003.
7. Recommended: Set the replication schedule on the public information store to always in order to speed up the process.
8. Repeat steps 1 – 5 to ensure the replicas have been removed.
Verify the Offline Address Book is replicated to an Exchange 2003 server in the site:
1. See http://support.microsoft.com/?kbid=152959
2. See http://support.microsoft.com/default.aspx?kbid=822450
3. Log into the Exchange 2003 server in the site.
4. Start Exchange System ManagerAdministrative GroupsSite NameFoldersView System Folders.
5. Expand Offline Address Book. The OAB should be in the format: EX:/O=ORG/OU=Site.
6. Select the OABPropertiesReplication tabVerify an Exchange 2003 server is listed.
7. If there are no replicas then click Add to add one.
8. Repeat steps 1-7 for OAB Version 2 if present.
9. Alternative method is to use PFMIGRATE.WSF /S:EX55SVR /T:EX2K3SVR /A /N:50 /SF to replicate this and all other system folders to Exchange 2003
Verify Schedule+ Free Busy Information have replicated to an Exchange 2003 server in the site
1. Repeat steps for the OAB above in order to ensure that there is an Exchange 2003 replica of the Schedule+ Free Busy folder for the site
Note: Free/busy may be unavailable for some users until it is generated by activity in their calendar. There should be at least one Exchange 2003 replica of free/busy for every Exchange site.
Verify the Organization Forms are replicated to an Exchange 2003 server in the site:
1. Repeat steps for the OAB above in order to ensure that there is an Exchange 2003 replica of the Organization Forms folder.
Move the Routing Calculation Server role to Exchange 2003 SRS:
1. Open Exchange 5.5 Administrator and connect to a server in the site.
2. Expand the Site NameConfigurationSite AddressingProperties.
3. Set the Routing calculation server to the Exchange 2003 SRS server in the site.
4. On the Routing tab, click Recalculate Routing.
5. To reflect the change immediately on the Exchange SRS, either restart the SRS service or open Exchange 5.5 Administrator > Select the SRS server > Microsoft Exchange Site Replication Service > Properties > Update Now
6. To reflect the change immediately in Exchange 5.5, open Exchange 5.5 Administrator > Select the SRS server > Directory Service > Properties > Update Now
7. To reflect the change in AD and Exchange System Manager, replicate the ADC Config_CA connections.
Move Replication Connector to an Exchange 2003 SRS server in the site:
1. See http://technet.microsoft.com/en-us/library/bb124174(EXCHG.65).aspx
2. See http://support.microsoft.com/kb/822450
3. Replicate connections and test mail flow between the site and another site after moving each connector across.
4. Log into the Exchange 2003 serverOpen Exchange Administrator for Exchange 5.5Site NameConfigurationDirectory Replication.
5. Open each Directory Replication Connector (except ADNAutoDRC) and change the local bridgehead server to the Exchange 2003 SRS server in the site. Also change the remote bridgehead for the partner Directory Replication connector in the other site.
Move connectors to an Exchange 2003 SRS server in the site by replacing them with Routing Group Connectors:
1. See http://technet.microsoft.com/en-us/library/bb124174(EXCHG.65).aspx
2. See http://support.microsoft.com/kb/822450
3. Open Exchange System Manager and create a Routing Group Connector that parallels every Exchanger 5.5 Site Connector in the site. For example, if there is a site connector between SiteA and SiteB then create a Routing Group Connector between SiteA and SiteB. Set the connector cost to “1”.
4. Log into the Exchange 2003 serverOpen Exchange Administrator for Exchange 5.5Site NameConfigurationConnections.
5. On each Site Connector to and from this site, change the cost to “2” or greater.
6. On each Site Connector from this site, set the Messaging Bridgehead to the Exchange 2003 SRS in the site.
7. On each Site Connector that connects to this site, set the Exchange 2003 SRS as the only remote bridgehead server.
8. Replicate this change through the organization and test mail flow immediately.
9. If mail flow stops working, reverse the changes made to the Site Connectors.
If there is an X400 connector or other connector then also update the bridgeheads on these connectors in both the local and remote sites.
If there is a “Connector for cc:Mail” or “MS Mail Connector” and they are not in use then these can be safely ignored and removed when Exchange 5.5 is uninstalled.
Verify that Internet e-mail connectors on the Exchange 5.5 server are moved to Exchange 2003:
1. Log into the Exchange 2003 serverOpen Exchange Administrator for Exchange 5.5Site NameConfigurationConnections.
2. Check for the presence of an Internet Mail Service.
3. Move any existing Internet Mail Service to Exchange 2003 by following http://support.microsoft.com/kb/883407/.
Verify expansion server for all distribution lists in the site are not set to an Exchange 5.5 server:
1. Open Exchange 5.5 Administrator.
2. Open each distribution list in the site and check that Expansion server is set to “Any Server In Site” or to the name of an Exchange 2003 server.
Force ADC replication on the Config CA connection agreement
1. Open the ADC management tool and replicate the Config CA connection agreements.
Force replication through Active Directory
1. Open Active Directory Sites and Services.
2. Replicate all connections.
Wait for public folders, Schedule+ Free Busy, and Organization Forms information to replicate before continuing.
1. Check in Exchange System Manager that Connector modifications have replicated.
2. Open Outlook and connect to a mailbox in the site to ensure that public folders appear as expected and free/busy data can be viewed for other users in the site.
3. Attempt to download the Offline Address Book. If it fails then force a rebuild of the OAB from Exchange System Manager.
4. Open organizational forms in Outlook and confirm that they open (if applicable)
Disable Exchange services and shutdown the Exchange 5.5 server for testing
See functional testing plan
Start the Exchange server
Restart the Exchange services
Remove Exchange 5.5 from the server:
1. Start the Exchange Server 5.5 CD and run setup.exe.
2. On the Microsoft Exchange Server Setup page, click Add/Remove.
3. Clear the checkbox for Microsoft Exchange Server and click Continue.
4. Use Exchange 5.5 Administrator to connect to another server in the site (the Exchange 2003 SRS server will be fine).
5. Confirm that the SRS service is running.
6. Select the server to be removed.
7. On the Edit menu, click Delete.
Remove the Exchange 5.5 server from the SRS database and Active Directory:
1. See http://technet.microsoft.com/en-us/library/bb124174(EXCHG.65).aspx
2. Open the Active Directory Connector Tool MMC console, right click the Config_CA_Site_Server_Name object, and then click Replicate Now.
3. Replicate Active Directory
See functional testing plan
Prepare final Exchange 5.5 server for removal:
1. See major task 1
See functional testing plan
Remove final Exchange 5.5 server:
1. See major task 3
See functional testing plan
Remove Exchange SRS:
1. Follow directions specified at http://technet.microsoft.com/en-us/library/bb124572(EXCHG.65).aspx
2. Do not remove the Config_CA connection agreement!
Remove any Directory Replication Connectors:
1. See http://support.microsoft.com/kb/272314/
2. Use Exchange 5.5 Administrator to connect to each SRS in the organization.
3. For each SRS, expand the local site name, expand Configuration, click Directory Replication Connectors.
4. Delete any Directory Replication Connectors that exist. Do not delete ADNAutoDRC connector listed under Directory Replication Connectors!
5. Allow time for Config_CAs to replicate the changes to Active Directory.
Remove all SRS in the organization:
1. Start Exchange System Manager and ensure no Exchange 5.5 server computers are displayed in any administrative group.
2. Navigate to the Tools container, click the Site Replication Services container.
3. Right click each SRS and then click Delete. This will remove the SRS and corresponding Config_CA.
4. Confirm that all SRS have been removed from the entire organization.
Remove the Active Directory Connector service by uninstalling it.
Exchange 2003: Issues (including migration)
Check that the folders OAB Version 2 and OAB Version 3a exist under /o=Org/cn=addrlists/cn=oabs/cn=Default Offline Address List
If they do not exist then you can recreate them by forcing a rebuild of the offline address list: -
Exchange System Manager > Recipients > Offline Address Lists > Right click the offline address list > Rebuild
If the address list does not exist at all then recreate it according to http://blogs.msdn.com/b/dgoldman/archive/2007/04/19/outlook-oab-download-fails-with-0x80004005-and-0x8004010f.aspx.
Check that there is either a replica in the administrative group / routing group, or that public folder referrals is enabled across each relevant routing group connector
See http://technet.microsoft.com/en-us/library/aa996531(EXCHG.65).aspx for further details.
Unable to see OAB for Exchange 5.5 users (co-existence)
Check that the Exchange 5.5 OAB has been generated
Open Exchange 5.5 Administrator > Site Name > Configuration > in the right hand pane open DS Site Configuration > Offline Address Book tab > Generate All
Once it is generated it will appear in the system folders under Exchange Administrator > Folders > System Folders > OFFLINE ADDRESS BOOK > EX:/=Org/ou=Site Name. It will be called OAB Version 2.
Unable to see Free/busy for Exchange 5.5 users in Exchange 2003
Ensure there is an Exchange 2003 replica of Exchange 5.5 free busy folders. This may need to be replicated to all Exchange 2003 routing groups, or else check that the routing group connectors allow public folder referrals.
Monday, April 12, 2010
Exchange: Migrate from Exchange 2007 to Exchange 2010 Forest
mailbox B --> contact in org B --> mailbox A
So the question is how to merge the mailboxes into a single mailbox in org B?
Option 1:
The first option will require Exchange 2007 to be running at least SP2. This option would be to backup then remove the mailbox and contact in org B, these can be replaced by a mail enabled user in org A which forwards to org B.
Define the users to be migrated
First create the variables that will be used to define the migration. For each user to be migrated, you will need to know: -
a) the email address that is the target address on the contact ($useremailorgA)
b) an email address that is common between the source and destination mailboxes ($useremailorgB)
c) the user account name of the destination mailbox user ($usernameorgB)
Perform a test migration
So lets define these values for a test user: -
$useremailorgA = "user@orgA.com"
$useremailorgB = "user@orgB.com"
$usernameorgB = "user"
Now lets create a test mailbox and contact on the target organization (make sure to edit this according to your situation): -
$fname = Read-Host "Enter the first name"
$lname = Read-Host "Enter the last name"
$password = Read-Host "Enter password" -AsSecureString
$extemail = Read-Host "Enter the TARGET email address for the contact"
$database = "GC-Temp"
$orgunit = "MEL"
$contactorgunit = "Users"
$alias = $fname + "." + $lname
$name = $fname + " " + $lname
$upn = $fname + "." + $lname + "@target.com.au"
$mymailbox = New-Mailbox -UserPrincipalName $upn -Alias $alias -Database $database -Name $name -OrganizationalUnit $orgunit -Password $password -FirstName $fname -LastName $fname -DisplayName $name -ResetPasswordOnNextLogon $false
start-sleep -s 5
new-mailcontact -Name $name -ExternalEmailAddress $extemail -OrganizationalUnit $contactorgunit
Set-Mailbox $mymailbox -ForwardingAddress $extemail
You might like to perform a PST backup of the target mailboxes before they are removed. Remember you must have Outlook 2010 installed on the Exchange server to do this: -
Get-mailbox | where {$_.PrimarySmtpAddress –eq $useremailorgB} | Export-mailbox –PSTFolderPath C:\PSTBackup
Now we must do something funky to "convert" the user mailbox and contact into a mail-enabled user that old emails will still reply to. To do this, the destination mail-user should have the following properties: -
a) An X500 address that matches the LegacyExchangeDN of the mailbox
b) An X500 address that matches the LegacyExchangeDN of the contact
c) All email addresses that were contained on the mailbox and contact
d) An email address xyz@orga.com.au where the contact forwarded to xyz@orga.com.au - this one is very important as in this case the X500 address does not appear to quite be enough.
To automate this, create a script that goes a little like below ). For this to work you will need to list users to be modifed in a CSV file that contains the following headings:
TargetUserName, CommonEmailAddress
(Note that this email address must exist on both the source and target mailboxes)
#IMPORT LIST OF USERS FROM CSV
$LIST = Import-CSV UserList.CSV
#CYCLE THROUGH EACH ROW IN CSV
FOREACH($USER in $LIST) {
$targetusername = $USER.TargetUserName
$commonSMTPaddress = $USER.commonemailaddress
#Locate Target Mailbox
$TargetMailbox = Get-Mailbox $targetusername
$TargetMailboxDN = $TargetMailbox.distinguishedname
#Locate Target Contact
$TargetContactDN = $TargetMailbox.ForwardingAddress.DistinguishedName
$TargetContact = Get-MailContact $TargetContactDN
#Determine Target Contact External Address
$TargetContactExternalAddress = $TargetContact.ExternalEmailAddress
$TargetContactExternalAddressString = [string]$TargetContactExternalAddress.AddressString
#Determine Target Mailbox Primary Address
$TargetMailboxPrimaryAddress = $TargetMailbox.PrimarySMTPAddress
$TargetMailboxPrimaryAddressString = [string]$TargetMailboxPrimaryAddress
#Retrieve email addresses on the Mailbox
$TargetMailboxLegacyExchangeDN = [string]$TargetMailbox.LegacyExchangeDN
$EmailAddresses = $TargetMailbox.EmailAddresses
$EmailAddresses += [Microsoft.Exchange.Data.CustomProxyAddress]("X500:" + $TargetMailboxLegacyExchangeDN)
#Retrieve email addresses on the Contact
$TargetContactLegacyExchangeDN = [string]$TargetContact.LegacyExchangeDN
$EmailAddresses += $TargetContact.EmailAddresses
$EmailAddresses += [Microsoft.Exchange.Data.CustomProxyAddress]("X500:" + $TargetContactLegacyExchangeDN)
#take the ALIAS of the contact target path and join it to the domain name of the mailbox then add it to the email addresses
$TargetContactExternalAddressAliasLocation = $TargetContactExternalAddressString.indexof("@")
$TargetContactExternalAddressAlias = $TargetContactExternalAddressString.Substring(0,$TargetContactExternalAddressAliasLocation)
$TargetMailboxDomainLocation = $TargetMailboxPrimaryAddressString.indexof("@")
$TargetMailboxDomain = $TargetMailboxPrimaryAddressString.Substring($TargetMailboxDomainLocation)
$FreeEmailAddress = $TargetContactExternalAddressAlias + $TargetMailboxDomain
If (-not $EmailAddresses -eq $FreeEmailAddress) {
$EmailAddresses += [Microsoft.Exchange.Data.proxyaddress] ($FreeEmailAddress)
Write-Host "Adding new email address..."
}
If ($EmailAddresses -eq $FreeEmailAddress) {
$FreeEmailAddress = "Already in list..."
}
#Provide information back to user
Write-Host "===================================="
Write-Host "MIGRATION OF:" $targetusername
Write-Host "===================================="
Write-Host "TargetMailbox: "$TargetMailbox.DisplayName
Write-Host "Target Mailbox Primary Email Address: "$TargetMailboxPrimaryAddress
Write-Host
Write-Host "TargetContact: "$TargetContact.DisplayName
Write-Host "Forwarding Address: "$TargetContact.ExternalEmailAddress.AddressString
Write-Host "Common Email Address (for matching purposes): "$commonSMTPaddress
Write-Host
Write-Host "Providing new email address free of charge: "$FreeEmailAddress
$EmailAddresses Format-Table Prefix,AddressString -wrap -autosize
#Confirm to proceed with merging the contact and mailbox
Write-Host "PLEASE PERFORM AN EXPORT OF ALL MAILBOXES AND CONTACTS TO BE MERGED PRIOR TO PERFORMING THIS TASK. USE GET-USER, GET-MAILBOX, and GET-MAILCONTACT TO PERFORM THIS BACKUP."
$myInput = Read-Host "Please confirm the merging of the above mailbox and contact by pressing y to continue consolidation"
if ($myInput -ne "y") {
"Conversion aborted at users request"
BREAK
}
#Disable the mailbox and contact
Disable-Mailbox $TargetMailbox -confirm:$false
Remove-MailContact $TargetContact -confirm:$false
#Mail-enable the user object
$TargetMailUser = Enable-MailUser -Identity $TargetUserName -ExternalEmailAddress $TargetContactExternalAddress
Write-Host "If there are no errors then the consolidation is complete for this user."
}
"Conversion of user from Mailbox to Mailuser complete."
Now once we define the above variables, we just run this script against it - your mailbox and contact will disappear and a new mail-user will appear in its place. and hopefully keep delivering mail, even replies to older emails!
There, now we have:
Mailuser B --> Mailbox A
Ready to migrate
We have now configured co-existence and prepared our environment for the migration. Now we need to make sure there is a common proxy address on each Mailuser B and Mailbox A. This would probably be alias@orgb.com. If there is not a common proxy address, you will need to make one by modifying the email policies.
Then we prepare the migration with the prepare-moveerquest:
#Now we need to make sure there is a common proxy address on each Mailuser B and Mailbox A. This would probably be alias@orgb.com. If there is not a common proxy address, you will need to make one by modifying the email policies.
#This command prepares the migration by linking the source and target mailboxes. Note that this step will convert the target mailuser into a mailbox object.
$useremailorgB = "user.name@target.local"
$RemoteDomainController = "source.DC.local"
Prepare-MoveRequest.ps1 -Identity $useremailorgB -RemoteForestDomainController $RemoteDomainController –UseLocalObject
This Prepare-MoveRequest creates a mailbox in the destination organization to correspond with the specified user, and with all required attributes (such as MsExchGUID – spelling?). The “UseLocalObject” is required if there is already an object in the destination with the same proxy addresses. In this case there is (we have a mail-enabled object that we created earlier). It will then delete the existing object and create a new one as per requirements. Mail should continue to flow as per normal at this stage. Note that you can only do this with a contact or mail enabled user in the target forest, you cannot use it to merge to an existing mailbox (this is why we converted the mailbox to a mail-enabled user in an earlier step!).
Then we go ahead and migrate the mailbox when we are ready:
#This step moves mailboxes between organisations - but must be run following the Prepare-MoveRequest command. Note that this step will create a contact in the source organisation which will continue to facilitate mail flow.
$UserEmailOrgB = "user.name@target.local"
$Cred = Get-Credential
new-moverequest -identity $useremailorgB -RemoteLegacy -TargetDatabase "Mailbox Database 0698034315" -RemoteGlobalCatalog source.DC.local -RemoteCredential $Cred -TargetDeliveryDomain 'target.local'
The new-moverequest handily also creates a contact in the source organization once the mailbox has been moved across.
Now that was easy wasn't it!
Option 2:
Second option is to export the mailbox from OrgA and import it into the mailbox in Org B.
This option requires installing the Exchange 2007 SP2 admin tools on a workstation with Office 2007 or later. This workstation will be used to export the mailboxes to PST.
The process would have to go a little like this:
1. Start of outage
2. Disable forwarder in OrgB (Powershell)
3. Remove contact in OrgB (Powershell)
4. Assign SOURCE email address to mailbox in OrgB (Powershell)
5. Enable the forwarder in OrgA (Powershell)
6. Export mailbox from Exchange 2007 to PST (Powershell)
7. Import mailbox to Exchange 2010 (Powershell)
8. Assume that there are no special email addresses on the OrgA mailbox.
$useremailorgA = user@orgA.com
$useremailorgB = user@orgB.com
$usernameorgB = useraccountname
Disable the forwarder in OrgB:
get-mailbox where {$_.PrimarySmtpAddress -eq $useremailorgb} set-mailbox -ForwardingAddress $disabled
Remove mail properties from the contact in OrgB:
get-contact where {$_.WindowsEmailAddress -eq $useremailorgA} disable-mailcontact
Assign SOURCE email address to proxy addresses to mailbox in OrgB:
$mailboxes = Get-Mailbox where {$_.PrimarySmtpAddress -eq $useremailorgb}
foreach ($mailbox in $mailboxes)
{
$newaddress = $mailbox.samAccountname + "@secondaddress.contoso.com"
$mailbox.EmailAddresses += $newaddress
Set-Mailbox -Identity $mailbox.alias -EmailAddresses $mailbox.EmailAddresses
}
Note: ADModify would probably work just as well here.
Enable the forwarder in OrgA
get-mailbox where {$_.PrimarySmtpAddress -eq $useremailorgb} set-mailbox -ForwardingAddress ghunt@uniqueaddress.com
I am up to here, because forwarding to an address in the other org will not be possible unless we first remove the target.com.au address from the orgA user.........TBC!!!