HP

HP Systems Insight Manager 5.1 用户指南

简体中文
  扩展管理的工具  |  定制工具  |  定制工具参考   

定制工具参考

目录
索引
声明
简介
产品概述
入门
发现和标识
用户和授权
目录服务
联网和安全性
监视系统、群集和事件
存储集成
通过任务进行管理
扩展管理的工具
群集监视程序
命令行工具
配置或修复代理概述
定制工具
新建远程工具
新建 CMS 工具
新建网页工具
管理定制工具
编辑远程工具
编辑 CMS 工具
编辑网页工具
删除定制工具
查看工具定义文件
删除和恢复定制工具
用于定制工具的环境变量
在定制工具中使用参数字符串的示例
定制工具参考
配置 DMI 访问
配置 SNMP 访问
设备 Ping 操作
磁盘阈值
许可证管理器
管理处理器工具
管理 MIB
安装 OpenSSH
PMP 工具
复制代理设置
RPM Package Manager
服务器迁移软件
System Management Homepage
系统页
版本控制
虚拟机管理软件
基于 WBEM 的工具
可用的 MSA 工具
合作伙伴应用程序
报告
管理系统和事件
故障排除
参考信息
打印版本
词汇表
使用帮助
 工具类型
 参数化字符串
 工具过滤
 版本号
 其他要求
 文档类型定义

工具类型

有三种基本类型的 HP Systems Insight Manager (HP SIM) 工具:单系统模式 (SSA) 工具、多系统环境 (MSA) 工具和 Web 浏览器启动 (WLA) 工具。

SSA 工具在目标系统上执行,它只识别目标系统环境。因此,在执行 SSA 工具时,分布式任务工具 (DTF) 会将工具信息发送到每个 HP SIM 代理,以执行该 SSA 工具。例如,用于容纳常见 UNIX 命令(如 lscatcp)的工具就是一个 SSA 工具。

MSA 工具在中央系统(有时为中央管理服务器 (CMS))上执行,它知道如何处理一系列目标系统。例如,用于容纳 HP-UX 系统上的 Ignite-UX 功能的工具就是一个 MSA 工具。

WLA 工具通常在浏览器中执行,它由统一资源定位器 (URL) 指定。

参数化字符串

要正确创建工具,工具开发人员必须了解 URL 和命令行的形成方式。使用参数化字符串,工具开发人员可以极大地增强创建工具定义文件 (TDEF) 时使用的选项。

与标准 C 库中常见的 printf() 函数内使用的格式字符串类似,参数化字符串包含替换字段。这些字段可替换为用户在运行时输入的值(由工具参数属性定义)、任务控制器提供的某些标准任务属性、与所选目标系统或系统组相关的值,或者从全局工具属性文件中检索的属性值。这样,便可以生成非常具体的 URL 或命令行。

参数化字符串替换表

下列参数提供全局属性值的替换项:

参数说明
%t 所执行的任务的 ID
%u运行该工具的用户的名称
%e以其身份执行该工具的用户的名称
%s运行该工具的核心 CMS 的管理服务器主机名
%#(其中 # 是一个正整数)替换用户针对所提供的数字 (#) 引用的参数输入的值,作为列表索引位置(以 1 为基数...%1、%2、%3 等等)
%y简单对象访问协议 (SOAP) 登录令牌,将与 SOAP 单次登录 Web 应用程序一起使用

下列参数提供当前所选目标的替换项:

参数说明
%f目标系统(如果字符串中包含 %x 切换,则为系统组)的系统名或 IP 地址。
%n网络名(主机名、IP 地址,或遵循该顺序的系统名)。
%a网络地址(IP 地址)。
%l采用由系统链路配置设置指定的格式的链路名(名称、IP 地址或完整的 DNS 名称)。
%p该目标的 WBEM 代理服务器 IP 地址(如果有),其格式为 <ip address>:<port#></port#></ip>。
%g目标系统(如果字符串中包含 %x 切换,则为系统组)的数据库 GUID。
%b目标系统的系统类型。
%c目标系统的系统子类型。
%r% (rt[.attribute]%)替换具有在参数“rt”中指定的关系类型的相关系统。如果指定了 [.attribute],则为相关系统返回指定的系统属性之一。此外,常见属性(如网络名称 (.a))也可以正常运行。例如,要获取服务器的管理处理器的 IP 地址,可使用 %r{MgmtProcToServer.a%};要获取联系人,可使用 %r{MgmtProcToServer.Contact%}。如果省略了相关系统的属性,则为每个系统返回网络名称和 IP 地址。网络名称和 IP 地址以“网络名称|IP 地址”的格式返回。如果返回了多个系统,则使用逗号分隔这些系统。请注意,可以使用关系类型“MgmtProcToServer”来为所有管理处理器关系类型返回相关系统的信息。
%(attribute]%)指定的目标系统属性的值。

下列参数提供重复功能来支持多个选定的目标系统:

