Failed to use System.Management.dll in Dot Net Core

How do I collect hardware information if System.Management.dllnot compatible with Dot Net Core .

How to get information about a computer, such as processor ID, disk number, etc.

+7
source share
2 answers

I am currently porting a Net Framework project that uses System.Managementto get information about hardware, and I have also reached a dead end because it is System.Managementnot compatible with Net Core.

, , Process.Start System.Diagnostics powershell , , Get-WmiObject Win32_BaseBoard | select SerialNumber, .

ifs, , OS Process.Start, , linux , dmidecode.

, A LOT SLOWER whem System.Management.

+3

.NET Core 3 System.Management. .NET Core 3 4 .

" NuGet..." "" Visual Studio, System.Management. , " ", .

System.Management :

Msgstr " [Out]..."

.

0

Source: https://habr.com/ru/post/1660602/


All Articles