Product SiteDocumentation Site

5.3. Resource Properties

Questo valore indica al cluster quale script utilizzare per la risorsa, dove trovarlo ed a quali standard è conforme.

Tabella 5.1. Proprietà di una Primitive Resource

Campo Descrizione
id
Your name for the resource
class
The standard the script conforms to. Allowed values: ocf, service, upstart, systemd, lsb, stonith
type
The name of the Resource Agent you wish to use. Eg. IPaddr or Filesystem
provider
The OCF spec allows multiple vendors to supply the same ResourceAgent. To use the OCF resource agents supplied with Heartbeat, you should specify heartbeat here.

Resource definitions can be queried with the crm_resource tool. For example
# crm_resource --resource Email --query-xml
might produce:

Esempio 5.1. An example system resource

<primitive id="Email" class="service" type="exim"/>

Nota

One of the main drawbacks to system services (such as LSB, Systemd and Upstart) resources is that they do not allow any parameters!

Esempio 5.2. Un esempio di risorsa OCF

<primitive id="Public-IP" class="ocf" type="IPaddr" provider="heartbeat">
   <instance_attributes id="params-public-ip">
      <nvpair id="public-ip-addr" name="ip" value="1.2.3.4"/>
   </instance_attributes>
</primitive>