参数说明
%( ... %)重复模式(仅在当前选择存在时才重复)。如果当前目标选择不存在,则扩展时将删除分隔符之间的文本。这样可以使文本成为可选文本,并依赖于目标选择列表。
%i选择索引(以 1 为基数)。
%z不替换任何内容,但将选择索引递增为下一个整数,并将引用的目标系统递增为所选目标列表中的下一个目标。
%⇚< ... >l加密的文本(在替换其他所有参数后加密)。
%%使您替换后可以在命令/URL 中保留 %。

工具过滤

工具过滤是一种工具,工具编写者可通过它来控制是否在选定系统上执行该工具。大多数工具都与平台相关,因为这些工具的成功执行取决于某些平台提供的命令,而不取决于其他平台提供的命令。例如,bdf 工具取决于 HP-UX 平台提供的 bdf 命令,而在 Linux 平台上,使用该名称的工具则不可用。仅当至少存在一个可传递过滤要求的已发现的系统时,才会在 工具 菜单中显示工具。已发现的系统必须传递过滤要求,并且仅当传递了所有过滤要求后才被执行。要实现此目的,工具将在系统过滤表达式中指定系统属性,这些属性必须由可以运行该工具的所有系统拥有。

如果无法针对选定的系统启动某个工具,则会显示错误消息,并提供工具无法启动的原因的信息。

运行工具所需的系统属性由采用以下格式的系统过滤表达式指定:

				
<node-filter name="attribute-name" operator="eq" 
   value="attribute-value" />
      or
<node-filter name="attribute-name" operator="ge" 
   value="attribute-value" />
      or
<node-filter name="attribute-name" operator="lt" 
   value="attribute-value" />
      or
<node-filter name="attribute-name" operator="ct" 
   value="attribute-value" />
      or
<node-filter name="attribute-name" operator="neq" 
   value="attribute-value" />
      or
<node-filter name="attribute-name" operator="nct" 
  value="attribute-value" />
			

eq 运算符指定可以运行该工具的系统必须严格使用指定的属性值。该运算符将应用到系统过滤表达式中允许的任何属性名称。ge 运算符指定可以运行该工具的系统至少要使用指定的属性值。lt 和 ge 运算符只能与版本属性一起使用,具体而言,这些版本属性为 OS type 过滤器中的 OSRevision 以及 Protocol type 过滤器的所有属性。这些属性的值可以是数字或字符串。ct 运算符指定可以运行该工具的系统必须具有包含指定值的属性。neq 运算符指定可以运行该工具的系统不能使用与指定的属性值完全相同的属性值。该运算符将应用到系统过滤表达式中允许的任何属性名称。nct 运算符指定可以运行该工具的系统必须具有未包含指定值的属性。对于系统而言,过滤表达式可以指定的数值型属性包括 OSRevisionProtocol Support 属性,这两个属性的值为版本号。下一节中的版本号中描述了版本号的允许值,以及这些值的比较方式。attribute-name 是下一节中的表内列出的某个值,或者是系统 ProtocolSupport 属性中的协议名称。attribute-value 是 attribute-name 的可能的系统属性值之一。

属性值基于 Distributed Management Task Force (DMTF) 通用信息模型 (CIM)。 通常,这些值会在系统标识过程中定义,该过程使用 WBEM 和 SNMP 来确定系统属性。 对于此发行版,有效的 OSName 值为 HP-UX 和 Linux。对于 OSName 值 HP-UX,OSRevision 属性值删除了最前面的字母字段(例如,B.11.11 将存储为 11.11)。

系统过滤表达式将作为包含过滤表达式的一部分使用。有三种类型的包含过滤表达式。每种类型都允许不同类别的用于过滤的属性名。

类别过滤器类型允许的属性名
操作系统osOSName、OSVendor、OS Revision
硬件硬件DeviceType、DeviceSubType、Model
协议支持协议除 HTTP 以外的其他任何协议名称
其他其他可以是任何预定义的系统属性或任何定制系统属性。

包含过滤器包括一个或多个使用允许的属性名的系统过滤表达式。例如,操作系统过滤器可能包括:

				
<include-filter type="os">
	      <node-filter name="OSName"     
		    operator="eq" value="LINUX"  />
	      <node-filter name="OSVendor"   
            operator="eq" value="RedHat" />
	      <node-filter name="OSRevision" 
            operator="ge" value="7.2"	  />
</include-filter>
			

包含过滤器无需包括所有允许的属性。如果包括多个属性,则通过逻辑 AND 将各个条件组合起来。属性不能在包含过滤器中多次出现,但是,如果一个运算符是 lt,另一个运算符是 ge,则包含版本号值的属性可出现两次。例如:

				
<include-filter type="protocol">
	      <node-filter name="WBEM" 
            operator="lt" value="2.6" />
          <node-filter name="WBEM" 
            operator="ge" value="2.4" />
