How to safely decommission spare Exchange 2016 Server from organization.

There are many occasion when an exchange admin needs to decommission an un-used Exchange server from organization that might be installed by mistake and doesn’t full fill business requirement. There are lots of blogs or link present on internet that may guide you to do via ADSI Edit but the preferred way is to do gracefully using front end (exchange PowerShell OR GUI). Following PS script is verified in Exchange 2016 test environment for the same purpose.

$Exch2k16="exmbx2" #Exchange Server name that needs to be removed. 
$DestDb="Mailbox Database 1529611009" #Destination mailbox Database where the mailboxes of server will be moved. 
Get-MoveRequest|Remove-MoveRequest -Confirm:$False #Delete move mailbox request if exists
Get-Mailbox -Server $Exch2k16 |New-MoveRequest -TargetDatabase $DestDb #Move mailboxes to other database. 
Get-Mailbox -AuditLog -Server $Exch2k16 |New-MoveRequest -TargetDatabase $DestDb  #Move Auditing mailbox
Get-Mailbox -Monitoring -Server $Exch2k16 |New-MoveRequest -TargetDatabase $DestDb #Move health/monitoring db
Get-Mailbox -Archive -Server $Exch2k16 |New-MoveRequest -TargetDatabase $DestDb #Move all archives
Get-Mailbox -PublicFolder -Server $Exch2k16 |New-MoveRequest -TargetDatabase $DestDb #Move Publicfolder mailboxes
Get-MailboxDatabase -Server $Exch2k16 |Remove-MailboxDatabase -Confirm:$False #Remove MailboxDB
Get-ReceiveConnector -Server $Exch2k16|Remove-ReceiveConnector -Confirm:$False #Remove Receive connector.  

Now uninstall exchange binaries using following command.

setup /m:uninstall

ExchangeUn.jpg

 

Advertisements

#exchange, #movemailbox

How to create windows Network Load Balance (NLB) for Microsoft Exchange.

What is NLB?

NLB configuration is intended for application with relatively small data sets that does not change frequently such as Web, FTP, VPN to provide high availability, high scalability of client request.

For Exchange services, Load balancing helps distribute incoming client connections over a variety of endpoints to ensure that no one endpoint takes on a disproportional share of the load. Load balancing can also provide fail-over redundancy in case one or more endpoints fails. By using load balancing with Exchange Server 2013, you ensure that your users continue to receive Exchange service in case of a computer failure. Load balancing also enables your deployment to handle more traffic than one server can process while offering a single host name for your clients.

Configuration Steps:-

In my test environment, I have two CAS servers on Windows 2012 R2 using Virtualized environment.

EX2013-CAS2.LAB.LOCAL

EX2013-CAS3.LAB.LOCAL

Install ‘Network Load Balance’ feature from ‘Add roles and Features wizard’.

1-add-remove-feature

2-add-remove-feature.jpg

 

NIC card properties on first CAS (EX2013-CAS2.LAB.LOCAL)

2-nic

 

NIC card properties on second CAS (EX2013-CAS3.LAB.LOCAL)

4-NIC.jpg

 

Change NIC ordering. Production NIC should be at top in both the servers.

5-nic

 

Open Network Load Balancing console and click on ‘New Cluster’.

6-nlb

7-nlb

 

Select NLB network interface and click on ‘Next’.

8-NLB.jpg

 

By default, only one default IP will use. If you wish then add multiple IP.

9-nlb

 

Now click ‘Add’ give IP address of cluster where will be used by client request.

10-NLB.jpg11-nlb

 

Give the full internet name of cluster OR CAS endpoint, in my example it will be ‘mail.lab.local’. select ‘Unicast’ cluster operation mode.

12-nlb

 

Let the default option as it is and click on ‘Finish’.

13-nlb

 

You may see spinning hour glass and the configuration will log at the bottom of the page. Double click on line in case of error during configuration to get detailed error message.

14-NLB.jpg

 

Once the wizard completes successfully, server will be shown in green color.

15-NLB.jpg

 

Now add second CAS server into NLB cluster, the step will most likely be the same.

16-NLB.jpg

 

A successful NLB configuration will show both node (CAS) in green status.

17-nlb

 

Now create a host record in DNS server pointing to IP address of NLB cluster.

dns

You will notice now, the MAC address of NLB NIC on both NIC is same.

20-mac

 

On Exchange shell, run following power shell to force client to use ‘mail.lab.local’.

Get-OutlookAnywhere | Set-OutlookAnywhere -InternalHostname mail.lab.local -InternalClientsRequireSsl $false

You can verify if cluster is reachable using ping command on IP address OR hostname.

IPaddress.jpg

 

Another way to confirm by opening OWA page using cluster name.

18nlb

Additional consideration if you are using virtualized environment.

Go to NLB Manager \ Cluster Properties \ Clusters Parameters Tab and write down the Network address for the NLB cluster.

Shut down the NLB cluster VMs one by one (make sure you don’t shutdown both CAS at a time) then configure the network adapters in ESX/VMware/HyperV that you added to the VMs for the NLB cluster to use a static MAC address that matches the NLB network address: 02-BF-0A-0A-0A-28.

 

Please note:-
All content provided on this blog is for informational purposes only. The reason for this blog is to document the things that I have learned reading blogs/books/self about Windows Server. We do not own any responsibility for the events that may happen because of using/applying the code/concepts mentioned in this blog.
If you like above content then feel free to share it with your colleague  and friends. If you wish to improve the content the feel free to comment and contact me directly.

#cas, #exchange, #high-availalablity, #nlb