-
- Novice
- Posts: 9
- Liked: never
- Joined: Jan 23, 2025 10:55 am
- Full Name: Silent
- Contact:
List VMs in VBR
Hello,
I'm trying to obtain a list of VMs that my connected hypervisor in VBR has.
For VMware you can use Find-VBRViEntity - this works well.
Now.. I got other hypervisors connected to a VBR server - this regards Proxmox and Nutanix.
These hypervisors work with VBR, they do backup, show VMs etc. in VBR GUI (Inventory -> Virtual Infrastructure).
Since there is no Powershell command for getting the list of VMs on those hypervisors I am looking into static methods. (I'm aware that these are not supported)
This is the path where the plugins for "PVE" (Proxmox) and "Nutanix AHV" are located in:
C:\Program Files\Veeam\Plugins
The Proxmox extension looks like it can be of help to add the assembly to Powershell for using methods/classes from it:
Veeam.Backup.Extensions.Proxmox.dll
Class: CInfrastructuresProvider
Methods: GetHierarchyAllVirtualMachines , GetVmsHierarchyView
(similar to getting ALL backup jobs using [Veeam.Backup.Core.CBackupJob]::GetAll() from VBR)
Did anyone figure out how to retrieve the VMs hosted by the connected hypervisor that is connected to VBR or can at least contribute?
I'm trying to obtain a list of VMs that my connected hypervisor in VBR has.
For VMware you can use Find-VBRViEntity - this works well.
Now.. I got other hypervisors connected to a VBR server - this regards Proxmox and Nutanix.
These hypervisors work with VBR, they do backup, show VMs etc. in VBR GUI (Inventory -> Virtual Infrastructure).
Since there is no Powershell command for getting the list of VMs on those hypervisors I am looking into static methods. (I'm aware that these are not supported)
This is the path where the plugins for "PVE" (Proxmox) and "Nutanix AHV" are located in:
C:\Program Files\Veeam\Plugins
The Proxmox extension looks like it can be of help to add the assembly to Powershell for using methods/classes from it:
Veeam.Backup.Extensions.Proxmox.dll
Class: CInfrastructuresProvider
Methods: GetHierarchyAllVirtualMachines , GetVmsHierarchyView
(similar to getting ALL backup jobs using [Veeam.Backup.Core.CBackupJob]::GetAll() from VBR)
Did anyone figure out how to retrieve the VMs hosted by the connected hypervisor that is connected to VBR or can at least contribute?
-
- Veeam Software
- Posts: 2846
- Liked: 654 times
- Joined: Jun 28, 2016 12:12 pm
- Contact:
Re: List VMs in VBR
Hi Silent,
I've not tried to poll for this information, but I'm going to guess you'll hit a wall trying to go through the extensions DLLs -- I have not tried it, but just have a feeling we'll hit a dead-end with .net reflection.
I will try to find a way a bit later, I suspect we'll need to go through [Veeam.Backup.DBManager.CDBManager]::Instances to find this, I'm just not sure what instance it's under at the moment.
Will update once I get a chance to poke around in this class.
I've not tried to poll for this information, but I'm going to guess you'll hit a wall trying to go through the extensions DLLs -- I have not tried it, but just have a feeling we'll hit a dead-end with .net reflection.
I will try to find a way a bit later, I suspect we'll need to go through [Veeam.Backup.DBManager.CDBManager]::Instances to find this, I'm just not sure what instance it's under at the moment.
Will update once I get a chance to poke around in this class.
David Domask | Product Management: Principal Analyst
-
- Novice
- Posts: 9
- Liked: never
- Joined: Jan 23, 2025 10:55 am
- Full Name: Silent
- Contact:
Re: List VMs in VBR
Hi David,
thank you for looking into this.
About the .NET reflection - sending a command (e.g. Get-VBRLicense) and piping it to Out-Null does load all .NET dependencies so the static methods from DLLs work.
I scoured the named DLL but the classes/methods I found and tried did not result with the information I'm trying to get - just wanted to ask for some hive intelligence and hopefully an answer or at least a hint that points me towards the right direction.
I'll have another run at it but will also be looking forward hearing from you!
PS: A few weeks back when I was looking into this very actively I stumbled upon some methods that contained "cache" in their names - there were 3 functions in total which were related to each other.
I need to look it up again but I guessed that it could be of help.
What I can remember is that I figured out that Veeam B&R talks to the Proxmox API and queries VMs etc. and "caches" that information in VBR. <- that's where I need to step in and fetch some infos for my project. Otherwise I need to write an API handler for each product which you guys already have done so I can rely on your expertise and work.
thank you for looking into this.
About the .NET reflection - sending a command (e.g. Get-VBRLicense) and piping it to Out-Null does load all .NET dependencies so the static methods from DLLs work.
I scoured the named DLL but the classes/methods I found and tried did not result with the information I'm trying to get - just wanted to ask for some hive intelligence and hopefully an answer or at least a hint that points me towards the right direction.
I'll have another run at it but will also be looking forward hearing from you!
PS: A few weeks back when I was looking into this very actively I stumbled upon some methods that contained "cache" in their names - there were 3 functions in total which were related to each other.
I need to look it up again but I guessed that it could be of help.
What I can remember is that I figured out that Veeam B&R talks to the Proxmox API and queries VMs etc. and "caches" that information in VBR. <- that's where I need to step in and fetch some infos for my project. Otherwise I need to write an API handler for each product which you guys already have done so I can rely on your expertise and work.
-
- Veeam Software
- Posts: 2846
- Liked: 654 times
- Joined: Jun 28, 2016 12:12 pm
- Contact:
Re: List VMs in VBR
You're welcome, though regrettably I must tell I was not able to make any headway. The non-VMware and HyperV hypervisors are connected via a specific API and VBR queries this API in the background to pull information from the connected hypervisors, and you're correct there is some local caching done to avoid constantly polling the hypervisors.
However, I'm not really able to find a way to poll this at this time via static methods.
Unfotunately here we'll need to wait until we have full support via our automation endpoints for Proxmox, Nutanix, etc., I'm not sure we're going to find a manageable solution even with unsupported methods.
However, I'm not really able to find a way to poll this at this time via static methods.
Unfotunately here we'll need to wait until we have full support via our automation endpoints for Proxmox, Nutanix, etc., I'm not sure we're going to find a manageable solution even with unsupported methods.
David Domask | Product Management: Principal Analyst
-
- Novice
- Posts: 9
- Liked: never
- Joined: Jan 23, 2025 10:55 am
- Full Name: Silent
- Contact:
Re: List VMs in VBR
Hi David,
are there any news to this topic? (I paused this to see if anything changed in the meantime with you)
The only way I found was this: [Veeam.Backup.Core.CHierarchyObjloader]::GetObjs($VBRServers[0])
$VBRServers[0] in my case was a proxmox cluster.
I have 2 proxmox hosts - the first one does not return any VMs using this method (even though there are 8 running on that node), that's why I pulled infos from the cluster.
I get a list of VMs but it contains some duplicates as well as a few VMs missing completely in the list.
are there any news to this topic? (I paused this to see if anything changed in the meantime with you)
The only way I found was this: [Veeam.Backup.Core.CHierarchyObjloader]::GetObjs($VBRServers[0])
$VBRServers[0] in my case was a proxmox cluster.
I have 2 proxmox hosts - the first one does not return any VMs using this method (even though there are 8 running on that node), that's why I pulled infos from the cluster.
I get a list of VMs but it contains some duplicates as well as a few VMs missing completely in the list.
-
- Veeam Software
- Posts: 2846
- Liked: 654 times
- Joined: Jun 28, 2016 12:12 pm
- Contact:
Re: List VMs in VBR
Hi Silent,
Not at this time regrettably. There are naturally plans to extend support for both Powershell and the REST API to cover this, but nothing new to share aside from the above. Will update the thread when there is information to share.
Thanks!
Not at this time regrettably. There are naturally plans to extend support for both Powershell and the REST API to cover this, but nothing new to share aside from the above. Will update the thread when there is information to share.
Thanks!
David Domask | Product Management: Principal Analyst
-
- Service Provider
- Posts: 607
- Liked: 155 times
- Joined: Apr 03, 2019 6:53 am
- Full Name: Karsten Meja
- Contact:
Re: List VMs in VBR
get-vm -computername hyper-v
Who is online
Users browsing this forum: Semrush [Bot] and 3 guests