Jump to content
Sign in to follow this  
mwh87

Export Veeam Backup Jobs Info to CSV and emailing

Recommended Posts

I've been tasked with taking the Dataviews > Veeam Backup > Jobs info and exporting to CSV and then emailing. I need the following fields - Client, Backup Server, Name, Status, Last Run, and Next Run from the dataview.  I've seen a few forums saying this requires running SQL commands. At the very least if anyone has some documentation to point me in the right direction it would be appreciated. Thanks!

Share this post


Link to post
Share on other sites

I was using this SQL Query in a script to download stats from the Veeam Plugin.  I ran this as a step in a script to create the CSV daily.  

 

The script worked but I found that the plugin wasn't updating the Dataviews with current data so I nixed the script.  Maybe this'll help you.

 

SELECT "Client", "Location", "Backup Server", "Name", "Type", "Status", "Last Run", "Next Run", "Schedule", "Message", "Duration", "Avg. Duration", "Bottleneck", "Transferred Data MB", "Processing Rate MB/s"
UNION ALL
SELECT CLIENT AS `Client`, location AS `Location`, SERVER AS `Backup Server`, job_name AS `Name`, `type` AS `Type`, `status` AS `Status`, last_run AS `Last Run`, next_run AS `Next Run`, SCHEDULE AS `Schedule`, message AS `Message`, duration AS `Duration`, avg_duration AS `Avg. Duration`, bottleneck AS `Bottleneck`, transferred_data_mb AS `Transferred Data MB`, processing_rate_mb_s AS `Processing Rate MB/s` 
FROM plugin_veeam_lbp_v_jobs
WHERE SCHEDULE NOT LIKE 'Disabled'
ORDER BY 'Backup Server' DESC LIMIT 0,350
INTO OUTFILE 'C:/Temp/VeeamJobs.csv' 
FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"'

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×