1.This PowerShell script lists all running processes where CPU time exceeds 100 seconds. It’s useful for identifying resource-hoging applications on a system.

Get-Process: retrieves a list of all active processes. Where- Object {$_.CPU -gt 100}: Filters the processes to only show those using more than 100 seconds of CPU time.


Get-Process | Where-Object {$_.cpu -gt 100}

2. This script lists all Windows services that are curently stopped. It is useful for identifying services that failed to start or are disabled.

Get-Service | Where-Object { $_.Status -eq 'Stopped'}

3. This PowerShell script retrieves the BIOS version information from your system. Helpful for inventorying, troubleshooting, or confirming firmware updates.

Get-WmiObject -Class Win32_BIOS | Select-Object SMBIOSBIOSVersion, Manufacturer, ReleaseDate

4. Check if a user exists in Active Directory

Get-ADUsern -Identity username

5. List locked out AD users

Search-ADAccount -LockedOut | Select-Object Name, SamAccountName

6. Force password reset for a user

Set-ADAccountPassword -Identity username -Reset -NewPassword (ConvertTo-SecureString "NewP@ssword!" -AsPlainText -Force)

7. Check installed Ram

Get-CimInstance Win32_ComputerSystem | Select-Object TotalPhysicalMemory

8. Check last update install date

Get-HotFix | Sort-Object InstalledOn -Descending | Select-Object -First 1

9. List installed printers

Get-Printers

10. Check disk space

Get-PSDrive -PSProvider 'FileSystem'

11. Restart a Windows service

Restart-Service -Name "Spooler"

12. Find high CPU processes

Get-Process | Sort-Object CPU -Descending | Select-Object -First 5

13. Test internet connection

Test-Connection -ComputerName 8.8.8.8 -Count 2

14. Get IP address of local machine

Get-NetIPAddress | Where-Object {$_.AddressFamily -eq "IPv4" -and $_.PrefixOrigin -ne "WellKnown"}

15. Flush DNS

Clear-DnsClientCache

16. Force check for updates Windows 10+

UsoClient StartScan