Files
TestRepo/PowerShell_SME_Command_Guide.md

2.9 KiB

PowerShell Commands for Support / SME / Helpdesk

Practical commands for Support Engineers and SMEs managing user issues, workstations, and basic troubleshooting.


Table of Contents

  1. Computer Information
  2. Network Troubleshooting
  3. Process and Application Issues
  4. Service Troubleshooting
  5. File Management
  6. Event Logs
  7. Remote Computer Access
  8. Useful Support Commands

1. Computer Information

Get-ComputerInfo
hostname
whoami

Check uptime:

(Get-CimInstance Win32_OperatingSystem).LastBootUpTime

2. Network Troubleshooting

Check IP:

Get-NetIPAddress
ipconfig

Ping test:

Test-Connection google.com

Check if port open:

Test-NetConnection server01 -Port 443

DNS lookup:

Resolve-DnsName google.com

3. Process and Application Issues

List processes:

Get-Process

Find application:

Get-Process chrome

Kill frozen app:

Stop-Process -Name chrome -Force

Start application:

Start-Process notepad

4. Service Troubleshooting

Check services:

Get-Service

Restart a service:

Restart-Service spooler

Check if running:

Get-Service spooler

5. File Management

List files:

Get-ChildItem

Copy files:

Copy-Item file.txt C:\Temp

Delete file:

Remove-Item file.txt

Read log file:

Get-Content log.txt -Tail 50

6. Event Logs

Recent system errors:

Get-WinEvent -LogName System -MaxEvents 20

Application errors:

Get-WinEvent -LogName Application -MaxEvents 20

7. Remote Computer Access

Connect remote PowerShell:

Enter-PSSession PC01

Run command remotely:

Invoke-Command -ComputerName PC01 -ScriptBlock { Get-Service }

Restart remote computer:

Restart-Computer PC01

8. Useful Support Commands

Check disk space:

Get-Volume

List logged in users:

quser

Find large files:

Get-ChildItem C:\ -Recurse |
Sort Length -Descending |
Select -First 10

Check installed updates:

Get-HotFix