</include-filter>
			

这将会指定,应对于支持 WBEM 协议 2.4 或更高版本(但低于 2.6 版)的任何系统集合显示该工具。

如果工具包含多个不同类型的包含过滤器,则通过逻辑 AND 将过滤器的条件组合在一起。具有操作系统相关性和硬件相关性的工具可以使用以下过滤器:

				
<include-filter type="os">
	      <node-filter name="OSName"     
	        operator="eq" value="LINUX"  />
 </include-filter>
 <include-filter type="hardware">
	      <node-filter name="DeviceSubType" 
	        operator="eq" value="HPVectra" />
 </include-filter>
			

如果工具包含多个相同类型的包含过滤器,则通过逻辑 OR 将过滤器的条件组合在一起。在两个不同操作系统上提供的工具可以指定:

				
<include-filter type="os">
	      <node-filter name="OSName"     
	        operator="eq" value="LINUX"  />
</include-filter>
<include-filter type="os">
	      <node-filter name="OSName"     
	        operator="eq" value="HPUX"	 />
</include-filter>
			

可以在使用 Linux 或 HP-UX 的任何系统集合上启动该工具。

工具过滤取决于所过滤的、具有选定系统上定义的值的属性。对于 os 过滤器类型,如果过滤使用的任何属性未定义给某个系统,则假定该系统具有过滤器所需的值。因此,将假定不包含由工具过滤器指定的任何 os 属性的系统可以运行该工具。对于 hardware 过滤器类型,如果使用 Model 属性,则以上语句为 true。但对于 DeviceTypeDeviceSubType 属性,工具过滤器仅适用于选定系统上的已知值。protocol 过滤器类型要求在应用运算符之前,系统上必须存在协议。这意味着 neqnct 运算符也依赖于系统来获得该协议。 另一个过滤器的工作方式同样类似于 protocol 过滤器,因此,在应用运算符之前,用于过滤的属性必须在系统上存在。 如果工具使用其他 and/or protocol 过滤器,那么,要使工具在 GUI 中显示,必须至少有一个系统包含可过滤的属性。

版本号

如果可能,OSRevisionProtocol Support 系统属性将包含解释为版本号的值。版本号是一系列以句点 (.) 字符分隔的非负十进制数。比较版本号时,将使用下列规则:

  • 系列中最左边的编号最重要,因此 1.0 大于 0.1。

  • 编号中的前导零将被忽略,因此 003 等于 3。

  • 相连的两个句点字符被解释为分隔编号 0,因此 1.0.3 等于 1..3

  • 以句点字符开头被解释为以零开头,因此 .9 等于 0.9。

  • 结尾零编号将被忽略,因此 1.0.0 等于 1。

其他要求

SSA 命令工具必须包含一个执行语句 (execStmt) 或一个文件复制语句 (copyStmt),或包含此两者。如果只指定执行语句,则执行命令前不复制任何文件。 如果只指定文件复制语句,则复制文件后不执行命令。如果指定这两个语句,则先复制文件,再执行命令。

MSA 命令工具必须指定一个命令以及执行该命令的系统。

工具名称的长度必须至少包含 1 个字符,且不超过 256 个字符。该名称的第一个字符必须是字母。第一个字符后面的字符可以是字母、数字、空格或下列任一字符:“-”、“.”、“(”、“)”或“_”。

Web 浏览器启动工具必须指定一个主 URL。

指定文件复制对时,单个 TDEF 中每个文件复制对的目标文件路径必须唯一。为多个源文件路径指定相同的目标文件路径将导致文件分析错误。

如果文件不存在或不可读,则运行复制文件的工具时将会出错。创建或修改工具时不会检查源文件路径,但是,在执行工具时,该路径必须存在。

如果将 log 元素设置为 true,则执行工具时产生的标准输出和标准错误输出将记录在中央管理服务器 (CMS) 日志文件 /var/opt/mx/logs/mx.log 中。如果将其设置为 false,则只记录摘要任务日志信息,例如开始时间、结束时间和任务状态。

文档类型定义

文档类型定义 (DTD) 文件定义 XML 文件的限制。这些限制包括有效的元素标记、属性,以及 XML 文件中的元素的基数。工具 DTD 文件的名称为 toollist.dtd,它包含在以下段落中。请注意,由于联机帮助页格式设置的问题,DTD 内容可能与文件中显示的内容不相同。

				
<?xml version="1.0" encoding="UTF-8" ?>

<!-- The tool-list element can contain zero or more of 
      ssa-command-tool elements, msa-command-tool elements,
      web-launch-tool elements, automation-tool elements or
      app-launch-tool elements.-->
      
<!ELEMENT tool-list ( ssa-command-tool |
      msa-command-tool |
      web-launch-tool  |
      automation-tool  |
      app-launch-tool )* >

