VMware VCM 5.3 - TRANSPORT LAYER SECURITY IMPLEMENTATION Guide de l'utilisateur Page 93

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 258
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 92
For additional information about Windows PowerShell and signing scripts, see:
n
Scripting with Windows PowerShell: http://technet.microsoft.com/en-us/scriptcenter/dd742419.aspx
n
Windows PowerShell Owner's Manual: http://technet.microsoft.com/en-us/library/ee176949.aspx
n
Signing Windows PowerShell Scripts: http://technet.microsoft.com/en-
us/magazine/2008.04.powershell.aspx
n
Execution Policies: http://technet.microsoft.com/en-us/library/dd347641.aspx
n
Registry value that controls execution policy: http://msdn.microsoft.com/en-
us/library/bb648598(VS.85).aspx
Developing Custom Collection Scripts
Development of custom collection scripts requires planning the data structure. WCI internally stores data
hierarchically, as displayed in the Tree View - Standard node. The collection script is required to provide all
of the structure that can be seen in any branch under this node.
The root element in the XML result data set will become a top level (root) element in the WCI data type
node. Child elements will appear in the same locations in the VCMuser interface as the locations they
populate in the XML document that is returned by the script.
When developing custom collection scripts, follow these guidelines:
n
XML element names must be unique at their level (for example, two "Child1" nodes can exist, as long as
they are not siblings).
n
Attributes must be unique at their level.
n
Element and attribute names used must be valid XML when returned by the script. If data is to be
returned as an element or an attribute name that is not valid for XML, the name can be encoded using
the [ToCMBase64String] function. The inserter will recognize names encoded with this function and
will decode them during the raw insert process. The inserter is a Collector job that is executed during
each collection. It is responsible for parsing the Agent results files and putting the data into a new raw
database table. The raw data is then transformed into the data that appears in the nodes in the user
interface.
function ToCMBase64String([string]$input_string)
{
return [string]("cmbase64-" +
[Sys-
tem.Co-
nvert]::ToBase64String([System.Text.Encoding]::UNICODE.GetBytes($input_
string))).replace("=","-")
}
n
If a script has configurable parameters, they should be described in a comment block near the top of
the script, along with configurable entries of the parameters near the top of the script, so that a user
who is cloning a WCI collection filter can easily see and set the parameters in the Edit Filter wizard (in
Administration > Collection Filters > Filters).
n
Declaration of variables, and any other tasks in a script that produce output that is not part of the XML
result set, should be redirected to out-null, such as:
[reflection.assembly]::LoadWithPartialName("Microsoft.SqlServer.Smo") > out-
null
Getting Started with VCM
VMware, Inc. 93
Vue de la page 92
1 2 ... 88 89 90 91 92 93 94 95 96 97 98 ... 257 258

Commentaires sur ces manuels

Pas de commentaire