Creating and editing aliases
Applies To: Windows Server 2003, Windows Server 2003 R2, Windows Server 2003 with SP1, Windows Server 2003 with SP2
Creating and editing aliases
You can use the WMI tools to create aliases as Managed Object Format (MOF) files. You can use WMI Common Information Model (CIM) Studio to generate a MOF file for a selected class. This file should be edited to create an instance of MSFT_CliAlias. The MOF files can then be used to register the alias. Aliases are registered with WMI by compiling the MOF form of the alias.
When viewing the role namespaces using WMI browsing tools (such as WMI CIM Studio), only the MSFT_CliAlias and MSFT_CliTranslateTable classes have instances. Their properties might include objects of the other classes, but the other classes do not have instances of their own. For this reason, when creating aliases, you primarily create instances in the MSFT_CliAlias class. You create instances of the other classes as properties of the MSFT_CliAlias class or as properties of its properties.
Localization is supported by using localized text arrays defined in the schema. Localization of aliases descriptions is done through the MFL file (CliEgAliases.mfl).
Adding roles to any WMI namespace can be done, for example, by copying WMIC's CliEgAliases.mof file, and then changing the namespace reference to the namespace that is to be used as a role. The new file can then be compiled with MOFCOMP.exe. Aliases can then be added as described above.
Any WMI namespace can serve as a role; but without the additional steps above, such a role would not have WMIC's interactive help or the base classes required for aliases.
For more information, see Windows Management Instrumentation Command-line.