<!-- The ssa-command-tool element specifies a single-system aware
      tool. The ssa-command-tool element can optionally specify a
      category element, a description element, a comment element, an
      owner element, a default-target element, an execute-as-user
      element, a job-display-handler element, a toolbox-enabled
      element, zero or more toolbox elements, zero or more
      include-filter elements, or zero or more env-variable elements.
      (NOTE: The role-enabled and role elements are deprecated
      elements and should not be used with this product. These
      are provided for backward compatibility with previous
      products. The toolbox-enabled element and the toolbox
      element should be used in their stead.)
      If more than one of these elements are specified, the element
      must appear in the order as listed in this definition. The
      ssa-command-tool element must contain an ssa-block element. The
      ssa-block element must appear after the previously described
      optional elements, if any of the optional elements are
      specified. Following the ssa-block element, one can specify zero
      or more attribute elements.-->
	  
 <!ELEMENT ssa-command-tool (category?, description?, comment?,
      owner?, default-target?, execute-as-user?,
      job-display-handler?,
      toolbox-enabled?, toolbox*,
      role-enabled?, role*,
      include-filter*, env-variable*,
      ssa-block, attribute* ) >

<!-- In addition to the previously described elements, the
      ssa-command-tool element specifies the following attributes. The
      name attribute specifies the tool name and must be specified in
      the ssa-command-tool element. The visible attribute specifies
      whether the tool is visible for running. By default tools are
      visible. The max-targets attribute specifies the maximum number
      of targets against which a tool can run. The revision attribute
      allows a tool author to specify a revision for the tool. Note
      that this is for information only. The job-log attribute
      specifies whether the results of the command will be kept in this
      system's job log. This attribute applies only to tools when they
      are run as scheduled tasks, not when they are run as "run now"
      tasks. When job-log="true" the job and target status for the tool
      will be kept for a relatively lengthy system-defined period in
      the database after the job completes. When job-log="false" only
      the last completed copy of the job and target status for the task
      will be kept in the cache for a much shorter period of time, and
      will not be written to the database.	 Job logging is enabled by
      default. The schedulable attribute specifies whether the tool can
      be run as a schedulable task. When scheduled="false" the tool can
      only run as a "run now" task.  Tools are scheduled by default.
      The GUID attribute specifies a globally unique identifier (GUID)
      for the tool. Because the system generates a GUID for a tool
      during the add operation, this field should only be specified
      during a modify operation. The accepts-targets attribute specifies
      whether the tool accepts targets for execution. The
      accepts-targets attribute is true by default. -->

<!ATTLIST ssa-command-tool name	     CDATA   #REQUIRED
      visible     (true | false) "true"
      max-targets NMTOKEN #IMPLIED
      revision    CDATA   #IMPLIED
      job-log     (true | false) "true"
      schedulable (true | false) "true"
      guid	     NMTOKEN #IMPLIED
      accepts-targets (true|false) "true" >

<!-- The ssa-block specifies the elements specific to a single-system
      aware tool. The ssa-block can specify a command or copy-block or
      both. Only one command should be specified but up to 16 multiple
      copy-blocks can be specified. After the command and/or
      copy-blocks, one can specify the parameters for the command
      and/or copy-block. -->
  
<!ELEMENT ssa-block (( command | copy-block )+, parameter*) >

<!-- The copy-block specifies a source file path and a destination
      file path for a copy operation. -->

<!ELEMENT copy-block ( source, destination )+ >

<!-- The source element specifies the source file path for a copy
      operation. -->

