Posts RSS Comments RSS 253 Posts and 411 Comments till now

Citrix Load Evaluators

I have had a few request for how to deal with Citrix Load Evaluators. There are few gotchas, but it is fairly strait forward.

There are two Built-in Citrix Load Evaluators Default and Advanced.. the problem is that from MFCom, this is not what they are called. This is what you should use.
– Default = MFDefaultLE
– Advanced = LMSDefaultLE

function Set-CitrixLoadEvaluator{
    Param($server = $(throw ‘$Server is Required’),$LoadEvaluator = "MFDefaultLE")

    # Loading Server Object
    $type = [System.Type]::GetTypeFromProgID("MetaframeCOM.MetaframeServer",$Server)
    $mfServer = [system.Activator]::CreateInstance($type)

    # Getting Current LE
    $le = $mfServer.AttachedLE
    Write-Host "Old Evaluator: $($le.LEName)"
    Write-Host "Setting Load Evaluator on $server to $LoadEvaluator"

    # Assigning New LE

    # Checking LE
    $le = $mfServer.AttachedLE
    Write-Host "Load Evaluator Set to $($le.LEName)"

Trackback this post | Feed on Comments to this post

Leave a Reply

You must be logged in to post a comment.