How to check if a Hyper-V machine is Windows or Linux?

Viewed 1088

I'm building a table with information about Hyper-V machines that I have on my PC.

I got most information from Powershell commands, namely using

Get-VM | Where {$_.Id –eq '" + vm["Name"].ToString() + "'} | fl *

and Msvm_ComputerSystem queries.

I can get my own operating system using

Get-CimInstance Win32_OperatingSystem | Format-List Caption

but how can I get the Hyper-V virtual machine operating system (it would suffice to know if it's Windows or Linux)?

Update

I've tried installing different Windows and Linux distributions (XP, Vista, Debian, Mint and Sparky), then went to check the Hyper-V VMCX file looking for some kind of pattern in them, but couldn't find any either. Besides it's pretty hard to scan through all that "gibberish" on notepad. It does have a bunch of information and maybe it's somewhere hidden in there, does anyone know how to properly read these files? Could be a way to solve the problem.

0 Answers
Related