Veeam v9 – My Veeam Report v9.0.1

Find the latest version here.

Once again Veeam has released a new version (v9) and with that comes a new version of My Veeam Report! There are some very interesting new features in this release, with my favorite so far, being the remote console. Let’s take advantage of that, shall we?

The majority of this update was to simply ensure compatibility with VBR v9 so not all new features are covered (yet). Having the ability to use a remote console and the addition of the Connect-VBRServer cmdlet was too tempting…that had to happen, and did. You now have the ability to run/schedule the report on a workstation with only the console installed – very nice. As this allows the script to run from one location but target multiple VBR servers, I’ve included the ability to add the VBR server name to both the report title as well as the email subject. Note the script can only run against a single VBR server at a time – though you could schedule multiple reports configured for different servers. One implication that this had was on the gathering of the license/support info which comes from the registry of the VBR server. I decided to go with a simple WMI call to get the value, which means the user running the script remotely will need full access to the VBR server for this to work.

Another big addition to the family was the missing properties for repository info (total space/free space). This as you may be aware, was a huge thorn in my side and am very happy Veeam has implemented them. This means no more guessing or diving into the database to retrieve this info – much more streamlined and much more accurate. Though I have no way to test myself, I am hoping this will help folks with fancy storage like DataDomains as well (please let me know).

You may have noticed a jump in version for MVR (My Veeam Report).  I’ve decided to keep inline with Veeam here as to avoid confusion in the future which version you should run against your environment. The new format is as follows –
VeeamMajorVersion.VeeamUpdateVersion.MVRVersion. That puts us currently at v9.0.1.

I will note one issue I had with v9 – Endpoint jobs do not return the correct Next Run date/time. This has been submitted to Veeam and should be fixed in the near future.

A few other small bits of polish and we are off and running with v9!

Here’s a list of the included changes:

  • Initial version for VBR v9
  • Updated version to follow VBR version (VeeamMajorVersion.VeeamUpdateVersion.MVRVersion)
  • Fixed Proxy Information (change in property names in v9)
  • Rewrote Repository Info to use newly available properties (yay!)
  • Updated Get-VMsBackupStatus to remove obsolete commandlet warning (Thanks tsightler!)
  • Added ability to run from console only install
  • Added ability to include VBR server in report title and email subject
  • Rewrote License Info gathering to allow remote info gathering
  • Misc minor tweaks/cleanup

Here’s a list of the requirements:

  • Veeam v9
  • PowerShell v2
  • VMware Infrastructure hosting VMs

Script can be downloaded from here.

