Tag: Windows Admin

  • 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. This post covers the following:# PowerShell: Delete a File# PowerShell: Delete a Folder# PowerShell: Delete Files in Subfolders Recursively PowerShell:…

    Read More


  • How to Check PowerShell Version

    This guide explains how to check your PowerShell version on a Windows computer using the $PSVersionTable command. Running the latest PowerShell version ensures access to new features and cmdlets. Some scripts may rely on commands not available in older versions, causing compatibility issues. We should keep it up-to-date…

    Read More


  • How to Automate PowerShell Scripts with Task Scheduler

    Running PowerShell scripts on a schedule is a common requirement for Windows Admins. This guide will show you how to automate your scripts using Task Scheduler, covering both the GUI and PowerShell methods. Task Scheduler allows you to run programs, scripts, or other tasks based on a schedule…

    Read More


  • SQL Server Default Port

    The default port for the SQL Server Engine is 1433, which is a key thing to know if you’re working as a Database Administrator (DBA), especially when managing network configurations or troubleshooting connectivity issues. In my experience, SQL Server runs on port 1433 about 95% of the time.…

    Read More


  • Restart Services on Multiple Hosts using PowerShell

    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. If you need to run a command on multiple remote machines, the PowerShell Invoke-Command cmdlet is a…

    Read More


  • How to Rename a Computer that Hosts SQL Server

    When changing the hostname of a computer that is running SQL Server, we have to update system metadata so that remote connections and applications do not lose connectivity. This guide provides a clear, step-by-step approach to updating SQL Server metadata after a hostname change. This is more often…

    Read More


  • How to Check Listening Ports on Windows

    This guide will show you how to check which service is running on a specific TCP or UDP port on a Windows computer. This can be useful for verifying which service is tied to a port or proactively checking for any dodgy (suspicious) open ports. In this post,…

    Read More


  • How to Check Windows Firewall Status with PowerShell

    Want to quickly check whether your Windows Firewall is enabled or disabled? This guide shows you how to use PowerShell to get the status of your local Windows Firewall for each profile. PowerShell cmdlets follow a standard format: verb-noun. The verb describes the action, and the noun specifies…

    Read More


  • How to Enable Windows Firewall using PowerShell

    Windows Firewall is an essential security feature that protects your system from unauthorized access and threats. If it has been disabled for testing or mistakenly turned off, you can quickly re-enable it using PowerShell. This guide provides a straightforward process to restore your firewall settings and ensure a…

    Read More


  • How to Disable Windows Firewall with PowerShell

    This post provides a demo on how to disable Windows Firewall with PowerShell on a Windows computer. ⚠ Important: Disabling the Windows Firewall is not recommended as it reduces your system’s security. However, there are scenarios, such as troubleshooting, where temporarily disabling the firewall may help identify if…

    Read More