Which script should you use?

You create a job that has two tasks named Task1.exe and Task2.exe. Task2.exe requires a minimum of two cores for optimum performance of your application. The corporate policy states that you must use a maximum of four cores to run a job. You need to write a Windows PowerShell script to use all the four cores to run the job every time the job is run.
Which script should you use?

You create a job that has two tasks named Task1.exe and Task2.exe. Task2.exe requires a minimum of two cores for optimum performance of your application. The corporate policy states that you must use a maximum of four cores to run a job. You need to write a Windows PowerShell script to use all the four cores to run the job every time the job is run.
Which script should you use?

A.
$job = New-HpcJob numcores 1-4
$job | Add-HpcTask numcores 1-4 -Command Task1.exe $job | Add-HpcTask numcores 2-4 -Command Task2.exe
$job | Submit-HpcJob

B.
$job = New-HpcJob
$job | Add-HpcTask numcores 2 -Command Task1.exe
$job | Add-HpcTask numcores 2-4 -Command Task2.exe $job | Submit-HpcJob

C.
$job = New-HpcJob numcores 4
$job | Add-HpcTask numcores 2-4 -Command Task1.exe $job | Add-HpcTask numcores 2-4 -Command Task2.exe $job | Submit-HpcJob

D.
$job = New-HpcJob
$job | Add-HpcTask numcores 1-4 -Command Task1.exe $job | Add-HpcTask numcores 2-4 -Command Task2.exe $job | Submit-HpcJob



Leave a Reply 0

Your email address will not be published. Required fields are marked *