Part 7 – BizTalk High Availability Server Environment –BizTalk 2010 Installation, Configuration and Clustering

Part 7 – BizTalk High Availability Server Environment –BizTalk 2010 Installation, Configuration and Clustering

So, finally we’ve reached the part in which we will actually install, configure and cluster BizTalk Server 2010. As mentioned in my previous posts; I assume you’ve followed all steps mentioned in the previous posts. Okay let’s get started!

Verify that MSDTC is configured

Before we can go ahead with the actual installation, we need to make sure that we’ve configured our MSDTC correctly. In order to do so we will need the following tool dtcping.exe, which can be downloaded here. Once you’ve downloaded dtcping, copy it over to all servers involved, in my case that would be

  • SQL001
  • SQL002
  • BTS001
  • BTS002

Time Saver Tip: Locally install dtcping.exe (it’s actually an self-extracting archive) and copy only the dtcping.exe application to your servers

Next we will start pinging all servers, and we will do this using the following matrix

Main Server Partner DTC Server
BTS001 SQL001 Ensure that BizTalk node one is Active and SQL node one is Active
BTS001 SQL002 Ensure that BizTalk node one is Active and SQL node two is Active (perform a failover)
BTS002 SQL002 Ensure that BizTalk node two (perform a failover) is Active and SQL node one is Active
BTS002 SQL001 Ensure that BizTalk node one is Active and SQL node two is Active (perform a failover)

BTS001 vs SQL001

Logon to your main BizTalk node (in my case BTS001) and open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’

Ensure that your main BizTalk node is currently the owner

Now logon to your main SQL Server Node (in my case SQL001) and open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’

Ensure that your main BizTalk node is currently the owner Now go back to your main BizTalk Node (BTS001), and browse to the location in which you copied dtcping.exe and start it. The MSDTC Simulation screen will pop up, now enter the SQL Server Cluster Name in the box ‘Remote Server Name’, in my case that would be SQL2008.

Now go back to your main SQL Server Node (SQL001), and browse to the location in which you copied dtcping.exe and start it. The MSDTC Simulation screen will pop up, now enter the BTS Server Cluster Name in the box ‘Remote Server Name’, in my case that would be BTS2010.

Now go back to your main BizTalk Node (BTS001) and in the MSDTC Simulation windows. Click on the ‘PING’ button. Once you’ve clicked that button; ‘hurry’ over to your main SQL Server Node (SQL001) and in the MSDTC Simulation windows. Click on the ‘PING’ button. If everything goes right, you should see the following results in the MSDTC Simulation Window.

BTS001

Please refer to following log file for details:
C:UsersAdministrator.LABDownloadsBTS0013924.log
Invoking RPC method on SQL2008
RPC test is successful
++++++++++++RPC test completed+++++++++++++++
Please start PING from SQL2008 to complete the test
Please send following LOG to Microsoft for analysis:
Partner LOG: SQL0014040.log
My LOG: BTS0013924.log
++++++++++++Start Reverse Bind Test+++++++++++++
Received Bind call from SQL001
Trying Reverse Bind to SQL001
Reverse Binding success: BTS001–>SQL001
++++++++++++Reverse Bind Test ENDED++++++++++
++++++++++++Start DTC Binding Test +++++++++++++
Trying Bind to SQL001
Received reverse bind call from SQL001
Binding success: BTS001–>SQL001
++++++++++++DTC Binding Test END+++++++++++++

SQL001

++++++++++++Validating Remote Computer Name++++++++++++
Please refer to following log file for details:
C:UsersAdministrator.LABDownloadsSQL0014040.log
Please send following LOG to Microsoft for analysis:
Partner LOG: BTS0013924.log
My LOG: SQL0014040.log
Invoking RPC method on BTS2010
RPC test is successful
++++++++++++RPC test completed+++++++++++++++
++++++++++++Start DTC Binding Test +++++++++++++
Trying Bind to BTS001
Received reverse bind call from BTS001
Binding success: SQL001–>BTS001
++++++++++++DTC Binding Test END+++++++++++++
++++++++++++Start Reverse Bind Test+++++++++++++
Received Bind call from BTS001
Trying Reverse Bind to BTS001
Reverse Binding success: SQL001–>BTS001
++++++++++++Reverse Bind Test ENDED++++++++++

Please note; in case of an error.

  • Ensure that MSDTC is configured correctly! (see previous blog posts)
  • Ensure that your Firewall is turned of for your Domain Profile and Private Profile! (see previous blog posts)

Close both DTCPing applications once done.

Perform a manual Failover of the SQL Server

Logon to your main SQL Server node (in my case SQL001) and open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’ The Failover Cluster Manager windows will appear; in this window ‘right-click’ on your SQL Server Cluster Service and select ‘Move this service or application to another node’ –> ‘1 – Move to Node SQL002’

Confirm this action.

At this point you will failover your SQLCluster to your second node. Before continuing validate this, by checking the ‘Current Owner’

BTS001 vs SQL002

Now repeat the same steps as mentioned in the previous chapter BTS001 vs SQL001, the only difference now is; that you will start dtcping on your second SQL node (SQL002).

Perform a manual Failover of the BizTalk Server

Logon to your main BizTalk Server node (in my case BTS001) and open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’ The Failover Cluster Manager windows will appear; in this window ‘right-click’ on your BizTalk Server Cluster Service and select ‘Move this service or application to another node’ –> ‘1 – Move to Node BTS002’

Confirm this action.

At this point you will failover your BizTalk Cluster to your second node. Before continuing validate this, by checking the ‘Current Owner’

BTS002 vs SQL002

Now repeat the same steps as mentioned in the previous chapter BTS001 vs SQL001, the only difference now is; that you will start dtcping on your second BizTalk node, and your second SQL node (SQL002).

Perform a manual Failover of the SQL Server.

Logon to your main SQL Server node (in my case SQL001) and open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’ The Failover Cluster Manager windows will appear; in this window ‘right-click’ on your SQL Server Cluster Service and select ‘Move this service or application to another node’ –> ‘1 – Move to Node SQL001’. Confirm this change and validate that the SQL001 node is once again the ‘Current Owner’

BTS002 vs SQL001

Now repeat the same steps as mentioned in the previous chapter BTS001 vs SQL001, the only difference now is; that you will start dtcping on your second BizTalk node, and your main SQL node (SQL001).

Perform a manual Failover of the BizTalk Server

Logon to your main BizTalk Server node (in my case BTS001) and open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’ The Failover Cluster Manager windows will appear; in this window ‘right-click’ on your BizTalk Server Cluster Service and select ‘Move this service or application to another node’ –> ‘1 – Move to Node BTS001’. Confirm this change and validate that the BTS001 node is once again the ‘Current Owner’

Almost there!

Congratulations, at this point we have validated our MSDTC configuration and now we are almost ready for the actual BizTalk Installation.

Installing BizTalk

The steps mentioned below, need to be performed on both BizTalk servers, in my case BTS001 and BTS002

Time Saver Tip: You can install both servers simultaneously. However note that this can not be done when we are configuring BizTalk.

Prerequisites

Well before we can proceed with the installation we need to install 2 more pre-requisites if we want to install BAM and EDI functionality on our BizTalk servers as well. These prerequisites are:

  • Microsoft SQL Server Data Transformation Services (DTS 2008) with SP1 or higher
  • Microsoft Office Excel 2010

Installing Microsoft Office Excel 2010

Make sure that you’ve mounted your BizTalk Server 2010 Installation ISO file, this can be easily done from within the Hyper-V Manager. Simply ‘Right-Click’ on the BizTalk server in question and select ‘Settings’ Go to ‘IDE Controller 1’ and mount your media (see screenshot below)

Once you’ve mounted the Microsoft Office 2010 DVD, run the installer. On the ‘Choose the installation you want screen’ select ‘Customize’ Now only install Microsoft Excel, you’re screen should look similar to the following screenshot:

Once done select ‘Install Now’ and finally ‘Close’ the installation.

and select ‘New Installation or add features to an existing installation’

Installing Microsoft SQL Server Data Transformation Services (DTS 2008)

Well we’re almost done, but we need to install ‘Microsoft SQL Server Data Transformation Services (DTS 2008) with SP1 or higher, if we want to configure and use BAM functionality. So let’s do this now.

Make sure that you’ve mounted your BizTalk Server 2010 Installation ISO file, this can be easily done from within the Hyper-V Manager. Simply ‘Right-Click’ on the BizTalk server in question and select ‘Settings’
Go to ‘IDE Controller 1’ and mount your media (see screenshot below)

Once you’ve mounted the SQL Server 2008 R2 DVD, run the installer and select ‘New Installation or add features to an existing installation’

Follow the onscreen instructions. Once you reach the ‘Setup Role’ screen select ‘SQL Server Feature Installation’. Once done select ‘Next’

On the ‘Feature Selection’ screen ensure to check the following features

  • Client Tools Connectivity
  • Management Tools – Basic
  • Management Tools – Complete

Click ‘next’ and follow the onscreen instructions.

BizTalk 2010

Now logon to one of the servers on which you want to install BizTalk, in my case I will start off with BTS001.

Make sure that you’ve mounted your BizTalk Server 2010 Installation ISO file, this can be easily done from within the Hyper-V Manager. Simply ‘Right-Click’ on the BizTalk server in question and select ‘Settings’ Go to ‘IDE Controller 1’ and mount your media (see screenshot below)
(Repeat these steps for your second BizTalk Server)

Start the installation, by running ‘Setup.exe’ from the BizTalk Installation DVD. An installation screen will appear, in this screen select ‘Install Microsoft BizTalk Server 2010’.

On the Customer Information Screen, enter the required information and press ‘next’

Accept the License agreement and press ‘Next’

Choose whether you want to participate in the ‘Customer Experience Improvement Program’ and press ‘Next’

On the ‘Component Installation’ screen, check all items you can and press ‘Next’

I was able to check all with exception of; Developer Tools and SDK, MQSeries Agent, Windows Sharepoint Services Adapter as I did not install the pre-requisites for them.

On the ‘Redistributable Prerequisites’ screen, select your preferred option. I’ve selected ‘Automatically install the redistributable prerequisites from a CAB file’ which I downloaded previously (click here) and press ‘Next’

On the ‘Summary Screen’ press ‘Install’

Installation will now start, during the installation you will be prompted for ‘Updates’, choose the preferred option and press ‘next’

Click finish to Quit the installation and ensure that the option ‘Launch BizTalk Server Configuration’ is not checked.

Installing Microsoft BizTalk Adapters

The steps mentioned below, need to be performed on both BizTalk servers, in my case BTS001 and BTS002 Continue the installation, by running ‘Setup.exe’ from the BizTalk Installation DVD. An installation screen will appear, in this screen select ‘Install Microsoft BizTalk Adapters’.

A new window will appear, select ‘Step 1: Install Microsoft WCF Lob Adapter SDK’ and follow the onscreen instructions.

When you reach the ‘Choose Setup Type’ screen, select ‘Complete’

Click on ‘Install’

Installation will now start, during the installation you will be prompted for ‘Updates’, choose the preferred option and press ‘Ok’

Click ‘Finish’

On the ‘Adapter Installation Window’, note the warning which can be ignored and select ‘Step 2: Install Microsoft BizTalk Adapter Pack’

Follow the onscreen instruction and once you reach the ‘Choose Setup Type’ screen, select ‘Complete’ .

Click on ‘Install’

Installation will now start, during the installation you will be prompted for ‘Updates’, choose the preferred option and press ‘Ok’

Another window will pop up, asking if you want to join ‘The Customer Experience Improvement Program’; select either option and press ‘ok’

Click on ‘Finish’

On the ‘Adapter Installation Window’, select ‘Step 3: Install Microsoft BizTalk Adapter Pack (x64)’ and follow the onscreen instructions. I will not list them again as they are similar to the previous instructions.

On the ‘Adapter Installation Window’, select ‘Step 4: Install Microsoft BizTalk Adapters for Enterprise Applications’ and follow the onscreen instructions. I will not list them again as they are similar to the previous instructions.(when asked for the Setup type; select ‘Complete’

During the installation of step 4, you might get a few warnings, indicating that an adapter was already installed. Just press ‘Ok’ and continue. At this point you installed all adapters, so press ‘Exit’

Note: We will not install the ‘Microsoft AppFabric Connect’ feature; in a later blog post however I might get back to this Before we can proceed with configuring BizTalk Server, we need to epeat the above mentioned steps on your other BizTalk Server node (my case BTS002)

Configuring BizTalk on the Main Node

Once you’ve installed BizTalk on both servers. Logon to your main BizTalk Node, and click on ‘Start’ –> ‘All Programs’ –> ‘Microsoft BizTalk Server 2010’ –> ‘BizTalk Server Configuration’

On the ‘Microsoft BizTalk Server 2010 Configuration’ screen, select ‘Custom Configuration’, fill out

  • The Database server name (point it to your SQL Cluster!), in my case ‘SQL2008BIZTALK2010’
  • Enter the username and password for the BizTalk Untrusted Service, in my case ‘LABsrvc-bts-untrusted’

Once done, press Configure.

Enterprise SSO Configuration

At this point the main configuration screen will appear. Select ‘Enterprise SSO’

Select ‘Enable Enterprise Single Sign-On on this computer’ and select ‘Create a new SSO System’

Now, add the correct Service Accounts and Windows Accounts; in my case:

  • Enterprise Single Sign-On Service Account: LABsrvc-bts-sso
  • SSO Administrator(s) group: LABSSO Administrators
  • SSO Affiliate Administrator(s)

Note the warning: Ignore this warning, as it is most likely a ‘refreshing issue’ as it states that I am using a local SSO Administrator group, which I am not

Select ‘Enterprise Single Sign-On Secret Backup’

Enter the details and store the backup file on a Secure Place. I’ve used the Clustered Disk named’ ‘Data_Store’

Now Click on ‘Apply Configuration’

Verify the settings on the ‘Summary Screen’ and press ‘Next’

Click Finish

Group Configuration

Select ‘Group’

Check ‘Enable BizTalk Server Group on this Computer’ and select ‘Create a new BizTalk Group’

Now, add the correct BizTalk Administrative Roles; in my case:

  • BizTalk Administrators Group: LABBizTalk Server Administrators
  • BizTalk Operators Group: LABBizTalk Server Operators
  • BizTalk B2B Operators Group: LABBizTalk Server B2B Operators

Now Click on ‘Apply Configuration’

Verify the settings on the ‘Summary Screen’ and press ‘Next’

Click Finish

BizTalk Runtime Configuration

Select ‘BizTalk Runtime’

Check ‘Register the BizTalk Server runtime components’

Check ‘Create In-Process Host and Instance’.

For Host Name enter: Processing_Host

Check ‘Create Isolated Host and Instance’ and check ‘Trusted’ right below it

For Isolated Host name enter: Isolated_Host

Ensure that both 32-bit only checkboxes are checked

Now, assign the correct Windows Services and Groups ; in my case:

  • BizTalk Host Instance Account: LABsrvc-bts-untrusted
  • Biztalk Isolated Host Instance Account: LABsrvc-bts-trusted
  • Biztalk Host Users Group: LABBizTalk Applications Users
  • Biztalk Isolated Host Users Group: LABBizTalk Isolated Host Users

Now Click on ‘Apply Configuration’

Verify the settings on the ‘Summary Screen’ and press ‘Next’

Click Finish

Business Rules Engine Configuration

Select ‘Business Rules Engine’

Check ‘Enable Business Rules Engine on this computer’

Now, add the correct Windows Service; in my case:

  • Rule Engine Update Service : LABsrvc-bts-rule-engine

Now Click on ‘Apply Configuration’

Verify the settings on the ‘Summary Screen’ and press ‘Next’

Click Finish

BAM Tools Configuration

Select ‘Bam Tools’

Check ‘Enable Business Activity Monitoring tools’

Now, add the correct ‘Server Name (SQL Cluster); in my case: SQL2008BIZTALK2010

Now Click on ‘Apply Configuration’

Verify the settings on the ‘Summary Screen’ and press ‘Next’

Click Finish

BAM Alerts Configuration

We will skip these for now.

In a future post I might come back to these and configure it. However in case you need it installation is quite straight forward, you only need to make sure to install the pre-requisites

BAM Portal Configuration

Select ‘Bam Portal’

Check ‘Enable BAM Portal’

Now, add the correct Windows Service Accounts ; in my case:

  • BAM Management Web Service user: LABsrvc-bts-bam
  • BAM Application Pool Account: LABsrvc-bts-bam-ap

Next add the correct Windows Group; in my case:

BAM Portal Users: LABDomain Users

Finally select the BAM Portal Web site, in my case

Bam Portal Web Site: Default Web Site

Now Click on ‘Apply Configuration’

Verify the settings on the ‘Summary Screen’ and press ‘Next’

Click Finish

BizTalk EDI/AS2 Runtime Configuration

Select ‘BizTalk EDI/AS2 Runtime’

Check all options.

Now Click on ‘Apply Configuration’

Verify the settings on the ‘Summary Screen’ and press ‘Next’

Click Finish

Export the configuration

Now click on Export Configuration

Save it the file (I’ve saved it on a cluster disk)

Configuring BizTalk on the Second Node

Before we start with configuring BizTalk on the Second Node, we will first perform a failover of the BizTalk Cluster such that all resources are available to our second node. Logon to your second BizTalk Node (in my case BTS002) and open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’

Ensure that the main BizTalk node (BTS001) is the current owner

Now fail this cluster over, so that the second node becomes the owner. ‘Right-click’ on your BizTalk Server Cluster Service and select ‘Move this service or application to another node’ –> ‘1 – Move to Node BTS002’

Confirm this action

Verify once all resources are back online that current owner is the Second BizTalk Node (BTS002).

Now click click on ‘Start’ –> ‘All Programs’ –> ‘Microsoft BizTalk Server 2010’ –> ‘BizTalk Server Configuration’

On the ‘Microsoft BizTalk Server 2010 Configuration’ screen, select ‘Custom Configuration’, fill out

  • The Database server name (point it to your SQL Cluster!), in my case ‘SQL2008BIZTALK2010’
  • Enter the username and password for the BizTalk Untrusted Service, in my case ‘LABsrvc-bts-untrusted’

Once done, press Configure.

Enterprise SSO Configuration

At this point the main configuration screen will appear. Select ‘Enterprise SSO’

Select ‘Enable Enterprise Single Sign-On on this computer’ and select ‘Join an existing SSO system’

 

Now, verify that the configurations are correct (should point to the same database as mentioned in the previous chapter) and add the correct Service Accounts; in my case:

  • Enterprise Single Sign-On Service Account: LABsrvc-bts-sso

Now Click on ‘Apply Configuration’, verify the settings on the ‘Summary Screen’ ,press ‘Next’ followed by ‘Finish’

Group Configuration

Select ‘Group’

Check ‘Enable BizTalk Server Group on this Computer’ and select ‘Join an existing BizTalk Group’ and verify that the configurations are correct (should point to the same databases as mentioned in the previous chapter)

Now Click on ‘Apply Configuration’, verify the settings on the ‘Summary Screen’ ,press ‘Next’ followed by ‘Finish’

BizTalk Runtime Configuration

Select ‘BizTalk Runtime’

Check ‘Register the BizTalk Server runtime components’

Check ‘Create In-Process Host and Instance’.

For Host Name enter: Processing_Host (ignore warning)

Check ‘Create Isolated Host and Instance’ and check ‘Trusted’ right below it

For Isolated Host name enter: Isolated_Host (Ignore the warning)

Ensure that both 32-bit only checkboxes are checked

Now, assign the correct Windows Services and Groups ; in my case:

  • BizTalk Host Instance Account: LABsrvc-bts-untrusted
  • Biztalk Isolated Host Instance Account: LABsrvc-bts-trusted
  • Biztalk Host Users Group: LABBizTalk Applications Users
  • Biztalk Isolated Host Users Group: LABBizTalk Isolated Host Users

Now Click on ‘Apply Configuration’, Verify the settings on the ‘Summary Screen’ ,press ‘Next’ and end with ‘Finish’

Business Rules Engine Configuration

Select ‘Business Rules Engine’

Check ‘Enable Business Rules Engine on this computer’ and verify that the configurations are correct (should point to the same databases and should use the correct account as mentioned in the previous chapter)

Now Click on ‘Apply Configuration’. Verify the settings on the ‘Summary Screen’ ,press ‘Next’ and end with ‘Finish’

BAM Tools Configuration

Select ‘Bam Tools’

Check ‘Enable Business Activity Monitoring tools’ and verify that the configurations are correct (should point to the same databases as mentioned in the previous chapter)

Now Click on ‘Apply Configuration’. Verify the settings on the ‘Summary Screen’ ,press ‘Next’ and end with ‘Finish’

BAM Alerts Configuration

We will skip these for now.

In a future post I might come back to these and configure it. However in case you need it installation is quite straight forward, you only need to make sure to install the pre-requisites

BAM Portal Configuration

Select ‘Bam Portal’

Check ‘Enable BAM Portal’

Now Click on ‘Apply Configuration’. Verify the settings on the ‘Summary Screen’ ,press ‘Next’ and end with ‘Finish’

BizTalk EDI/AS2 Runtime Configuration

Select ‘BizTalk EDI/AS2 Runtime’

Check ‘Enable BizTalk EDI/AS2 Runtime on this computer; (other options are greyed out).

Now Click on ‘Apply Configuration’. Verify the settings on the ‘Summary Screen’ ,press ‘Next’ and end with ‘Finish’

Export the configuration

Now click on Export Configuration

Save it the file (I’ve saved it on a cluster disk)

Failover Back to your main BizTalk Node

Open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’

Ensure that the main BizTalk node (BTS002) is the current owner

Now fail this cluster over, so that the second node becomes the owner. ‘Right-click’ on your BizTalk Server Cluster Service and select ‘Move this service or application to another node’ –> ‘1 – Move to Node BTS001’

Confirm this action

Verify once all resources are back online that current owner is the Main BizTalk Node (BTS001).

Setting Up BizTalk

We’ll now that we’ve installed and configured BizTalk it’s time to finish up our BizTalk Cluster.

Clustering our Single Sign On Service

Ensure you’re logged on to the BizTalk Server node which is currently the owner; in my case this is BTS002. Once logged open up one of the best editors in the world called notepad. In notepad copy and paste the following code

<sso>
  <globalInfo>
     <secretServer>SSOCLUSTER</secretServer>
  </globalInfo>
</sso>

change the SSOCLUSTER value in the <secretServer> xml-tag to the name of your BizTalk Server Cluster. In my case this would be ‘BTS2010’

Save this file to disk (I saved it to c:tmp) and name it ‘SSO_Secret_Server.xml’

Once stored open up a command prompt do this by going to start and typing ‘CMD’ into the search box followed by hitting ‘Enter’

A command prompt box will open; At this command prompt, change to the Enterprise SSO installation folder. In my case I typed “c:Program FilesCommon FilesEnterprise Single Sign-On”

Now enter the following command ‘ssomanage –updatedb <SSO_Secret_Server.xml location> (my case ssomanage –updatedb “c:tmpSSO_Secret_Server.xml”) hit ‘enter’ and once done close the window.

Open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’

In the ‘Failover Cluster Manager’ right click on your BizTalk Cluster Service (in my case BTS2010) and select ‘Add a resource’ –> ‘4 – Generic Service’

On the ‘Select Service window’, select ‘Enterprise Single Sign On Service’ and press ‘Next’

On the ‘Confirmation’ screen press ‘Next’

On the ‘Summary’ screen press ‘Finish’

Now in the main pane; you will see that the ‘Enterprise Single Sign-On Service’ is added as a resource.

Right click on it and select ‘properties’

On the ‘General’ Tab; ensure to check ‘Use Network Name for computer name’

Confirm this action by click ‘Yes’

Click on ‘Ok’ on the ‘Information Screen’

Go to the ‘Dependencies’ Tab, add the following depended resources and once done press ‘apply’

  • name (in my case BTS2010)
  • dtc resource (in my case MSDTC-BTS2010)

Now start the SSO resource by right-clicking on it and selecting ‘Bring this resource online’

Once this resource is online, right click on the BizTalk Cluster Service and select ‘Move this service or application to another node’ –> ‘1 – Move to node BTS002’

Confirm the action

Now log on to the BizTalk node you just failed over to (in my base BTS002). On that server open a command prompt do this by going to start and typing ‘CMD’ into the search box followed by hitting ‘Enter’

A command prompt box will open; At this command prompt, change to the Enterprise SSO installation folder. In my case I typed “c:Program FilesCommon FilesEnterprise Single Sign-On”

Now enter the following command ‘ssoconfig –restoresecret <RestoreFile (Backup of your SSO Secret you saved earlier)> (my case ssoconfig –restoresecret “f:SSO SecretSSO7884.bak”)

Hit enter,and enter the Secret Password and hit enter

You should see the following message

In case you receive an adapter, ensure that you followed all steps as mentioned above!

Modify the BizTalk Application Configuration

In order to optimize the throughput with regards to HTTP based send ports, we need to add a configuration section to both our BTSNTSvc.exe.config and BTSNTSvc64.exe.config files which can be found in the installation directory if BizTalk. (in my case “C:Program Files (x86)Microsoft BizTalk Server 2010”) So open-up windows explorer and browse to your BizTalk installation directory and upon BTSNTSvc.exe.config by right clicking it and selecting ‘open with…’ –> ‘notepad’ (if notepad is not visible, select ‘Choose default program… and select then notepad’)

Now add the following code section just above the </configuration> closing tag and save the file.

<system.net>
    <connectionManagement>
      <add address="*" maxconnection="25" />
    </connectionManagement>
</system.net>

Once done, your file should look something like this:

One of the standard settings which come with a BizTalk Installation is the setting which indicated the maximum connections allowed for HTTP based send adapters. This setting is by default set to Now repeat this step for the BTSNTSvc64.exe.config Once done, log on to your other BizTalk server and repeat the above mentioned steps.

Adding BizTalk Hosts

At this point we are ready to finally open up the BizTalk Administrator and finish our BizTalk Cluster So let’s get Started. First of all log on to your active BizTalk Node and open the BizTalk Administrator Console. You can find it by going to ‘Start’ –> ‘All Programs’ –> ‘Microsoft BizTalk Server 2010’ and clicking on ‘BizTalk Server Administrator’

In the BizTalk Server Administration Console, expand the ‘BizTalk Server Node’, expand ‘BizTalk Group’, expand ‘Platform Settings’ and select ‘Hosts’

In the main pane, you should now see two Hosts (these hosts have been created while we configured BizTalk earlier on).

We now will add a few more hosts, beings

  • Send_Host
  • Receive_Host
  • Tracking_Host
  • Legacy_Host
  • x64_Host

Adding a new host is quite simple; just right-click on the main pane and select ‘New’ –> ‘Host’

On the Host Properties screen, change/add the following properties. Once done click on ‘Ok

Name: Send_Host Type: In_Process Options: 32-bit only Track Windows group: <add your BizTalk Application Users Group>

On the Host Properties screen, change/add the following properties. Once done click on ‘Apply’

Name: Receive_Host Type: In_Process Options: 32-bit only Windows group: <add your BizTalk Application Users Group>

On the Host Properties screen, change/add the following properties. Once done click on ‘Ok’

Name: Tracking_Host Type: In_Process Options: 32-bit only and Check Allow Host Tracking Windows group: <add your BizTalk Application Users Group>

On the Host Properties screen, change/add the following properties. Once done click on ‘Ok’

Name: Legacy_Host Type: In_Process Options: 32-bit only Windows group: <add your BizTalk Application Users Group>

On the Host Properties screen, change/add the following properties. Once done click on ‘Ok’

Name: x64_Host Type: In_Process Options: 32-bit only DO NOT CHECK! Windows group: <add your BizTalk Application Users Group>

Now double click on the ‘Processing Host’ and remove the check in front of ‘Allow Host Tracking’ and click ok.

A warning pops up indicating that a restart is required of the associated host instances, press ‘Ok’.

Adding BizTalk Host-Instances

First of all log on to your active BizTalk Node and open the BizTalk Administrator Console. You can find it by going to ‘Start’ –> ‘All Programs’ –> ‘Microsoft BizTalk Server 2010’ and clicking on ‘BizTalk Server Administrator’

In the BizTalk Server Administration Console, expand the ‘BizTalk Server Node’, expand ‘BizTalk Group’, expand ‘Platform Settings’ and select ‘Host Instances’

You should see, four host-instances; and you should notice that we have 2 exactly the same host instances on both BizTalk Server instances.

Adding a new host instance is quite simple; just right-click on the main pane and select ‘New’ –> ‘Host Instance’

On the Host Instance Properties screen, select the following:

Host Name: Legacy_Host Server: BTS001  

Now click on ‘Configure’

On the ‘Logon Credentials’ screens enter the details of the windows service account you want this host instance to execute with (the Untrusted BizTalk Service Account in AD), in my case this will be LABsrcv-bts-untrusted. Once done press ‘OK’ and once more ‘OK’

Now repeat the above steps, but this time on the ‘Host Instance Properties’ screen select ‘BTS002’ for the server propery

Note: Don’t forgot to hit configure and enter the service credentials

Repeat the above mentioned steps for the remaining other hosts, being:

  • Tracking_Host
  • Send_Host
  • Receive_Host
  • x64_Host

Once done, your main pane should look similar to the image below

Adding the correct Host Instances to the Adapters

First of all log on to your active BizTalk Node and open the BizTalk Administrator Console. You can find it by going to ‘Start’ –> ‘All Programs’ –> ‘Microsoft BizTalk Server 2010’ and clicking on ‘BizTalk Server Administrator’

In the BizTalk Server Administration Console, expand the ‘BizTalk Server Node’, expand ‘BizTalk Group’, expand ‘Platform Settings’ and expand the ‘Adapters’ node

Click on the ‘File’ Adapter, and then right-click in the main-pane and select ‘New’ –> ‘Send Handler’

On the ‘File – Adapter Handler Properties’ For Host name select Send_Host and ensure to check ‘Make this the default Handler’. Once done press ‘Ok’

A warning will pop-up, just read it and click “ok”

Right-click in the main-pane once more and select ‘New’ –> ‘Receive Handler’

On the ‘File – Adapter Handler Properties’ For Host name select ‘Recieve_Host’. Once done press ‘Ok’

A warning will pop-up, just read it and click “ok”

In the main-pane right click on ‘Processing_Host’ for the direction ‘Send’ and select ‘Delete’

Confirm the ‘Deletion’ by selecting ‘Yes’

Note the ‘warning’ and press ‘Ok’

In the main-pane right click on ‘Processing_Host’ for the direction ‘Receive’ and select ‘Delete’

Confirm the ‘Deletion’ by selecting ‘Yes’

Note the ‘warning’ and press ‘Ok’

Now repeat the above steps for the following adapters, but note the host_names as listed below

Adapter Send Host Name Receive Host Name Remarks
FTP Legacy_Host (make default) Legacy_Host Delete Processing_Host entries
HTTP Send_Host (make default) No change Delete Processing_Host entries
MQSeries Send_Host (make default) Receive_Host Delete Processing_Host entries
MSMQ Send_Host (make default) Receive_Host Delete Processing_Host entries
POP3 Not Applicable Legacy_Host Delete Processing_Host entries
SMTP Legacy_Host (make default) Not Applicable Delete Processing_Host entries
SOAP Legacy_Host (make default) No Change Delete Processing_Host entries
SQL Can’t delete Receive Processing_Host entries as they are used (see note below)
WCF-BasicHTTP Send_Host (make default) No Change Delete Processing_Host entries
WCF-Custom Send_Host (make default) Receive_Host Delete Processing_Host entries
WCF-CustomIsolated Not Applicable No Change
WCF-NetMsmq Send_Host (make default) Receive_Host Delete Processing_Host entries
WCF-NetNamedPipe Send_Host (make default) Receive_Host Delete Processing_Host entries
WCF-NetTcp Send_Host (make default) Receive_Host Delete Processing_Host entries
WCF-WSHttp Send_Host (make default) No Change Delete Processing_Host entries
Windows SharePoint Services Send_Host (make default) No Change Delete Processing_Host entries

Note: In order to delete the Receive Processing_Host, we first need to change the binding of the receive locations of the ‘Biztalk EDI Application’, in order to do so. Click on ‘Applications’ –> <All Artifacts>’ –> and select ‘Receive Locations’.

Perform the following actions for all receive locations visible in the main pane Double click receive-location and change the Receive handler to: Receive_Host and click ‘Ok’

Now go back to the SQL Adapter and delete the ‘Processing Host’

Clustering BizTalk Server Hosts

At this point we are almost done with our tasks in the BizTalk Server Administration Console. The one thing which we now need to do is actually cluster the hosts. In the BizTalk Administration Console, click on the Hosts node

Perform the following actions for all hosts, with exception of the Isolated_Host Right Click on a host and select ‘Cluster’

Select the Cluster Resource Group to use, in my case ‘BTS2010’

Select ‘Ok’ Once you’re done; you should see the that the ‘Clustered’ Column says yes for all hosts except for the ‘Isolated Host’ as out Isolated Host can not be clustered (but we’ve taken care of this in a previous step when we’ve clustered IIS )

At this point we are almost done, we only need to verify everything in our Cluster Failover Manager and add some dependencies.

Verifying our BizTalk Cluster Resources and adding dependencies

At this point we are almost done, we only need to verify everything in our Cluster Failover Manager and some dependencies to the just clustered hosts Open the ‘Failover Cluster Manager’ do this by going to start and in the search box type ‘Failover Cluster Manager’ then hit ‘enter’

In the Failover Cluster Manager, select your BizTalk Cluster Service and notice all the BTSSvc$…. resources added

Well, for all these resources we will add a few dependencies. So let’s get started. ‘Right Click’ on the first BTSSvc$… resource and select ‘properties’

On the properties screen select the ‘Dependencies’ Tab and add the following dependencies and once done click ‘Ok’

  • MSDTC (in my case ‘MSDTC-BTS2010’)
  • Enterprise Single Sign-On Service

Repeat the above mentioned step, for all other BTSSvc$… resources.

Closing note

Congratulations, at this point you’ve created a complete BizTalk High Availability Environment. Well it took some time and effort, but hey you accomplished it 🙂 and that at least deserves a congratulation. So what’s up next you might be wondering, well most likely I won’t be posting a new article pretty soon as I am currently involved in reviewing one of the upcoming BizTalk 2010 books and this takes up more time than I initially expected 🙂 But hey, isn’t that with all the things we ‘developers’ do 😉 Anyway, if you have any suggestions on future article with regards to BizTalk, Programming in general or anything else; well just drop me a note [email protected] or try to contact me on Twitter (ReneBrauwers). Well it has been a pleasure and it took me quite some time (avg 10hrs per post) to put all these posts together so I really hope that one of these posts or all have or can help you in anyway. If you have any questions or feedback please feel free to leave a comment and I’ll try to address them. So until the next time and don’t forget to check back regularly for new posts (or even better just follow me in Twitter as I’ll tweet whenever there is a new blogpost 🙂 Cheers René

Part 6: BizTalk High Availability Server Environment–BizTalk 2010 Failover Cluster Creation

Part 6: BizTalk High Availability Server Environment–BizTalk 2010 Failover Cluster Creation

Part 5 covered setting up our SQL-Server Cluster, so now it’s time to do the same but this time for our BizTalk 2010 Server environment.

Once again this post assumes you’ve followed all steps mentioned in the previous posts. All right let’s get on with it

Please note the following with regards to MSMQ: http://technet.microsoft.com/en-us/library/cc730960.aspx

In case you’ve already installed the MSMQ feature as instructed in part 4, please uninstall the MSMQ feature and then apply the AD modifications as mentioned here: http://technet.microsoft.com/en-us/library/cc730960.aspx . . Once done, add the MSMQ feature again as mentioned in part 4. Sorry for the inconvenience, but this part was unintended left out in the original part 4 (The current version of Part 4 has been updated)

Preparing our BizTalk Cluster

Before we can actually start with Clustering BizTalk Server, we need to perform all kinds of other things, like:

  • Verifying if all required Roles and Features have been installed
  • Verifying that we’ve configured the Firewall properly
  • Configure IIS
  • Configure the local Microsoft Distributed Transaction Coordinator
  • Add Storage using iSCSI

Once these steps are done, we will create our BizTalk Cluster Group.

Verifying the required Server Roles and Features

Logon to your first server on which BizTalk will be installed, in my case that would be BTS001. Once logged on; open the ‘server manager’ and expand the Roles node and ensure you’ve added the following roles:

  • Application Server
  • Web Server (IIS)

Now select ‘Application Server’ and in the main pane in the Server Manager scroll down to the Role Services. In total you should see that 13 role services are installed.

if you’re missing any of the role-services mentioned above, add them by clicking on the ‘Add Role Services’

Once double-checked, select the ‘Web Server (IIS) role and in the main pane in the Server Manager scroll down to the Role Services. In total you should see that 36 role services are installed

if you’re missing any of the role-services mentioned above, add them by clicking on the ‘Add Role Services’

Once verified, expand the Features node in the Server Manager and select ‘features’. Ensure that you have the features as mentioned below in the image installed.

if you’re missing any of the features as mentioned above, add them by clicking on the ‘Add Features’

Verifying that we’ve configured the Firewall properly

Open up the windows firewall, by going to Start and in the search box simple type: ‘Windows Firewall with Advanced Security’ followed by hitting ‘enter’

Within the MMC-Snap in, click on ‘Windows Firewall Properties’

A window will appear. Go to the first tab named ‘Domain Profile’ and ensure the firewall state is set to ‘Off’. If not turn it ‘Off’

Go to the second tab named ‘Private Profile’ and ensure the firewall state is set to ‘Off’. If not turn it ‘Off’

Configuring IIS

Go back to the Server manager, expand Roles –> Web Server (IIS) and select the ‘Internet Information Services (IIS) Manager’

The Internet Information Services (IIS) Manager will appear in the main pain. Expand the Server Node and select Application Pools.

In the Actions pane, click on the ‘Set Application Pool Defaults…’

Change the following settings and once done click on ‘ok’:

  • Net Framework Version: v4.0 (if this version is not available; stop your horses and go fetch the .Net 4.0 Framework here)
  • Enable 32-Bit Applications: True

In the actions, select ‘Add Application Pool…’

Now we will add an application pool, which will be dedicated to BizTalk. In order to do so, enter a descriptive name (I’ve used BizTalkApplicationPool). Once done click on ‘ok’

In the main pane, right click on the newly created Application Pool and select ‘Advanced Settings’

Select the ‘Identity item’, and click on the ‘…’

Select ‘Custom Account’ and click on the ‘Set…’ button.

Fill out the details and use trusted BizTalk Service account you’ve set up earlier in Active Directory (in my case ‘[email protected]) Once done, click ‘ok’, and once more ‘ok’.

Your screen should look similar to the picture shown below. Once verified, click ‘ok’

Configure the local Microsoft Distributed Transaction Coordinator

go to start and type into the search box ‘Component Services’ and hit enter.

the Component Services MMC snap in will open; now extend the ‘Component Service’ node, do the same for the node ‘Computers’ and ‘My Computer’

Expand the ‘Distributed Transaction Coordinator’ , right click on ‘local DTC’ and select ‘properties’

Within the Properties window go the the ‘Security Tab’

On this tab, check (enable) the following item:

  • Network DTC Access
  • Allow Inbound
  • Allow Outbound
  • No Authentication Required
  • Enable XA Transactions
  • Enable SNA LU 6.2 Transactions

Click on ‘Ok, a message box will appear stating that the MSDTC service needs to be stopped and started. Click on Yes

Close the Component Services Snap in.

Add Storage which will be used within our BizTalk Cluster.

First verify that we’ve set-up our link with our Fileserver. Do this by clicking on Start and in the search box type ‘iSCSI Initiator’ and hit ‘enter’ (a pop-up might appear, just click ‘ok’)

In the ‘iSCSI Initiator Properties’ screen, go to the ‘Discovery’ tab and click on ‘Discover Portal…’

Type in the DNS name of your File Server (in my case that is ‘EUROPOORT’) and press ‘ok’

Now click on the ‘Targets’ tab and checking the status

The status should say ‘Inactive’, in order to use this Target we have to Connect to it. Do so by Clicking on the ‘Connect’ button.

A popup will appear, check the setting and press ‘ok’

You should now be connected to the File Server. Once verified, press ‘ok’

Go back to your ‘Server Manager’, expand the ‘Storage’ node and select ‘Disk Management’

At this point you should notice several disks which are not online.

If they are ‘offline’ bring them ‘online’ by right clicking on a disk and selecting ‘Online’ (repeat this step for all offline disks)

You now should have the availability of your additional storage devices.

Once done, repeat all the steps mentioned above starting with ‘Verifying the required Server Roles and Features’ on your other BizTalk server (in my case this would be BTS002)

Creating our BizTalk Cluster Group

Well at this point we are still not quite ready to install BizTalk and to Cluster BizTalk. Before we can actually start with this, we need to perform the following actions:

  • Verify our Cluster
  • Create our BizTalk Cluster group
  • Cluster IIS and add it to our BizTalk Cluster group
  • Cluster MSDTC and add it our BizTalk Cluster group
  • Cluster MSMQ and add it to our BizTalk Cluster group

Once these steps are done, we will install Biztalk, configure BizTalk and last but not least Cluster BizTalk.

Verify our Cluster

Log on to your ‘Master’ Server on which you want to install BizTalk. In my case that would be BTS001.

Go to start and in the search box type ‘Failover Cluster Manager’ and then hit ‘enter’

In your Failover Cluster Manager, first click on ‘Validate a configuration’

On the ‘Before you begin’ screen, press ‘next’

Now Enter the server names (or browse) which you want to be part of your cluster. In my case that would be ‘BTS001 and BTS002’ and then select ‘Next’

on the ‘Testing Options’ screen, select the ‘Run all tests’ option and select ‘next’

Confirm the settings and then select ‘Next’

Once the validation has completed, it should show a summary which should not include any warnings. Examine the report (View Report) click on Finish.

Create our BizTalk Cluster group

From within your ‘Failover Cluster Manager’ select the ‘Create a Cluster’ link

On the ‘Before you begin’ screen, press ‘next’

Now Enter the server names (or browse) which you want to be part of your cluster. In my case that would be ‘BTS001 and BTS002’ and then select ‘Next’

On the ‘Access Point for Administering the Cluster’ enter a Cluster name, and a designated IP Address and click ‘next’ once done.

I’ve used the following:

Cluster Name: CLUSTER_BIZTALK
IP Address: 192.168.8.32

Confirm your settings and then click ‘next’

On the ‘Summary’ screen, press ‘Finish’

Configure Cluster Quorum Settings

Open up the ‘Cluster Manager’, right click on your cluster node (my case: CLUSTER_BIZTALK ) and select ‘More Actions’ –> ‘Configure Cluster Quorum Setting’

On the ‘Select Quorum Configuration’ screen, select the option ‘Node and File Share Majority’ and press ‘Next’

On the ‘Configure File Share Witness’ screen, browse to your Shared ‘Wittness’ Folder which you’ve created earlier (see previous part). In my case I’ve selected the folder ‘Majority_BTS’ on the EUROPOORT server. Once done press ‘Ok’ and then ‘Next’

Conform the settings and press ‘next’

On the ‘Summary’ screen, press ‘Finish’

Add storage as a disk resource in your Cluster

Open up the ‘Cluster Manager’, expend the CLUSTER_BIZTALK node and right click on Storage and select ‘Add a disk’

A list of available disks will appear, ensure that they are all selected and press ‘ok’

Now for each disk add a logical name, this is done by right clicking on a disk and selecting ‘properties’

Change the Resource Name to a logical Name; I’ve set it up as follow

Cluster_Disk 1 – DTC_STORE
Cluster_Disk 2 – MSMQ_STORE
Cluster_Disk 3 – FILE_STORE

Create our BizTalk Cluster Resource

Go back to the ‘Failover Cluster Manager’ and expand your created Cluster (my case: CLUSTER_BIZTALK) and right click on ‘Services and Applications’ and select ‘Configure a Service or Application…’

On the ‘Select Service or Application’ screen, select ‘Other Server’ and then press ‘next’

On the ‘Client Access Point’ screen, fill out the actual name of your BizTalk Cluster Name and assign it an IP and once done press ‘Next’. I’ve used the following settings:

Name: BTS2010
IP: 192.168.8.33

On the ‘Select Storage’ screen, add the required DATA Stores and press ‘Next’

On the ‘Confirmation’ screen, review the settings and press ‘Next’

On the ‘Summary’ screen, press ‘Finish’

In the ‘Failover Cluster Manager’ right-click your newly created ‘BizTalk Cluster Resource’ and select ‘properties’

On the ‘Properties’ screen, ensure to Check your main server as being the ‘Preferred owner’; in my case this is BTS001. Once done click ‘ok’.

Cluster IIS and add it to our BizTalk Cluster Resource

At this point we’ve created our BizTalk Cluster Group and BizTalk Cluster Resource. The later one will actually host all services required for our BizTalk Failover Cluster.

Now it is time to add those cluster resources which are required in our BizTalk Failover Cluster.

The first cluster resource we will add to our BizTalk Cluster Group will be the IIS. As we are not using a NLB, we have to perform a few tricks which enable us at least to Cluster out to use BizTalk Web Application and our BizTalk Application Pool. The next steps will explain how to achieve this.

Adding HTTP Response Header

Go back to the Server manager, expand Roles –> Web Server (IIS) and select the ‘Internet Information Services (IIS) Manager’

The Internet Information Services (IIS) Manager will appear in the main pain. Expand the Server Node and select the ‘Server Name’ (in my case BTS001)

In the main pane, go to the IIS Section and double click on ‘HTTP Response Headers’

In the actions pane, click on ‘Add..’

The ‘Add Custom HTTP Response Header’ windows will appear. In this window we will add a custom header which will ensure that all trafic redirected to our BizTalk Cluster Group will point to the Localhost. In my case I filled out the following information. Once done press ok.

Name: BTS2010
Value: http://localhost

Now go to your second server (in my case BTS002) and perform the above mentioned step ‘Adding HTTP Response Header’. Once done; return to your main server (BTS001)

Create a Generic-Script resource for IIS Clustering

On your main server (BTS001), open your nest friend ‘Notepad’ and copy and paste the following code to it:

'<begin script sample>


'This script provides high availability for IIS websites
'By default, it monitors the "Default Web Site" and "DefaultAppPool"
'To monitor another web site, change the SITE_NAME below
'To monitor another application pool, change the APP_POOL_NAME below
'More thorough and application-specific health monitoring logic can be added to the script if needed

Option Explicit

DIM SITE_NAME
DIM APP_POOL_NAME
Dim START_WEB_SITE
Dim START_APP_POOL
Dim SITES_SECTION_NAME
Dim APPLICATION_POOLS_SECTION_NAME
Dim CONFIG_APPHOST_ROOT
Dim STOP_WEB_SITE


'Note:
'Replace this with the site and application pool you want to configure high availability for
'Make sure that the same web site and application pool in the script exist on all cluster nodes. Note that the names are case-sensitive.
SITE_NAME = "Default Web Site"
APP_POOL_NAME = "DefaultAppPool"

START_WEB_SITE = 0
START_APP_POOL = 0
STOP_WEB_SITE  = 1
SITES_SECTION_NAME = "system.applicationHost/sites"
APPLICATION_POOLS_SECTION_NAME = "system.applicationHost/applicationPools"
CONFIG_APPHOST_ROOT = "MACHINE/WEBROOT/APPHOST"

'Helper script functions


'Find the index of the website on this node
Function FindSiteIndex(collection, siteName)

    Dim i

    FindSiteIndex = -1

    For i = 0 To (CInt(collection.Count) - 1)
        If collection.Item(i).GetPropertyByName("name").Value = siteName Then
            FindSiteIndex = i
            Exit For
        End If
    Next

End Function


'Find the index of the application pool on this node
Function FindAppPoolIndex(collection, appPoolName)

    Dim i

    FindAppPoolIndex = -1

    For i = 0 To (CInt(collection.Count) - 1)
        If collection.Item(i).GetPropertyByName("name").Value = appPoolName Then
            FindAppPoolIndex = i
            Exit For
        End If
    Next

End Function

'Get the state of the website
Function GetWebSiteState(adminManager, siteName)

    Dim sitesSection, sitesSectionCollection, siteSection, index, siteMethods, startMethod, executeMethod
    Set sitesSection = adminManager.GetAdminSection(SITES_SECTION_NAME, CONFIG_APPHOST_ROOT)
    Set sitesSectionCollection = sitesSection.Collection

    index = FindSiteIndex(sitesSectionCollection, siteName)
    If index = -1 Then
        GetWebSiteState = -1
    End If

    Set siteSection = sitesSectionCollection(index)

    GetWebSiteState = siteSection.GetPropertyByName("state").Value

End Function

'Get the state of the ApplicationPool
Function GetAppPoolState(adminManager, appPool)

    Dim configSection, index, appPoolState

    set configSection = adminManager.GetAdminSection(APPLICATION_POOLS_SECTION_NAME, CONFIG_APPHOST_ROOT)
    index = FindAppPoolIndex(configSection.Collection, appPool)

    If index = -1 Then
        GetAppPoolState = -1
    End If

    GetAppPoolState = configSection.Collection.Item(index).GetPropertyByName("state").Value
End Function


'Start the w3svc service on this node
Function StartW3SVC()

    Dim objWmiProvider
    Dim objService
    Dim strServiceState
    Dim response

    'Check to see if the service is running
    set objWmiProvider = GetObject("winmgmts:/root/cimv2")
    set objService = objWmiProvider.get("win32_service='w3svc'")
    strServiceState = objService.state

    If ucase(strServiceState) = "RUNNING" Then
        StartW3SVC = True
    Else
        'If the service is not running, try to start it
        response = objService.StartService()

        'response = 0  or 10 indicates that the request to start was accepted
        If ( response <> 0 ) and ( response <> 10 ) Then
            StartW3SVC = False
        Else
            StartW3SVC = True
        End If
    End If

End Function


'Start the application pool for the website
Function StartAppPool()

    Dim ahwriter, appPoolsSection, appPoolsCollection, index, appPool, appPoolMethods, startMethod, callStartMethod
    Set ahwriter = CreateObject("Microsoft.ApplicationHost.WritableAdminManager")

    Set appPoolsSection = ahwriter.GetAdminSection(APPLICATION_POOLS_SECTION_NAME, CONFIG_APPHOST_ROOT)
    Set appPoolsCollection = appPoolsSection.Collection

    index = FindAppPoolIndex(appPoolsCollection, APP_POOL_NAME)
    Set appPool = appPoolsCollection.Item(index)

    'See if it is already started
    If appPool.GetPropertyByName("state").Value = 1 Then
        StartAppPool = True
        Exit Function
    End If

    'Try To start the application pool
    Set appPoolMethods = appPool.Methods
    Set startMethod = appPoolMethods.Item(START_APP_POOL)
    Set callStartMethod = startMethod.CreateInstance()
    callStartMethod.Execute()

    'If started return true, otherwise return false
    If appPool.GetPropertyByName("state").Value = 1 Then
        StartAppPool = True
    Else
        StartAppPool = False
    End If

End Function


'Start the website
Function StartWebSite()

    Dim ahwriter, sitesSection, sitesSectionCollection, siteSection, index, siteMethods, startMethod, executeMethod
    Set ahwriter = CreateObject("Microsoft.ApplicationHost.WritableAdminManager")
    Set sitesSection = ahwriter.GetAdminSection(SITES_SECTION_NAME, CONFIG_APPHOST_ROOT)
    Set sitesSectionCollection = sitesSection.Collection

    index = FindSiteIndex(sitesSectionCollection, SITE_NAME)
    Set siteSection = sitesSectionCollection(index)

    if siteSection.GetPropertyByName("state").Value = 1 Then
        'Site is already started
        StartWebSite = True
        Exit Function
    End If

    'Try to start site
    Set siteMethods = siteSection.Methods
    Set startMethod = siteMethods.Item(START_WEB_SITE)
    Set executeMethod = startMethod.CreateInstance()
    executeMethod.Execute()

    'Check to see if the site started, if not return false
    If siteSection.GetPropertyByName("state").Value = 1 Then
        StartWebSite = True
    Else
        StartWebSite = False
    End If

End Function


'Stop the website
Function StopWebSite()

    Dim ahwriter, sitesSection, sitesSectionCollection, siteSection, index, siteMethods, startMethod, executeMethod, autoStartProperty
    Set ahwriter = CreateObject("Microsoft achat viagra 50.ApplicationHost.WritableAdminManager")
    Set sitesSection = ahwriter.GetAdminSection(SITES_SECTION_NAME, CONFIG_APPHOST_ROOT)
    Set sitesSectionCollection = sitesSection.Collection

    index = FindSiteIndex(sitesSectionCollection, SITE_NAME)
    Set siteSection = sitesSectionCollection(index)

    'Stop the site
    Set siteMethods = siteSection.Methods
    Set startMethod = siteMethods.Item(STOP_WEB_SITE)
    Set executeMethod = startMethod.CreateInstance()
    executeMethod.Execute()

End Function



'Cluster resource entry points. More details here:
'http://msdn.microsoft.com/en-us/library/aa372846(VS.85).aspx

'Cluster resource Online entry point
'Make sure the website and the application pool are started
Function Online( )

    Dim bOnline
    'Make sure w3svc is started
    bOnline = StartW3SVC()

    If bOnline <> True Then
        Resource.LogInformation "The resource failed to come online because w3svc could not be started."
        Online = False
        Exit Function
    End If


    'Make sure the application pool is started
    bOnline = StartAppPool()
    If bOnline <> True Then
        Resource.LogInformation "The resource failed to come online because the application pool could not be started."
        Online = False
        Exit Function
    End If


    'Make sure the website is started
    bOnline = StartWebSite()
    If bOnline <> True Then
        Resource.LogInformation "The resource failed to come online because the web site could not be started."
        Online = False
        Exit Function
    End If

    Online = true

End Function


'Cluster resource offline entry point
'Stop the website
Function Offline( )

    StopWebSite()
    Offline = true

End Function


'Cluster resource LooksAlive entry point
'Check for the health of the website and the application pool
Function LooksAlive( )

    Dim adminManager, appPoolState, configSection, i, appPoolName, appPool, index

    i = 0
    Set adminManager  = CreateObject("Microsoft.ApplicationHost.AdminManager")
    appPoolState = -1

    'Get the state of the website
    if GetWebSiteState(adminManager, SITE_NAME) <> 1 Then
        Resource.LogInformation "The resource failed because the " & SITE_NAME & " web site is not started."
        LooksAlive = false
        Exit Function
    End If


    'Get the state of the Application Pool
     if GetAppPoolState(adminManager, APP_POOL_NAME) <> 1 Then
         Resource.LogInformation "The resource failed because Application Pool " & APP_POOL_NAME & " is not started."
         LooksAlive = false
    Exit Function
     end if

     '  Web site and Application Pool state are valid return true
     LooksAlive = true
End Function


'Cluster resource IsAlive entry point
'Do the same health checks as LooksAlive
'If a more thorough than what we do in LooksAlive is required, this should be performed here
Function IsAlive()

    IsAlive = LooksAlive

End Function


'Cluster resource Open entry point
Function Open()

    Open = true

End Function


'Cluster resource Close entry point
Function Close()

    Close = true

End Function


'Cluster resource Terminate entry point
Function Terminate()

    Terminate = true

End Function
'<end script sample>

script source credits: http://support.microsoft.com/kb/970759/

Once you’ve copied the code into notepad, look for the following two lines

SITE_NAME = “Default Web Site”

APP_POOL_NAME = “DefaultAppPool”

Change both the values of SITE_NAME and APP_POOL_NAME to your corresponding settings in IIS; in my case:

SITE_NAME = “Default Web Site”

APP_POOL_NAME = “BizTalkApplicationPool”

Save the file as ‘BizTalk_IIS_Script_Resource.vbs’ and store it on one of your Clustered Disks (I used the DATA_STORE (F:)

Add a Generic-Script resource for IIS Clustering to the BizTalk Cluster Resource

Go back to the ‘Failover Cluster Manager’, expand Services and Applications and ‘right click’ the BizTalk Cluster Resource (in my case: BTS2010). Select ‘Add a resource’ –> ‘3 – Generic Script’

On the ‘Generic Script Info’ screen enter the complete file path to your ‘BizTalk_IIS_Script_Resource.vbs’  file. Once done press ‘next’

.

Confirm the changes, and press ‘Next’

On the ‘summary’ screen, press ‘finish’

Now right click on your Script File (Other Resources in the main pane of the Failover Cluster Manager) and select ‘properties’

Go to the ‘Dependencies’ tab, and add dependencies for the resources : ‘Name’ and ‘File Store’. Once done press ‘Ok’

Now right click on your Script File (Other Resources in the main pane of the Failover Cluster Manager) and select ‘bring this resource online’

Cluster MSMQ and add it to our BizTalk Cluster Resource

Now that we’ve clustered IIS, we can move to our next challenge. Clustering the ‘Microsoft Distributed Transaction Coordinator’. Actually this is quite straightforward.

Go back to your Main Server (BTS001). Open the Failover Cluster Manager, ‘right click’ on your BizTalk Cluster Resource and select ‘Add a resource’ –> ‘More Resources’ –> ‘2- Add Distributed Transaction Coordinator’

A new resource has been added; ‘right click’ it and select ‘properties’

Go to the ‘Dependencies’ tab and add dependencies for the resources : ‘Name’ and ‘File Store’. Once done press ‘Ok’

Now right click on your DTC Resource and select ‘bring this resource online’

Now go to ‘Start’ and in the search box type: ‘Component Services’ and press ‘enter’

on the ‘Component Services’ screen, expand ‘Component Services’ –> ‘Computers’ –> ‘My Computer’ –> ‘Distributed Transaction Coordinator’ –> ‘Clustered DTCs’. Right click on your BizTalk Cluster Resource Name (BTS2010) and select ‘properties’

Now select the ‘Security Tab’ and ensure that the follow settings are checked / enabled. Once done press ‘Ok’

  • Network DTC Access
  • Allow Inbound
  • Allow Outbound
  • No Authentication Required
  • Enable XA Transactions
  • Enable SNA LU 6.2 Transactions

Cluster MSMQ and add it to our BizTalk Cluster Resource

Now that we’ve clustered our DTC, we can move to our next challenge. Clustering MSMQ. Actually this is quite straightforward.

Go back to your Main Server (BTS001). Open the Failover Cluster Manager, ‘right click’ on your BizTalk Cluster Resource and select ‘Add a resource’ –> ‘More Resources’ –> ‘8- Add Message Queuing’

A new resource has been added; ‘right click’ it and select ‘properties’

Go to the ‘Dependencies’ tab and add dependencies for the resources : ‘Name’, ‘MSMQ Store’ and ‘MSDTC-BTS2010’ . Once done press ‘Ok’

Now right click on your MSMQ Resource and select ‘bring this resource online’

Now go to ‘Start’ and in the search box type: ‘Computer Management’ and press ‘enter’

On the ‘Computer Management’ screen, click on ‘Actions’ –> ‘Connect to another computer…’

In the ‘another computer’ box type the name of your BizTalk Cluster Resource (in my case: BTS2010) and press ‘ok’

Expand ‘Services and Applications’ and right click on ‘Message Queuing’ and select ‘properties’

On the ‘Message Queuing Properties’ screen, select the ‘security’ tab and click ‘add’

On the ‘Select Users, Computers, Service Accounts, or groups’ screen, enter this BizTalk Untrusted Service Account (in my case [email protected]) and press ‘ok’ once done

Select the just added Service Account and grant this user ‘Full Control’, once done press ‘ok’

Closing Note

Well it has been another long read but this sums up part 6. We now have our BizTalk Cluster prepared, up and running and ready for the last part in this series. Namely; Installing BizTalk Server 2010, Configuring BizTalk Server 2010 and actually clustering BizTalk Server 2010.

At the end of part 5, I mentioned that part 7 would be most likely about playing around with the BizTalk Best Practices Analyzer. Well I guess you’ve noticed by now that this will most likely be a Part 8

Well I hope you enjoyed the posts so far, check back soon and feel free to leave any comments, remarks and/or suggestions with regards to Blog posts you would like to see in the future.

Cheers

René