This section explains the commands for manipulating template information.
Template information list display command
cfmg_listtemplate [-v] [-utf8]
This command outputs an XML file that contains a list of the template information that has been registered.
Option | Description |
---|---|
-v | This option outputs the list in detailed format. If this option is omitted, the list is output in the simple format. |
-utf8 | This option outputs the list in UTF-8 format. This option is only valid for the Windows version. For the Windows version, the list is output in ISO-8859-1 format if this option is omitted. |
This command uses the following format to output all of the template information that has been registered.
Detailed format | Simple format | Output format |
---|---|---|
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * * * * * * * - * * * * * * * * * * * * * * * - * * - * | *
*
*
*
*
-
-
*
*
*
-
-
-
-
*
-
* | <?xml version="1.0" encoding="UTF-8"?> <templates> <template> <id>[Template ID]</id> <name>[Template name]</name> <baseTemplateId>[Base template ID]</baseTemplateId> <baseTemplateName>[Base template name]</baseTemplateName> <ownerOrg>[Owner organization]</ownerOrg> <ownerUser>[Owner user]</ownerUser> <publicCategory>[Publication category]</publicCategory> <designSheetPath>[Path to the design sheet]</designSheetPath> <releaseDate>[Release date]</releaseDate> <numOfMaxVnet>[Maximum number of VNETs]</numOfMaxVnet> <numOfMaxVm>[Maximum number of VMs]</numOfMaxVm> <description>[Description]</description> <keyword>[Search keyword]</keyword> <estimate>[Estimated amount]</estimate> <license>[License information]</license> <support>[Support information]</support> <productId>[Model number]</productId> <productName>[Product name]</productName> <price>[Unit price]</price> <chargeType>[Billing method]</chargeType> <expectedUsage>[Expected monthly usage]</expectedUsage> <showFlag>[Show flags]</showFlag> <vnets> <vnet> <id>[Network ID]</id> <name>[Name]</name> <numOfMaxVm>[Maximum number of VMs]</numOfMaxVm> <resourceId>[Resource ID]</resourceId> <category>[Network type]</category> </vnet> … </vnets> <servers> <server> <no>[Server serial number]</no> <imageId>[Image ID]</imageId> <name>[Server name]</name> <serverType>[Server type]</serverType> <vmPool>[Resource name of the VM pool]</vmPool> <storagePool>[Resource name of the storage pool]</storagePool> <vnics> <management>[Control NIC]</management> <vnic> <no>[NIC serial number]</no> <networkId>[Connection destination network ID]</networkId> </vnic> … </vnics> <vdisks> <vdisk> <no>[Disk serial number]</no> <diskSize>[Disk capacity]</diskSize> <storagePool>[Resource name of the storage pool]</storagePool> </vdisk> … </vdisks> <softwareOptions> <softwareOption> <softwareId>[Software ID]</softwareId> <choices> <parameterInfo> <id>[Parameter ID]</id> <name>[Parameter name]</name> </parameterInfo> … </choices> </softwareOption> … </softwareOptions> </server> … </servers> </template> … </templates> |
*: Indicates information that is output.
-: Indicates information that is not output.
This command outputs the following data if there is no template information.
<?xml version="1.0" encoding="UTF-8"?> <templates />
# /opt/FJSVcfmg/bin/cfmg_listtemplate <?xml version="1.0" encoding="UTF-8"?> <templates> <template> <id>template-12c95768de8</id> <name>TEMPLATE_SAMPLE1</name> <ownerOrg>cfmgadm</ownerOrg> <ownerUser>cfmgadm</ownerUser> <publicCategory>PUBLIC</publicCategory> <description>Web/App/DB single server model</description> <estimate>0.0000</estimate> <license>0</license> <support>0</support> <productId /> <productName /> <price /> <chargeType /> <expectedUsage /> <showFlag>1</showFlag> </template> </templates>
Template information registration command
cfmg_addtemplate [-id <Template ID>] [-name <Template name>] - xml <Path to the template information file>
This command registers template information.
Option | Description |
---|---|
-id | This option specifies the template ID, using a string made up of up to 32 printable ASCII characters long. |
-name | This option specifies the template name, using a string made up of up to 85 printable ASCII characters long. |
-xml | This option specifies the absolute or relative path to the template information file, using a string made up of printable ASCII characters. |
The template ID that has been allocated is output using the following XML format.
<?xml version="1.0" encoding="UTF-8"?> <result> <id>[Template ID]</id> </result>
None.
# /opt/FJSVcfmg/bin/cfmg_addtemplate -xml /tmp/template_test/sample1.xml <?xml version="1.0" encoding="UTF-8"?> <result> <id>template-12c95768de8</id> </result>
System template publication setup command
cfmg_showtemplate -id <Template ID> -on | off
This command publishes and delists system templates.
Option | Description |
---|---|
-id | This option specifies the ID of the template to be published or delisted. |
-on | This option publishes the system template. |
-off | This option delists the system template. |
None.
None.
# /opt/FJSVcfmg/bin/cfmg_showtemplate -id template-12c95768de8 -on
Template information deletion command
cfmg_deletetemplate [-f] -id <Template ID>
This command deletes template information.
Option | Description |
---|---|
-f | This option executes the deletion without confirmation. |
-id | This option specifies the template ID for the template information file to be deleted. |
None.
None.
# /opt/FJSVcfmg/bin/cfmg_deletetemplate -id template-12c95768de8 Do you want to delete the template? (Y/N) y
Detailed explanation of template information
This section provides detailed template information.
Template information files are XML documents that list configuration information for system templates.
Create and register a separate template information file for each system template.
Sample template information files are stored in the following directory.
The service provider must create template information files by referring to these samples.
[Windows] Storage location: <CIMS installaton folder>\Systemwalker\SWCFMG\templates\templates\ The following sample files are stored: sample1.xml (for single server configurations) sample2.xml (for two-tier server configurations) sample3.xml (for three-tier server configurations) [Linux] Storage location: /opt/FJSVcfmg/templates/templates/ The following sample files are stored: sample1.xml (for single server configurations) sample2.xml (for two-tier server configurations) sample3.xml (for three-tier server configurations)
Refer to "Detailed template information" for details on the items (tags).
For the image ID in the template information file, enter the image ID of a virtual image that has been registered.
Template information files use the following XML format.
<?xml version="1.0" encoding="UTF-8" ?> <template version="1.1"> <id>[Template ID]</id> <lcid>[Locale ID]</lcid> <name>[Template name]</name> <baseTemplateId>[Base template ID]</baseTemplateId> <ownerOrg>[Owner organization]</ownerOrg> <ownerUser>[Owner user]</ownerUser> <publicCategory>[Publication category]</publicCategory> <designSheetPath>[Path to the design sheet]</designSheetPath> <releaseDate>[Release date]</releaseDate> <numOfMaxVnet>[Maximum number of VNETs]</numOfMaxVnet> <numOfMaxVm>[Maximum number of VMs]</numOfMaxVm> <productId>[Model number]</productId> <description>[Description]</description> <keyword>[Search keyword]</keyword> <estimate>[Estimated amount]</estimate> <license>[License information]</license> <support>[Support information]</support> <vnets> <vnet> <id>[Network ID]</id> <name>[Name]</name> <numOfMaxVm>[Maximum number of VMs]</numOfMaxVm> <resourceId>[Network resource ID]</resourceId> </vnet> … </vnets> <servers> <server> <no>[Server serial number]</no> <imageId>[Image ID]</imageId> <imageName>[Image name]</imageName> <name>[Server name]</name> <serverType>[Server type]</serverType> <vmPool>[Resource name of the VM pool]</vmPool> <storagePool>[Resource name of the storage pool]</storagePool> <vnics> <management>[Control NIC]</management> <vnic> <no>[NIC serial number]</no> <networkId>[Connection destination network ID]</networkId> </vnic> … </vnics> <vdisks> <vdisk> <no>[Disk serial number]</no> <diskSize>[Disk capacity]</diskSize> <storagePool>[Resource name of the storage pool]</storagePool> </vdisk> … </vdisks> </server> … </servers> </template>
The following table shows descriptions of each of these items (tags), as well as their settings.
Modify template information files as necessary, by referring to the information in this table.
The square brackets enclosing some of the tag names indicate that these tags can be omitted.
Tag name | Type | Setting range | Description | Required? | Settings |
---|---|---|---|---|---|
[ id ] | string | 0 to 32 bytes | This item specifies the ID to be allocated to the template. | O | If this item is omitted, IDs will be assigned automatically. |
[ lcid ] | string | Select | This item specifies the locale for template information. | M | Select one of the following values: |
[ name ] | string | Up to 85 characters | This item specifies the name of the template. | O | |
baseTemplatId | - | - | This item specifies the name of the base template. | U | |
ownerOrg | string | Fixed value | This item specifies the organization ID of the organization to which the template belongs. | M | The value is fixed as "cfmgadm". |
ownerUser | string | Fixed value | This item specifies the user ID of the user who registers the template. | M | The value is fixed as "cfmgadm". |
publicCategory | string | Fixed value | This item specifies the category of the template. | M | The value is fixed as "PUBLIC". |
designSheetPath | - | - | This item specifies the directory where the design sheet is stored. | U | |
releaseDate | string | 0 to 10 bytes | This item specifies the date when the template is to be published. | O | The format is "yyyy/mm/dd". |
numOfMaxVnet | integer | 1 to 99 | This item specifies the maximum number of segments that can be used by the system in the template. | M | |
numOfMaxVm | integer | 0 to 10 | This item specifies the maximum number of servers that can be used by the system in the template. | M | |
productId | - | - | This item specifies a product ID for the template that will be used for billing purposes. | U | |
description | string | Up to 85 characters | This item contains a description of the template, explaining the system that the template produces, the content of the template, and so on. | O | |
keyword | string | Up to 85 characters | This item specifies a search keyword for the template. | O | The function for searching templates uses this keyword to find the template. |
estimate | decimal | Fixed value | This item specifies the price of the template. | M | The value is fixed as "0". |
license | string | Select | This item specifies whether a license has been assigned to the template. | M | Select the following value: |
support | string | Select | This item specifies whether support has been assigned to the template. | M | Select one of the following values: |
vnets | - | - | This item specifies a segment for the system. | U | |
[ vnet ] | - | One or more | This item specifies a separate segment information tag for each segment. | U | This item is required only when segment information exists. |
Id | string | 1 to 20 bytes | This item specifies an ID for identifying the segment within the template. | M | Specify a unique ID within the template. |
name | string | 0 to 20 bytes | This item specifies the name of the segment. | O | |
numOfMaxVm | integer | 0 to 10 | This item specifies the maximum number of servers that can be used by adding them to the segment. | M | |
[ resourceId ] | string | 1 to 32 bytes | This item specifies the resource ID of the virtualization network to be allocated to the segment. | M | Use the cfmg_listvnet command (described in "Virtual network list display command") to verify resource IDs. |
servers | - | - | This item specifies a server for the system. | U | |
server | - | One or more | This item is for server information and specified for each server. | M | |
No | integer | 0 to 9 | This item specifies the number of the server. | M | Specify a serial number for the server that is unique within the template. |
imageId | - | - | This item specifies the image ID for the image to be deployed to the server. | U | It is necessary to register the image information and check the image ID beforehand. |
imageName | string | 1 to 32 bytes | This item specifies the image name of the image to be deployed to the server. | M | It is necessary to register the image information and check the image name in advance. |
name | string | Up to 85 characters | This item specifies the name of the server. | M | This is a name that is used to distinguish servers within the template, and is not the host name. |
serverType | string | 1 to 32 bytes | This item specifies the name of an L-Server Template that has been set up and will be selected as the default L-Server Template. | M | Specify the same value as was specified in the image information file. |
[ vmPool ] | string | 1 to 32 bytes | This item specifies the resource name of the VM pool where the server will be deployed. Example: | O | If this option is omitted, the first VM pool will be selected. |
[ storagePool ] | string | 1 to 32 bytes | This item specifies the resource name for the storage pool where the server will be deployed. | O | If this option is omitted, the first storage pool will be selected. |
vnics | - | - | This item specifies a NIC. | U | |
[ management ] | integer | 1 or more | This item specifies the number of the NIC to be specified as the control NIC. | M | Specify the value that was specified for the <no> tag under the <vnic> tag. |
[ vnic ] | - | One or more | This item is specified for each NIC. | U | |
No | integer | 1 to 99 | This item specifies the number of the NIC. | M | Specify a number for the NIC that is unique within the server. |
networkId | string | 1 to 20 bytes | This item specifies the segment ID for the segment to connect to. | M | Specify the value that was specified for the <id> tag under the <vnet> tag. |
vdisks | - | - | This item specifies the expansion disk for the server. | U | |
[ vdisk ] | - | One or more | This item is specified for each disk. | U | This item is required only when expansion disks exist. |
[ no ] | integer | 1 or more | This item specifies a number for the disk that is unique within the server. | M | For the shared disk, the same value must be specified for all servers. |
[ diskSize ] | decimal | In decimal notation, to one decimal place | This item specifies the size of the disk. | M | Specify this value in GB. |
[ storagePool ] | string | 1 to 32 bytes | This item specifies the resource name for the storage pool where the expansion disk will be deployed. | O | If this item is omitted, the first storage pool is selected. |
The symbols in the "Required?" column have the following meaning:
M: If the tag is specified, be sure to specify a value.
O: The value can be omitted.
U: There is no need to set a value. Only the tag itself is specified.