65 thoughts on “Veeam v9 – My Veeam Report v9.0.1

  1. Alan Kreifels

    Love the new version Shawn, one more little buggy – under the Proxy Details, all of mine (3) are showing the same ip address as the vbr server.

    1. smasterson Post author

      You are correct – good catch
      I’ve updated the gist

      Issue was on line 371:
      $DNS = [Net.DNS]::GetHostEntry(“$($inputObj.Host.RealName)”)
      Should be:
      $DNS = [Net.DNS]::GetHostEntry(“$($inputObj.Host.Name)”)

      1. Andreas

        for me all proxies still showing the ip address of the vbr
        the result is that all proxies are alive (which is not correct because two are down)

      2. Andreas

        yes I did – result is:

        Proxy Name Proxy Host Disabled IP Address RT (ms) Status True 0 Alive True 0 Alive False 0 Alive
        Backup Proxy esxbck01 False 0 Alive

      3. Andreas

        yes, because they are in a separate backup-network and these ip-addresses are not maintained in the DNS …

      1. Preston Goh

        Hi. Shawn, do you have version contain tape backup job result?
        I’m using cmdlet “Get-VBRTapeJob” and replaced “Get-VBRjob” to get tape backup.

        1. smasterson Post author

          Unfortunately, I don’t have access to tape and therefore cannot test. I would be happy to include if someone wanted to come up with the bits.

  2. Mark Lavrijsen (@yomark1)

    Seems to be working great with v9. Thanks Shawn!!

    For the people also using replica’s, change under “# Gather Backup jobs” the line to:
    $allJobsBk = @(Get-VBRJob | ? {$_.JobType -eq “Backup” -or $_.JobType -eq “Replica”})

    Change the line starting with “foreach” under “# Get Backup session information” to
    Foreach($job in (Get-VBRJob | ? {$_.JobType -eq “Backup” -or $_.JobType -eq “Replica”})) {

    Change line starting with “$runningSessionsBk =” under “# Get Backup session information” to:
    $runningSessionsBk = @($allSesh | ?{$_.State -eq “Working” -and ($_.JobType -eq “Backup” -or $_.JobType -eq “Replica”)})

    This will include some basic replica job status in the report. Of course it’s also niuce to do some cosmetic changes to the report as well(so that replica info is also included in the header etc.. ), but I leave that up to you.

    1. smasterson Post author

      I haven’t yet had a chance to look at scale-out repositories – when I do, they’ll be added
      Backup Copy, Replica and SureBackup jobs have not yet made it into the report

      1. Oliver Smart

        Good Morning, Firstly, Excellent script! Thank you, it has made the daily monitoring far easier. Would it be possible to add the Backup Copy feature to this? It is the only bit that is missing for us. We would all be most grateful Sir 🙂

  3. z3r0

    Hi, is there any possibility to add the “Backup Start- and Endtime” to the “VMs with Successful Backups” Section?

    I need a report, where each VM Backup Start and Endtime is reported, and not only the Backupsession.

    Thank you

  4. Alex


    I tried running this report, getting the following errors:

    Attempted to divide by zero.
    At C:\Veeam_reports\MyVeeamReport.ps1:452 char:29
    + $objoutput = New-Object -TypeName PSObject -Property …
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : NotSpecified: (:) [], RuntimeException
    + FullyQualifiedErrorId : RuntimeException

    Report is version 9.01 and using Veeam 9.0


      1. Alex

        Thanks for the response, I’ll have to take a look. In the meantime, the report still gets emailed even though I get that error, thanks for publishing that!

  5. Pingback: Veeam PRTG Sensor Reloaded | my cloud-(r)evolution

  6. chad markley

    The script looks great but I am having an issue and I can’t figure out where the problem lies. I made the changes pertinent to my system but when I run the script I am getting a “SOAP” login error. This looks like it is trying to hit my ESX cluster/server, but I can’t find where that varible is being set. I am specifying my VBR server as an IP address and not a hostname, but the error is giving me the name of my VBR server. Anyhow, my question is, what is the script trying to log into via SOAP on port 443??
    WARNING: System.Exception: Failed to login to “servername” by SOAP, port 443, user “domain\admin”, proxy srv: port:0
    —> System.Net.WebException: Unable to connect to the remote server —> System.Net.Sockets.SocketException: No

    Just need help hunting down where my issue is. Thanks again for all the hard work on this

    1. smasterson Post author

      The only ‘connection’ that is made is PowerShell connecting to the VBR server (whether local or remote).

      Try running the following commands and see if any errors are produced. Replace the server parameter if not running on the VBR server itself (remote console install).

      Add-PSSnapin “VeeamPSSnapIn” -ErrorAction SilentlyContinue
      Connect-VBRServer -server localhost

        1. smasterson Post author

          Hmmm that one is strange…

          The only other connection that I can think of would be VBR querying the vCenter for objects.
          Try this out and see if you get any errors:

          Add-PSSnapin “VeeamPSSnapIn” -ErrorAction SilentlyContinue
          Connect-VBRServer -server localhost

    1. smasterson Post author

      I would check the connection details for server hdc-backup within VBR – it appears to not be configured correctly. When VBR tries to access it, it pukes.

  7. Diego Cunha

    Hi Shawn! Very nice script. Thanks a lot for your work.
    I have one question: The filter gets the items based on the VAPP NAME, and I needs to get trough the VM NAME.
    There is a way?
    Thanks in advance!

    1. smasterson Post author

      Hi Diego

      Glad you enjoy the script!
      Can you give me a few more details on what you are trying to accomplish and what you are actually seeing as a result?

  8. Paul

    Hey Shawn,
    Thanks so much for this script, it is incredibly awesome and I was using your previous one too.

    I’ve tweaked it for my environment so thought I would share the changes in case you wanted to incorporate any of them. Mainly this is because we have 6 Backup servers and I would like to only have 1 script file to maintain and run it remotely now that Veeam has that ability.

    -Added parameters for servername, SentTo, RegionCode, Exclusions folder
    -Collect the exclusions from text files (we sign scripts that run as scheduled tasks so I don’t want to have to resign each time we exclude a VM or folder, these are based on a text file in the Exclusions folder with RegionCode in the name, passed as a parameter)
    -Compare times in UTC (as we are over 3 timezones we need the script to base all time calculations on UTC to get the correct last 24 hours, the actual email still shows the local time)
    -Added a section for Running and Failed Backup Copy jobs, I thought that was in your old one but this versions on checks for Backup jobs, I kept them in separate sections so the failures don’t get confusing (we are a lot more concerned about Backup Jobs failing than a Copy which sometimes takes a couple of days)

    Anyway, thanks again.

    1. smasterson Post author

      Hi Johannes
      Glad you find the script useful 🙂
      At this time there is no way to filter by cluster, there used to be but I haven’t seen a reliable way for Veeam to be able to tell the difference between a host and a cluster.

  9. Nick Paolini

    Hey Shawn,
    Great work on your script.
    It works great except, my output for “VM’s with No Successful Backups” looks like it lists every backup job. But “Backup Job Status” shows 65 successful backups. Could I have something going on in my backup jobs or the script?

    Best regards

    1. smasterson Post author

      I would ensure the vcenter(s) in the script matches the name of vcenter within VBR – sounds like the script is not able to get a list of successfully backed up VMs.

  10. Joe

    Shawn – Thanks for this great script. It really is a great tool.

    Question – A few versions ago, I had my vCSA become damaged and I needed to restore it from the host. This was done by logging into the VM on the host and adding the IP address of the host to Veeam thus making it (what its called in V9) Managed Server.

    The report is providing everything perfectly. Here’s my problem.

    VM-A on vCSA backed up normally shows up as backed up every night.

    However, if that same VM-A is hosted on an ESXi host that is also setup as a “Managed Server”, that same VM-A is displayed as a failed backup.

    The only difference is that the vCenter of the failed (VM-A) backup is the IP address of the Host and the vCenter of the successful (same VM-A) backup is the IP address of my actual vCSA.

    I looked around and did not see an area to exclude a vCenter IP.

    Any suggestions – Thanks again for such a great script.

    1. smasterson Post author

      Hi Joe
      Thanks for the kind words – glad you’ve found the script helpful!
      I’ve actually run across this issue myself. The issue you are describing is due to VM-A having two identities (ID’s) – one in vCenter and the other on the host itself. So though it is the same ‘VM’, VBR (or any other software) is going to view them as two separate entities.
      The easiest answer is to remove the host from VBR (as a Managed Server). This could easily be added again in the future if needed (let’s hope vCSA doesn’t need to be restored again!).
      Another option may be to include the -Server parameter on the Get-VBRViEntity command within the Get-VMsBackupStatus function. Theoretically, this would tell VBR to only look at certain vCenters/Hosts as opposed to all it can ‘see’. I say theoretically as this would need further testing to be proven true.


  11. Paul Salwey

    Would we be able to tweak this to exclude a job entirely? I’ll admit I’m not the “Veeam guy” at my work but I’m trying to help get some reliable reporting. This script is amazing, but if you run a 48hr report, it will show servers that are backed up weekly as “failed” because a backup did not happen in the last 2 days, which is expected in those cases.

    I can exclude folders, but the issue is that under VSphere “weekly” job folders people have put “Bob’s Servers” for organizational purposes and the script does not ignore the nested folders in addition to the ignored root “weekly” folder – if I were to exclude that folder name as well, presumably it would exclude all “Bob’s Servers” folders even if they are under a Daily job. My options are either to make people remove those folders or rename them, or to try to exclude the “weekly” job entirely.

    Hope that makes sense. Keep up the great work!

  12. Dominic Herrmann

    Shouldn’t it be possible to realize his request with this command?
    $allSesh = Get-VBRBackupSession | where { $_.JobName -notlike “*$customer*”}

    I modified this awesome script to my needs:

    My Report has a filter for each customer, we baclup with veeam.
    We have a search String which matches both, VM Name in vSphere and Backupjob Name.
    Backupjob_Customer1_daily (veeam)

    I get a filtered report for each customer including the VM Backup start and Endtimes. So i think it should be possible to exclude some Jobs and VMs.

  13. Simon Jackson

    Can you possibly add additional exclusion based on the job name (also supporting wildcards)?

    These are great options; but unfortunately this may result in management job (and subsequently VMs) becoming visible to a client-specific backup report. I just don’t want this to raise questions months down the line.
    $excludeVMs = @(“”)
    $excludeFolder = @(“”)
    $excludeDC = @(“”)

    Awesome report though – have been using it for a few years now!

  14. Larry Walker

    first thanks
    When we have an enterprise server any way to pull the list of $vbrServer(s) and run this combining them all?

      1. Larry Walker

        have it mostly working . made a server array and one for loop for the whole #region NonUser-Variables region. Main issue is with the Get-VMsBackupStatus just some VMs get missed but made a dirty work around.

        thanks for your work.

        1. smasterson Post author

          It is an interesting idea. I’m curious as to how many VBR servers you have?
          It would be pretty simple to just create 4-5 copies of the script for 4-5 servers…I suppose if you had 10+ it could get annoying.

  15. Larry Walker

    We have four vmservers. The sections I have working with the for each server loop are
    Successful Backup Sessions
    Repository Details
    Backup Sessions with Warnings or Failures
    Backup Job Status
    VMs with Successful Backups
    VMs with No Successful Backups – ugly fix 🙂

    Need to add tape and replica’s

    most of your code just worked by appending the arrays from each servers get commands.

    will send you the code if you don’t judge it. just private email me.

    1. smasterson Post author

      I suppose there is a benefit to receiving one report as opposed to four.
      As my code is pretty sloppy at best (don’t judge), I wouldn’t be surprised if there are variables that need to be reset during each loop that are not properly reset now.

      Support for replication, backup copy and SureBackup jobs as well as (very) minor tape support coming very soon.

      1. Larry Walker

        The enterprise report we now get dosn’t show where the issue is. We get the totals but not the info we get with your. If you are doing tape I will wait and not add it in. The one report shows VMs that are really not backed up while four reports didn’t without excluding VMs.

  16. Tom

    Would someone be willing to suggest which part(s) of this script I could “borrow” for a simple daily report containing: VM name, data backed up daily, and the repository data??
    I only need this information on a daily basis to ascertain backup growth over time.
    Thank you, Tom

  17. Pingback: Veeam PRTG Sensor Reloaded - my cloud-(r)evolution

  18. Jason

    Thank you so much for your fine work, Shawn! I’ve been using your script for months and love it. I came back today to get the latest version in hopes that it would have replication and tape support and am very happy that you are planning on adding that in soon. Keep up the good work!

  19. Fiede

    Hello Shawn,
    at first a big thank u for your amazing work, but i need ur help.
    it is possible to expand the query up to 60 days?
    if its possible can u pls explain how?

  20. Remi Hornung

    I’m having some SMTP trouble maybe you can help?

    Exception Calling “Send” with “1” Argument(s): “Failiure sending mail.”
    At C:\Scripts\Veeamreport-Daily.ps1:3644 char:3
    + $smtp.send($msg)
    + ~~~~~~~~~~~~~~~~~~
    + CategoryInfo : NotSpecified: (:) [], MethodInvocationExcetion
    + FullyQualifiedErrorId : SmtpException.

    1. smasterson Post author

      This appears to be an issue with your SMTP server – ensure it allows relaying using the credentials used to run the script (or specified, though I’d not be a fan of hard coding the creds into the script itself).

  21. Daniel

    Great report, but for me the layout is broken. The colums are way to large, width does not fit a browser window. I have to scroll ages to the right. Any way to correct that?


Leave a Reply

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