< Back

Get-SVTtask

Tue Jan 14, 2020 2:08 am

NAME Get-SVTtask



SYNOPSIS

Show information about tasks that are currently executing or have finished executing in HPE SimpliVity





SYNTAX

Get-SVTtask [[-Task] <PSObject>] [<CommonParameters>]





DESCRIPTION

Performing most Post/Delete calls to the SimpliVity REST API will generate task objects as output.

Whilst these task objects are immediately returned, the task themselves will change state over time. For example,

when a Clone VM task completes, its state changes from IN_PROGRESS to COMPLETED.



All cmdlets that return a JSON 'task' object, e.g. New-SVTbackup, New-SVTclone will output custom task objects of

type HPE.SimpliVity.Task and can then be used as input here to find out if the task completed successfully. You can

either specify the Task ID from the cmdlet output or, more usefully, use $SVTtask. This is a global variable that

all

'task producing' HPE SimpliVity cmdlets create. $SVTtask is overwritten each time one of these cmdlets is executed.





PARAMETERS

-Task <PSObject>

The task object(s). Use the global variable $SVTtask which is generated from a 'task producing' HPE SimpliVity

cmdlet, like

New-SVTbackup, New-SVTclone and Move-SVTvm.



Required? false

Position? 1

Default value $SVTtask

Accept pipeline input? true (ByValue)

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

System.String

HPE.SimpliVity.Task





OUTPUTS

HPE.SimpliVity.Task





-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Get-SVTtask



Provides an update of the task(s) from the last HPESimpliVity cmdlet that creates, deletes or updates a SimpliVity

resource









-------------------------- EXAMPLE 2 --------------------------



PS C:\\>New-SVTbackup -VMname MyVM



PS C:\\> Get-SVTtask



Shows the state of the task executed from the New-SVTbackup cmdlet.









-------------------------- EXAMPLE 3 --------------------------



PS C:\\>Get-SVTvm | Where-Object VMname -match '^A' | New-SVTclone



PS C:\\> Get-SVTtask



The first command enumerates all virtual machines with names beginning with the letter A and clones them.

The second command monitors the progress of the clone tasks.











RELATED LINKS