Hi All,
I would like to fetch the last 24 hours backup status of each and every client with the details "Client_name, Job_name, Status, Start_time, End_time"
Client_name, Job_name, Status data are fetched using the below script
$vbrsessions = Get-VBRBackupSession | Where-Object {$_.JobType -eq "Backup" -and $_.EndTime -ge (Get-Date).addhours(-24)}
foreach ($session in $vbrsessions) {$session.gettasksessions()| Select Name, Jobname, Status, }
How can I get the Start time and End time of each client?
Thanks in advance
-
- Influencer
- Posts: 17
- Liked: 3 times
- Joined: Jul 09, 2021 12:42 pm
- Full Name: Suryanarayanan
- Location: Bangalore India
- Contact:
-
- Veteran
- Posts: 1143
- Liked: 302 times
- Joined: Apr 27, 2020 12:46 pm
- Full Name: Natalia Lupacheva
- Contact:
Re: Script to fetch client's backup details for the last 24 hours
Hi Suryanarayanan,
You can try with the following parameters:
Thanks!
You can try with the following parameters:
Code: Select all
foreach ($session in $vbrsessions) {$session.gettasksessions()| Select Name, Jobname, Status, @{n='StartTimeLocal';e={$_.Progress.StartTimeLocal}}, @{n='EndTimeLocal';e={$_.Progress.StopTimeLocal}}}
Thanks!
-
- Influencer
- Posts: 17
- Liked: 3 times
- Joined: Jul 09, 2021 12:42 pm
- Full Name: Suryanarayanan
- Location: Bangalore India
- Contact:
Re: Script to fetch client's backup details for the last 24 hours
Hi Natalia,
Thanks for your prompt response. It solves my query
Thanks for your prompt response. It solves my query
-
- Veteran
- Posts: 1143
- Liked: 302 times
- Joined: Apr 27, 2020 12:46 pm
- Full Name: Natalia Lupacheva
- Contact:
Re: Script to fetch client's backup details for the last 24 hours
Glad to hear that!
Don't hesitate to ask if you have any further questions.
Thanks!
Don't hesitate to ask if you have any further questions.
Thanks!
Who is online
Users browsing this forum: No registered users and 6 guests