How To: Test Port Connectivity Using PowerShell

How To: Test Port Connectivity Using PowerShell

How To Test Port Connectivity Using PowerShell Without The Need To Install Telnet Client


Objective

Traditionally, admins will install the Telnet Client on a Windows machine to test the ability to reach a port on another computer. The purpose of this article is to provide instructions on how to test connectivity to a specific port on another device using Powershell and without the need to install any additional software.

Instructions

  1. Open Powershell as Administrator
  2. In Powershell, use the following command:
  • Test-NetConnection -computername <ip, hostname or FQDN> -Port <port number>

Example: Test-NetConnection -computername V15AppServer1 -Port 443


GOOD EXAMPLE:


FAILED EXAMPLE