Export-HpcJob
Syntax
![]() |
|
---|---|
Parameter Set: job Export-HpcJob -Job <HpcJob> -Path <String> [-Force] [-Scheduler <String> ] [ <CommonParameters>] Parameter Set: id Export-HpcJob [-Id] <Int32> -Path <String> [-Force] [-Scheduler <String> ] [ <CommonParameters>] |
Detailed Description
Exports the specified job to an XML file. You can then import the file by specifying the file in the JobFile parameter of the New-HpcJob cmdlet to create a new job based on the exported job.
Parameters
-Force
Replaces the job XML file if it already exists, without prompting the user.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
not applicable |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-Id<Int32>
Specifies the identifier of the job that you want to export. You cannot use the Id parameter together with the Job parameter.
Aliases |
none |
Required? |
true |
Position? |
1 |
Default Value |
no default |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-Job<HpcJob>
Specifies an HpcJob object that corresponds to the job that you want to export. To get an HpcJob object, use the Get-HpcJob command. You cannot use the Job parameter together with the Id parameter.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
no default |
Accept Pipeline Input? |
true (ByValue) |
Accept Wildcard Characters? |
false |
-Path<String>
Specifies a name for the XML file to which you want to export the job, including the full or relative path to the file if the Export-HpcJob cmdlet should not save the file in the current directory.
This cmdlet creates any directories that do not already exist in that path. If the file already exists and you do not specify the Force parameter, the cmdlet prompts you to confirm whether or not you want to replace the file.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
no default |
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 contains the job you want to export. 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>
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
%CCP_SCHEDULER% |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
<CommonParameters>
This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters
Inputs
The input type is the type of the objects that you can pipe to the cmdlet.
- An HpcJob object.
Outputs
The output type is the type of the objects that the cmdlet emits.
- None.
Examples
EXAMPLE 1
Exports the job with an identifier of 8 to a file named Job8.xml.
![]() |
|
---|---|
Get-HpcJob -id 8 | Export-HpcJob -Path Job8.xml |