If you are not familiar with MCF in MOM 2005 you can read more about it here. I do not go into detail about MCF here as that is an area best covered by Jakub. What I do want to show you is how to setup MCF over tiering using the Operations Manager Command Shell. I encourage you to look at how to setup tiering before continuing on with this post.
MCF over tiering is a bit different than normal tiering in that you must define a run-as account used by the Connector to connect to the tiered Management Group. Let's start by creating a run-as account used to connect to the Management Group you would like to tier. There is no Cmdlet for creating a run-as account so we must use PowerShell script to make Operations Manager SDK calls.
$runAsAccount = New-Object Microsoft.EnterpriseManagement.Monitoring.Security.MonitoringWindowsCredentialSecureData;
# Use Get-Credential to get a password in the form of a SecureString type.
$tierCreds = Get-Credential;
# Assumes the user name is in format "domain\user".
$domain,$userName, $junk = $tierCreds.UserName.Split("\");
$runAsAccount.Name = "My Tiered MCF Run-As Account"; # The name for this run-as account.
$runAsAccount.UserName = $userName;
$runAsAccount.Domain = $domain;
$runAsAccount.SecureData = $tierCreds.Password;
$mg = (Get-Item .).ManagementGroup; # Get a reference to the SDK Management Group object.
$mg.InsertMonitoringSecureData($runAsAccount); # Insert the run-as account.
That's that was a bit verbose. Just to make sure everything worked as expected run the following command and verify your new run-as account exists.
Get-RunAsAccount | fl Name
Next we need to create a tier.
# Get the credentials required to connect to the tiered Management Group.
$creds = Get-Credential ;
# Create the tier.
$tier = New-Tier -Name: "MyMcfTier" -ManagementServerName: "server2" -Credential: $creds -RunAsAccount: $runAsAccount;
Make sure your tier exists.
Get-Tier | fl Name
Next we need to create the Connector. There is no Cmdlet for creating a Connector so we must use PowerShell script to make Operations Manager SDK calls.
$connectorInfo = New-Object Microsoft.EnterpriseManagement.ConnectorFramework.ConnectorInfo;
$connectorInfo.Name = "McfOverTieringConnector";
$connectorInfo.Description = "McfOverTieringConnector Description"
$connectorInfo.DiscoveryDataIsManaged = $false;
$connector = $mg.GetConnectorFrameworkAdministration().Setup($connectorInfo);
Make sure your connector exists.
Get-Connector | fl Name
Last but not least we need to add the connector to the tier.
Add-ConnectorToTier -Tier: $tier -Connector: $connector;
Clearly the Command Shell could benefit from a New-RunAsAccount Cmdlet and a New-Connector Cmdlet to simplify this process. In the mean time I recommend you create functions that encapsulate any process that can't be completed using Cmdlets if you must complete the process multiple times.