Close
  • Blog
  • About
×
×
  • Blog
  • About
Menu & Search
MSSQL DBA Blog
Category

PowerShell

PowerShell & Windows Admin Blog Archives, by Peter Whyte (SQL Database Administrator). Includes a lot of WSL posts & more...


How to Get and Set Evironment Variables with PowerShell
December 19, 2022
AWS
PowerShell
Windows
How to Set Environment Variables in PowerShell

To get environment variables in PowerShell, we can use Get-ChildItem env: to list all the environment variables and $env: to return the value of a specific environment variable.

Read More
SQL Server Management Studio Silent Install
September 14, 2022
PowerShell
SQL Server
SSMS Silent Install

This is a note on how to silently install SQL Server Management Studio (SSMS) via command (PowerShell).SSMS is a tool most people use to administer SQL Server and to run SQL queries.

Read More
PowerShell Delete Files in Subfolders
September 11, 2022
PowerShell
How to Delete Files in PowerShell

This is a post on how to delete files in PowerShell, which will be useful when you need to delete files as part of a script in Windows.

Read More
MSSQL
September 5, 2022
PowerShell
Windows
Create a New Firewall Rule with PowerShell

Create a New Firewall Rule with PowerShellThis is a short post to share a PowerShell script that will create a new Windows Firewall Rule on a local computer.

Read More
Check PowerShell Version
August 31, 2022
PowerShell
How to Check PowerShell Version

This post is a guide on how to check your PowerShell version on a Windows computer. I’m using $PSVersionTable to get this info.

Read More
Create Scheduled Task Windows PowerShell
August 28, 2022
PowerShell
Windows
How to Automate PowerShell Scripts with Task Scheduler

This post is useful if you need to run PowerShell Scripts automatically with a set schedule in Windows. In the demos below, we’re creating new Scheduled Tasks via GUI and with PowerShell.

Read More
SQL Server Default Port
August 26, 2022
PowerShell
SQL Server
Windows
SQL Server Default Port

The default port for the SQL Server Engine is 1433, which is a useful thing to know if you’re working as a Database Administrator (DBA) or Database Reliability Engineering (DBRE) type role.

Read More
PowerShell Restart Service Multiple Hosts
August 24, 2022
PowerShell
Windows
PowerShell Restart Services on Multiple Hosts

In this post, we’ll walk through a script that restarts services on multiple remote hosts using PowerShell. A single PowerShell command will be run on several computers at the same time.

Read More
PowerShell ForEach Get-ChildItem
August 22, 2022
PowerShell
PowerShell ForEach Loop Tutorial

Looping is a fundamental concept in PowerShell, and in programming in general. It’s needed for various situations where we need to work with one object at a time within an array/collection of objects.

Read More
Get-NetFirewallProfile
August 16, 2022
PowerShell
Windows
How to Check Windows Firewall Status with PowerShell

This post will help you to check your local Windows Firewall status using PowerShell (whether it’s off or on for each Profile).

Read More
1 2 3 … 5
Peter Whyte DBA

Peter Whyte

Blog Menu

  • Homepage
  • MSSQL DBA Blog
  • SSMS Tips
  • SQL Notes & Links
  • DBA Blog Archives
  • WSL Windows Tips
  • Projects

Categories

  • AWS (5)
  • Linux (34)
  • MySQL (5)
  • Postgres (7)
  • PowerShell (48)
  • RedShift (7)
  • SQL Server (78)
  • Windows (64)
  • WordPress (2)

Tags

Active Directory (AD) (4) AWS CLI (3) CDC (2) Certificates & Encryption (3) Change Data Capture (2) CSV Files (4) Database Admin (54) Database Backups (10) Data Types (2) Deleting Data (2) Error Messages (4) Featured (4) Git (11) Git Commands (4) Git Log (3) Installing SQL Server (10) Linked Servers (3) Linux Admin (2) Measuring Databases (9) MSSQL SPIDs (3) NetFirewallProfile (3) New-Item PowerShell (2) PowerShell Create Folder (2) PowerShell Delete Files (2) PowerShell ForEach (2) PowerShell Tips (20) PowerShell Version (2) Restoring Databases (7) SQL Server Agent (4) SQL Server ETL (2) SQL Server Management Studio (SSMS) (14) SQL Server Processes (6) SQL Server Scripts (3) SQL Tips (19) SSH (2) SSMS Tips (9) Temp DB (2) Windows Admin (21) Windows Firewall (4) WordPress Tutorials (2) WSL (22) WSL1 (4) WSL2 (4) WSL Ubuntu (6) WSL Version (4)