Samk13 / powershell-notes

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Powershell commands

Get motherboard model

Get-WmiObject win32_baseboard | Select-Object -Property Product

Get the maximum capacity of the MB RAM in GB

Get-WmiObject -Class Win32_PhysicalMemoryArray | Select-Object -Property @{Name="MaxCapacityGB";Expression={$_.MaxCapacity / 1MB}}

Get the current RAM installed

 Get-WmiObject -Class Win32_PhysicalMemory | Measure-Object -Property Capacity -Sum | Select-Object @{Name="TotalGB"; Expression={ $_.Sum / 1GB }}

Get the list of connected storage devices

 Get-PhysicalDisk | Select-Object MediaType, BusType, Model

Get the current graphic driver version

Get-WmiObject Win32_VideoController | Select-Object Name, DriverVersion
# or
Get-WmiObject Win32_VideoController | Select-Object -Property Name, DriverVersion
Name                          DriverVersion
----                          -------------
NVIDIA GeForce RTX 4090 SUPER 31.0.15.4633
```

# Windows issues

## Windows security not openening 
- Open Command Prompt and execute:
```powershell
sfc /scannow
DISM /Online /Cleanup-Image /RestoreHealth
```

About