Export (0) Print
Expand All

Copy-HpcNodeTemplate

Creates a new node template by making a copy of an existing node template.

Syntax

Copy-HpcNodeTemplate [-NewName <string>] [-Scheduler <string>] [-Name] <string> [<CommonParameters>]

Copy-HpcNodeTemplate [-NewName <string>] [-Scheduler <string>] -Template <HpcNodeTemplate> [<CommonParameters>]

Detailed Description

Creates a new node template by making a copy of an existing node template.

Parameters

-Name <string>

Specifies the name of the existing node template that you want to copy. You cannot specify both the Name and Template parameters. Use the Get-HpcNodeTemplate cmdlet to view the names of existing node templates.

 

Required?

true

Position?

1

Default Value

no default

Accept Pipeline Input?

false

Accept Wildcard Characters?

true

-NewName <string>

Specifies a name for the new node template that the Copy-HpcNodeTemplate cmdlet creates. If you do not specify a name for the new node template, the cmdlet uses "Copy of " followed by the name of the node template you want to copy as the name of new node template. If a node template with that name already exists, the Copy-HpcNodeTemplate cmdlet tries the names Copy of <original_template_name> (2), Copy of <original_template_name> (3),... until the cmdlet finds a name that no other node template uses.

 

Required?

false

Position?

named

Default Value

Copy of <original_template_name>

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Scheduler <string>

Specifies the host name or IP address of the head node for the cluster that includes the node template you want to copy. The value must be a valid computer name or IP address. If you do not specify the Scheduler parameter, this cmdlet uses the scheduler on the head node that the CCP_SCHEDULER environment variable specifies. To set this environment variable, run the following cmdlet:

Set-Content Env:CCP_SCHEDULER <head_node_name>

 

Required?

false

Position?

named

Default Value

%CCP_SCHEDULER%

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Template <HpcNodeTemplate>

Specifies an HpcNodeTemplate object for the node template that you want to copy. Use the Get-HpcNodeTemplate cmdlet to get an HpcNodeTemplate object for a node template. You cannot specify both the Template and Name paramters.

 

Required?

true

Position?

named

Default Value

no default

Accept Pipeline Input?

true (ByValue)

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters.

Input and Return Types

The input type is the type of the objects that you can pipe to the cmdlet. The return type is the type of the objects that the cmdlet emits.

 

Input Type

An HpcNodeTemplate object.

Return Type

An HpcNodeTemplate object.

Notes

You can specify the node template that you want to copy by name or by using an HpcNodeTemplate object.

Example 1

C:\PS>Copy-HpcNodeTemplate -Name MyTemplate

Creates a new node template as a copy of the existing node template named MyTemplate. The new node template has a name of Copy of MyTemplate by default.

Example 2

C:\PS>Copy-HpcNodeTemplate -Name MyExistingTemplate -NewName MyNewTemplate

Creates a new node template named MyNewTemplate as a copy of the existing node template named MyExistingTemplate.

Example 3

C:\PS>Get-HpcNodeTemplate -Name MyExistingTemplate | Copy-HpcNodeTemplate -NewName MyNewTemplate

Gets an HpcNodeTemplate object for the node template named MyExistingTemplate, then creates a new node template named MyNewTemplate as a copy of that existing node template.

See Also

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft