PowerShell script exchange
Post Reply
Voodoo
Novice
Posts: 4
Liked: 1 time
Joined: May 22, 2023 1:25 pm
Contact:

Get Running SQL Log Job Session Stats

Post by Voodoo »

Hi,

I would like to retrieve the session summary stats for an active/running SQL log job for a report - pretty much all the information in the red boxes in the below picture.
I'm mainly interested in the number of successes, warnings, and errors, and the result of the last session for each individual VM/task in the log job.
This is for both agent and VM backup jobs.

I already have a script to list the overall result of a completed SQL log job, but can't work out how to do the above.


Image

https://imgur.com/a/A9h5p4i

Thanks.
david.domask
Veeam Software
Posts: 2069
Liked: 503 times
Joined: Jun 28, 2016 12:12 pm
Contact:

Re: Get Running SQL Log Job Session Stats

Post by david.domask » 1 person likes this post

Hi @Voodoo

post466985.html?hilit=log%20backup#p466985

Does this thread help you? You can get the sessions that way and then format the output as you desire.
David Domask | Product Management: Principal Analyst
Voodoo
Novice
Posts: 4
Liked: 1 time
Joined: May 22, 2023 1:25 pm
Contact:

Re: Get Running SQL Log Job Session Stats

Post by Voodoo » 1 person likes this post

Thanks David, that was exactly what I was after.

Don't know how I missed that post when searching.
david.domask
Veeam Software
Posts: 2069
Liked: 503 times
Joined: Jun 28, 2016 12:12 pm
Contact:

Re: Get Running SQL Log Job Session Stats

Post by david.domask »

Happens :) I knew we had the code elsewhere on the forums and I just didn't have an active SQL Log backup job to test with, so I knew what to search.

Glad I could help, and good luck with scripting.
David Domask | Product Management: Principal Analyst
Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests