6.2.9.3 mktemplate

Create a file template.

Purpose

The mktemplate command creates an Exascale file template.

Syntax

mktemplate  [ --vault vault | --cluster ] { --file-type file-type | --name template-name } --content-type content-type --media-type media-type --redundancy redundancy

Command Options

Specify the following mktemplate command options to identify the template and its scope:

  • --vault: Create a template associated with the specified vault.

  • --cluster: Create a template associated with the cluster.

  • --file-type: Create a template associated with the specified file type. If you specify this option, the template name is the same as the file type.

  • --name: Create a user-defined template having the specified name.

Specify the following File Storage Attributes, which are associated with the template:

  • --media-type: Specifies the physical media type that is used to store the file. Exascale uses this attribute to place the file in a storage pool that uses the specified media type. Possible values are:
    • HC: Identifies high capacity storage media, which uses hard disk drives (HDDs).
    • EF: Identifies extreme flash storage media, which uses flash devices.
  • --redundancy: Specifies the number of data copies that are maintained. Possible values are:
    • normal: Maintains 2 mirrored copies of the file data.
    • high: Maintains 3 mirrored copies of the file data.
  • --content-type: Specifies the type of content in the file. Exascale internally uses this attribute to place file extents on physically separate devices in a way that maximizes availability if failures occurs. Possible values are:
    • DATA
    • RECO

Usage Notes

Note the following information when using this command:

  • You can define the scope of the template by specifying the --vault option or the --cluster option. You cannot specify both options simultaneously.

    If neither option is specified, then the scope of the template is inferred from the current working directory in the ESCLI session. If the current working directory in the ESCLI session is the root directory, then the template is associated with the cluster. Otherwise, the template is associated with the vault that is referenced in the current working directory.

  • You must define the template as a user template by specifying the --name option, or you must associate the template with a file type by using the --file-type option. You cannot specify both options simultaneously.

  • You can view a list of Exascale file types by using the ESCLI lstemplate command. For example:

    @> lstemplate --cluster
    @> lstemplate --vault VAULT1 --all

Examples

Example 6-122 Create a User-Defined Cluster-Wide Template

This example shows creating a user-defined template named T1. The template is associated with the cluster, as neither --vault or --cluster are specified, and the current working directory in the ESCLI session is the root directory.

@> mktemplate --name T1 --content-type DATA --media-type HC --redundancy high

Example 6-123 Create a User-Defined Vault-Specific Template

This example shows creating a user-defined template named T2. The template is associated with the vault named VAULT1, as neither --vault or --cluster are specified, and the current working directory in the ESCLI session is inside VAULT1.

@VAULT1> mktemplate --name T2 --content-type DATA --media-type HC --redundancy high

Example 6-124 Create a User-Defined Vault-Specific Template

This example shows creating a user-defined template named T3 that is associated with the vault named VAULT1.

@> mktemplate --name T3 --vault VAULT1 --content-type DATA --media-type HC --redundancy high

Example 6-125 Create a User-Defined Cluster-Wide Template

This example shows creating a user-defined cluster-wide template named T4. The --cluster option overrides the fact that the current working directory in the ESCLI session is inside VAULT1.

@VAULT1> mktemplate --name T4 --cluster --content-type DATA --media-type HC --redundancy high

Example 6-126 Create a Template for a Specific Vault and File Type

This example shows creating a template associated with the DATAFILE file type and the vault named VAULT1.

@> mktemplate --file-type DATAFILE --vault VAULT1 --content-type DATA --media-type HC --redundancy high

Example 6-127 Create a Cluster-Wide Template for a Specific File Type

This example shows creating a cluster-wide template associated with the DATAFILE file type.

@> mktemplate --file-type DATAFILE --cluster --content-type DATA --media-type HC --redundancy high