I have the following Powershell line to get information about the progress of HyperV merge and replication sync status on a Windows Server 2016 installation :
Get-WmiObject -Namespace "root\virtualization\v2" -Query "select * from Msvm_ConcreteJob" | select name,PercentComplete
My issue is it often returns a blank line when it should return a value as I know its doing something. So for instance if HyperV is doing a replication resync I run the command and it shows me the percentage complete:
If I run it again it often returns a blank line, if I leave it a minute or so then run it again I get a result but often with more information:
WMI/CIM consists of a bazillion little underlying "providers." Those providers are responsible for sticking data into the repository and responding to queries; in this case, the provider appears to be Not Well Written. It's likely related to Hyper-V's management architecture, but there's not much you can do in terms of gaining insight or fixing it.