<!ELEMENT source (#PCDATA) >

<!-- The destination element specifies the destination file path for a
      copy operation. -->
     
<!ELEMENT destination (#PCDATA) >

<!-- The msa-command-tool element specifies a multiple-system aware
      tool. The msa-command-tool element can optionally specify a
      category element, a description element, a comment element, an
      owner element, a default-target element, an execute-as-user
      element, a job-display-handler element, a toolbox-enabled
      element, zero or more toolbox elements, zero or more
      include-filter elements, or zero or more env-variable elements.
      (NOTE: The role-enabled and role elements are deprecated
      elements and should not be used with this product. These
      are provided for backward compatibility with previous
      products. The toolbox-enabled element and the toolbox
      element should be used in their stead.)
      If more than one of these elements are specified, the element
      must appear in the order as listed in this definition. The
      msa-command-tool element must contain an msa-block element. The
      msa-block element must appear after the previously described
      optional elements, if any of the optional elements are
      specified. Following the msa-block element, one can specify zero
      or more attribute elements.-->
      
<!ELEMENT msa-command-tool (category?, description?, comment?, owner?,
      default-target?, execute-as-user?,
      job-display-handler?,
      toolbox-enabled?, toolbox*,
      role-enabled?, role*,
      include-filter*, env-variable*,
      msa-block, attribute* ) >

<!-- In addition to the previously described elements, the
      msa-command-tool element specifies the following attributes. The
      name attribute specifies the tool name and must be specified in
      the msa-command-tool element. The visible attribute specifies
      whether the tool is visible for running. By default tools are
      visible. The max-targets attribute specifies the maximum number
      of targets against which a tool can run.  The revision attribute
      allows a tool author to specify a revision for the tool. Note
      that this is for information only. The job-log attribute
      specifies whether the results of the command will be kept in this
      systems job log. When job-log="true" the job and target status
      for the tool will be kept for a relatively lengthy system-defined
      period in the database after the job completes. When
      job-log="false" only the last completed copy of the job and
      target status for the tool will be kept in the cache for a much
      shorter period of time, and will not be written to the database.
      Job logging is enabled by default. The schedulable attribute
      specifies whether the tool can be run as a scheduled task. When
      schedulable="false" the tool can only run as a "run now" task.
      Tools are schedulable by default.  The guid attribute specifies a
      globally unique identifier (GUID) for the tool. Because the
      system generates a GUID for a tool during the add operation, this
      field should only be specified during a modify operation.  The
      accepts-targets attribute specifies whether the tool
      accepts targets for execution. The accepts-targets attribute is
      true by default. -->

<!ATTLIST msa-command-tool name	     CDATA   #REQUIRED
      visible     (true | false) "true"
      max-targets NMTOKEN #IMPLIED
      revision    CDATA   #IMPLIED
      job-log     (true | false) "true"
      schedulable (true | false) "true"
      guid	     NMTOKEN #IMPLIED
      accepts-targets (true|false) "true" >

<!-- The msa-block specifies the elements specific to a
      multiple-system aware (MSA) tool. The msa-block can specify an
      MSA command, the parameters for the command and an execution system
      on which the command executes. -->
      
<!ELEMENT msa-block ( command, parameter*, execution-system ) >

<!-- The command element specifies the command for an SSA or an MSA
      tool. If the command accepts parameters, it must be specified as
      a parameterized string. -->
     
<!ELEMENT command ( #PCDATA ) >

<!-- The command element can have two attributes. The command-type
      attribute specifies whether the command is an x-window, stdout,
      restart, launch, or an unknown command type. The default command
      type is stdout. The log attribute specifies whether the results
      of the command will be output to this system's audit log. When
      log="true" the stdout and stderr results of the command will be
      output to the system's audit log. Command output is not logged
      by default. -->
      
<!ATTLIST command command-type (x-window |
      stdout   |
      restart  |
      launch   |
      unknown) "stdout"
      log (true | false) "false" >

<!-- The execution-system element specifies the system on which an MSA
      tool will execute. -->
      
<!ELEMENT execution-system ( #PCDATA ) >

<!-- The web-launch-tool element specifies a web launch tool. The
      web-launch-tool element can optionally specify a category
      element, a description element, a comment element, an owner
      element, a default-target element, an execute-as-user element, a
      job-display-handler element, a toolbox-enabled element, zero or
      more toolbox elements,  zero or more include-filter elements, or
      zero or more env-variable elements.
      (NOTE: The role-enabled and role elements are deprecated
      elements and should not be used with this product. These
      are provided for backward compatibility with previous
      products. The toolbox-enabled element and the toolbox
      element should be used in their stead.)
      If more than one of these elements are specified, the element
      must appear in the order as listed in this definition. The
      web-launch-tool element must contain a web-block element. The
      web-block element must appear after the previously described
      optional elements, if any of the optional elements are
      specified. Following the web-block element, one can specify zero
      or more attribute elements.-->
      
<!ELEMENT web-launch-tool (category?, description?, comment?, owner?,
      default-target?, execute-as-user?,
      job-display-handler?,
      toolbox-enabled?, toolbox*,
      role-enabled?, role*,
      include-filter*, web-block, attribute* ) >

<!-- In addition to the previously described elements, the
      web-launch-tool element specifies the following attributes. The
      name attribute specifies the tool name and must be specified in
      the web-launch-tool element. The visible attribute specifies
      whether the tool is visible for running. By default tools are
      visible. The max-targets attribute specifies the maximum number
      of targets against which a tool can run.  The revision attribute
      allows a tool author to specified a revision for the tool. Note
      that this is for information only. The job-log attribute
      specifies whether the results of the command will be kept in this
      systems job log. When job-log="true" the job and target status
      for the tool will be kept for a relatively lengthy system-defined
      period in the database after the job completes. When
      job-log="false" only the last completed copy of the job and
      target status for the tool will be kept in the cache for a much
      shorter period of time, and will not be written to the database.
      Job logging is enabled by default.  The schedulable attribute
      specifies whether the tool can be run as a scheduled task. When
      schedulable="false" the tool can only run as a "run now" task.
      Tools are schedulable by default. The guid attribute specifies a
      globally unique identifier (GUID) for the tool. Because the
      system generates a GUID for a tool during the add operation, this
      field should only be specified during a modify operation. -->

<!ATTLIST web-launch-tool name	    CDATA #REQUIRED
      visible	    (true | false) "true"
      max-targets NMTOKEN #IMPLIED
      revision    NMTOKEN #IMPLIED
      job-log	    (true | false) "true"
      schedulable (true | false) "true"
      guid	    NMTOKEN #IMPLIED >

<!-- The web-block specifies the elements specific to a web launch
      tool. The web-block must specify a main-url element. Optionally,
      the web-block can specify a side-url element, a status-url
      element, and a current-url element. Additionally, the web-block
      can specify the parameters for the URLs. Finally, the web-block
      can optionally specify a target format to describe how targets
      are passed to a Web-launch aware tool. -->
      
 <!ELEMENT web-block (main-url, (side-url?, status-url?, current-url?),
      parameter*, target-format? ) >

<!-- In addition to the above elements, the web-block element has one
      attribute. The accepts-targets attribute specifies whether the
      web launch tool accepts targets for execution. The
      accepts-targets attribute is true by default. -->
      
<!ATTLIST web-block accepts-targets (true|false) "true">

<!-- The main-url specifies the URL to launch the tool. If the URL
      accepts parameters, the URL must be specified as a parameterized
      string. -->
      
<!ELEMENT main-url ( #PCDATA ) >

 <!-- The status-url specifies a URL at which one might find the status
      of this web launch tool during execution. -->
      
<!ELEMENT status-url ( #PCDATA ) >

<!-- The current-url specifies the current URL. -->

<!ELEMENT current-url ( #PCDATA ) >

<!-- The side-url specifies a set-aside URL. -->

<!ELEMENT side-url ( #PCDATA ) >

<!-- The target-format defines the format of targets in a web launch
      tool and is specified as a parameterized string.-->
      
<!ELEMENT target-format ( #PCDATA ) >

<!-- The automation tool performs an action on the CMS which
      involves accessing the target systems. The automation-tool element
      can optionally specify a category element, a menu-category
      element, a description element, a comment element, an owner
      element, a default-target element, an execute-as-user element, a
      job-display-handler element, a default-parameter element, a
      role-enabled element, zero or more  role elements,  zero or more
      include-filter elements, or zero or more env-variable elements.
      If more than one of these elements are specified, the element
      must appear in the order as listed in this definition. The
      automation-tool element must contain an automation-block element.
      The automation-block element must appear after the previously
      described optional elements, if any of the optional elements are
      specified. Following the automation-block element, one can
      specify zero or more attribute elements. -->
      
<!ELEMENT automation-tool (category?, description?, comment?, owner?,
      default-target?, execute-as-user?,
      job-display-handler?,
      toolbox-enabled?, toolbox*,
      role-enabled?, role*,
      include-filter*, automation-block,
      attribute* ) >

<!-- In addition to the previously described elements, the
      automation-tool element specifies the following attributes. The
      name attribute specifies the tool name and must be specified in
      the automation-tool element. The visible attribute specifies
      whether the tool is visible for running. By default tools are
      visible. The max-targets attribute specifies the maximum number
      of targets against which a tool can run. The revision attribute
      allows a tool author to specify a revision for the tool. Note
      that this is for information only.  The job-log attribute
      specifies whether the results of the command will be kept in this
      systems job log. When job-log="true" the job and target status
      for the tool will be kept for a relatively lengthy system-defined
      period in the database after the job completes. When
      job-log="false" only the last completed copy of the job and
      target status for the tool will be kept in the cache for a much
      shorter period of time, and will not be written to the database.
      Job logging is enabled by default. The schedulable attribute
      specifies whether the tool can be run as a scheduled task. When
      schedulable="false" the tool can only run as a "run now" task.
      Tools are schedulable by default.  The guid attribute specifies a
      globally unique identifier (GUID) for the tool. Because the
      system generates a GUID for a tool during the add operation, this
      field should only be specified during a modify operation. The
      accepts-targets attribute specifies whether the tool
      accepts targets for execution. The accepts-targets attribute is
      true by default. -->
      
!ATTLIST automation-tool	 name	     CDATA   #REQUIRED
      visible     (true | false) "true"
      max-targets NMTOKEN #IMPLIED
      revision    CDATA   #IMPLIED
      job-log     (true | false) "true"
      schedulable (true | false) "true"
      guid	     NMTOKEN #IMPLIED
      accepts-targets (true|false) "true" >

<!-- The automation-block specifies the elements specific to an
      automation tool. The automation-block must specify a
      message-id. -->
      
<!ELEMENT automation-block (message-id) >

<!-- The message-id is the internal string representation of the message
      sent by the Automation engine to cause the tool to run. -->
      
<!ELEMENT message-id ( #PCDATA ) >

<!-- The app-launch-tool element specifies an application launch
      tool. The app-launch-tool element can optionally specify a
      category element, a menu-category element, a description element,
      a comment element, an owner element, a default-target element, an
      execute-as-user element, a job-display-handler element, a
      default-parameter element, a role-enabled element, zero or more
      role elements,  zero or more include-filter elements, or zero or
      more env-variable elements. If more than one of these elements
      are specified, the element must appear in the order as listed in
      this definition. The app-launch-tool element must contain an
      app-launch-block element. The app-launch-block element must
      appear after the previously described optional elements, if any
      of the optional elements are specified. Following the
      app-launch-block element, one can specify zero or more attribute
      elements. -->

<!ELEMENT app-launch-tool (category?, description?, comment?, owner?,
      default-target?, execute-as-user?,
      job-display-handler?,
      role-enabled?, role*,
      toolbox-enabled?, toolbox*,
      include-filter*,  env-variable*,
      app-launch-block, attribute* ) >

<!-- In addition to the previously described elements, the
      app-launch-tool element specifies the following attributes. The
      name attribute specifies the tool name and must be specified in
      the app-launch-tool element. The visible attribute specifies
      whether the tool is visible for running. By default tools are
      visible. The max-targets attribute specifies the maximum number
      of targets against which a tool can run. The revision attribute
      allows a tool author to specify a revision for the tool. Note
      that this is for information only.  The job-log attribute
      specifies whether the results of the command will be kept in this
      systems job log. When job-log="true" the job and target status
      the tool will be kept for a relatively lengthy system-defined
      period in the database after the job completes. When
      job-log="false" only the last completed copy of the job and
      target status for the tool will be kept in the cache for a much
      shorter period of time, and will not be written to the database.
      Job logging is enabled by default. The schedulable attribute
      specifies whether the tool can be run as a scheduled task. When
      schedulable="false" the tool can only run as a "run now" task.
      Tools are schedulable by default.  The guid attribute specifies a
      globally unique identifier (GUID) for the tool. Because the
      system generates a GUID for a tool during the add operation, this
      field should only be specified during a modify operation. The
      accepts-targets attribute specifies whether the tool
      accepts targets for execution. The accepts-targets attribute is
      true by default. -->

<!ATTLIST app-launch-tool	 name	     CDATA   #REQUIRED
      visible     (true | false) "true"
      max-targets NMTOKEN #IMPLIED
      revision    CDATA   #IMPLIED
      job-log     (true | false) "true"
      schedulable (true | false) "true"
      guid	     NMTOKEN #IMPLIED
      accepts-targets (true|false) "true" >

<!-- The app-launch-block specifies the elements specific to an
      application launch tool. The app-launch-block specifies a
      required command element. -->
      
<!ELEMENT app-launch-block (command, app-parameters?) >

<!-- In addition to the previously described elements, the
      app-launch-block element specifies the following attribute. The
      alert-driven attribute specifies whether the alert list or the
      system list is used to determine the target systems to run the tool
      on. -->

<!ATTLIST app-launch-block alert-driven (true | false) "false" >

<!-- The app-parameters element is an application parameters
      definition string whose value is a string -->
      
<!ELEMENT app-parameters ( #PCDATA ) >

<!-- The env-variable element is an environment variable definition
      string whose value is a string -->
      
<!ELEMENT env-variable ( #PCDATA ) >

<!-- In addition to the previously described elements, the
      env-variable element specifies the following attribute. The
      name attribute specifies the name of the environment variable.-->
      
<!ATTLIST env-variable name CDATA #REQUIRED >

<!-- The owner element specifies the tool owner. When the owner field
      is specified, the tool is only associated with the All Tools toolbox.
      When the owner field is not specified, tool is enabled in all
      of its associated toolboxes. When a limited-rights user adds or
      modifies a tool, the owner field contains the name of the
      limited-rights user. Only a full-rights user can add or modify a
      tool without the owner specified. -->
      
<!ELEMENT owner ( #PCDATA ) >

 !-- The comment field specifies additional information about the
      tool. It is usually more verbose that the description. -->

<!ELEMENT comment ( #PCDATA ) >

<!-- The parameter element specifies the first to the tenth parameter
      of a tool. -->
     
<!ELEMENT parameter EMPTY >

<!-- The parameter element has three attributes. The index attributes
      specifies which argument in a parameterized string this parameter
      substitutes. Parameters can be indexed from 1 to 10 with a
      default index of 1. Tools cannot contain parameters with
      duplicate indexes. If more than one parameter in a tool
      definition contains the same index, only the first parameter added
      to the tool with the duplicate index remains in the tool. The
      prompt attribute provides information about the parameter that
      can be displayed in a GUI for assistance. The required attribute
      specifies whether this parameter must be specified when the tool
      is executed. By default, parameters are not required.  The private
      attribute specifies whether this parameter is encoded and stored
      securely.  By default, parameters are not private. -->
<!ATTLIST parameter index	 (1|2|3|4|5|6|7|8|9|10) "1"
     prompt CDATA #REQUIRED
      required (true|false) "false"
      private (true|false) "false" >

<!-- The toolbox-enabled element specifies whether the toolboxes
      associated with a tool are enabled. -->

<!ELEMENT toolbox-enabled EMPTY >

<!-- The toolbox-enabled element has one attribute. The value
      attribute specifies whether the tool within the toolboxes is enabled.
      This allows a full-rights user to explicitly disable the tools in
      a toolbox though the tool is always enabled in the All Tools
      toolbox.  By default, the tool is enabled in all the toolboxes that
      it is in.  If a tool is disabled within a toolbox, it cannot be
      executed. -->
      
<!ATTLIST toolbox-enabled value (true|false) "true">

<!-- The role-enabled element specifies whether the roles associated
      with a tool are enabled. This is an obsolete element. The
      toolbox-enabled element should be used instead.-->
      
<!ELEMENT role-enabled EMPTY >

<!-- See description of toolbox-enabled element attributes. -->

<!ATTLIST role-enabled value (true|false) "true">

<!-- The default-target element specifies a target on which the tool
      can run if no targets are specified at run time. One can specify
      a system, &cms2; to run on the &cms2; by default, or ALL to run on all
      authorized systems by default. -->
      
<!ELEMENT default-target ( #PCDATA ) >

<!-- The category element specifies the category with which to
      associate the tool. By default, tools are associated with the
      "Local Tools" category. -->

<!ELEMENT category ( #PCDATA ) >

<!-- The description element specifies a simple description of the
      tool. To specify more verbose information such as how to run the
      tool, use the comment element. -->

<!ELEMENT description ( #PCDATA ) >

<!-- For SSA and MSA command tools, the execute-as-user element
      specifies the user name that the tool runs as or under whose
      account the tool runs on the target systems. For Web-launch
      tools the execute-as-user is passed to the URL for its use. -->

<!ELEMENT execute-as-user ( #PCDATA ) >

<!-- The job display hander element specifies the fully-qualified
      name of a class implementing the JobDisplayHander interface,
      used to display the results of a job created by running this
      tool. -->

<!ELEMENT job-display-handler ( #PCDATA ) >

<!-- The toolbox element specifies a toolbox to associate with the
      tool. To run a tool the user must be authorized with one of the
      specified toolboxes. -->

<!ELEMENT toolbox EMPTY >

<!-- The toolbox element has one attribute to specify the toolbox
      name. -->

<!ATTLIST toolbox toolbox-name CDATA #REQUIRED >

<!-- The role element specifies a role to associate with the tool. To
      run a tool the user must be authorized with one of the specified
      roles. This element is obsolete. The toolbox element should be
      used instead. -->

<!ELEMENT role EMPTY >

<!-- See the toolbox element attribute description. -->

<!ATTLIST role role-name CDATA #REQUIRED >

<!-- The include-filter element specifies system attributes against
      which to filter a tool for execution. A specified include-filter
      element must contain one or more system-filter elements. When
      filtering a tool each include-filter block is OR'd together to
      get the final filter result. Each system-filter element within an
      include-filter block is AND'd together. -->
      
<!ELEMENT include-filter (system-filter)+ >

<!-- The include-filter elements has one attribute. The type attribute
      specifies the type of include filter to execute. Four types are
      currently recognized.  Three of them are os (operating system), 
      hardware, protocol filtering. The fourth type is called other which 
      will allow all other system attributes to be filtered upon.-->

<!ATTLIST include-filter type (os | hardware | protocol | other) "os" >

<!-- The system-filter element is an empty element that contains
      attributes used to specify the system attributes against which to
      filter a tool for execution. -->
      
<!ELEMENT system-filter EMPTY >

<!-- The system-filter element is specified with three attributes. The
      name attribute specifies the system attribute name to filter
      against. The operator attribute specifies whether to filter
      against an equal value, a less than value, a greater than or
      equal value, a contains value, a not equals value or a not
      contains value. The operator name is case-insensitive. The
      value attribute specifies the value of the system attribute to
      filter against. -->
      
<!ATTLIST node-filter name CDATA #REQUIRED
      operator (EQ | GE | LT | CT | NEQ | NCT |
      eq | ge | lt | ct | neq | nct |
      Eq | Ge | Lt | Ct | Neq | Nct |
      eQ | gE | lT | cT | nEQ | nCT ) "EQ"
      value CDATA #REQUIRED >

<!-- The attribute element specifies the name value pairs that
      comprise client attributes. The client attribute name is
      specified using the name attribute and the client attribute value
      is specified as the PCDATA of the element. -->

<!ELEMENT attribute ( #PCDATA ) >

<!ATTLIST attribute name CDATA #REQUIRED >
			

相关步骤

 定制工具 - 删除和恢复定制工具
 定制工具 - 编辑 CMS 工具
 定制工具 - 编辑远程工具
 定制工具 - 编辑网页工具

相关主题

 扩展管理的工具 - 命令行工具