export_template
Exports a monitoring template. You can export a template to the file system in the form of an XML file, or you can print it on standard output in XML form.
Format
emcli export_template -name=<name> -target_type=<target_type> [-output_file=<file_for_exported_template>] [-archive] [ ] indicates that the parameter is optional
Options
-
name
Name of the template. The name and target type uniquely identify a template.
-
target_type
Target type of the template.
-
output_file
Specifies the file to output the template. If not specified, the template prints to
stdout
. -
archive
Indicates that the template must be exported as a zip file. When a Metric Extension is included in the template, this option is required to export the template as a zip file.
Examples
Example 1
This example shows that template XML specified by name HOST_TEMP1
and target type host
will be output to the screen.
emcli export_template -name=HOST_TEMP1 -target_type=host
Example 2
This example shows that template XML specified by name HOST_TEMP1
and target type host
will be created in the test.xml
file.
emcli export_template -name=HOST_TEMP1 -target_type=host -output_file=test.xml