gopsutil icon indicating copy to clipboard operation
gopsutil copied to clipboard

Using host.HostID() on the Windows platform The uuid obtained is different from the cmd `wmic csproduct get uuid`

Open kakj-go opened this issue 2 years ago • 2 comments

Is your feature request related to a problem? Please describe. Using host.HostID() on the Windows platform The uuid obtained is different from the cmd wmic csproduct get uuid

Describe the solution you'd like add method host.MachineCode(), this method use cmd wmic csproduct get uuid to get uuid

Additional context image

host.HostID() return b418a861-8693-4e57-904a-448e0451ab7b

kakj-go avatar Nov 28 '23 03:11 kakj-go

How did you solve it in the end?

futurecad avatar Apr 16 '24 06:04 futurecad

I think the two methods of obtaining are different. If you use the cmd method, there will be some vmic that does not exist.

futurecad avatar Apr 16 '24 06:04 futurecad