Use PowerShell to format port query (PortQry) output

Recently I had to check connectivity to several servers on some specific ports using PortQry. As some of you already know this command will return some kind of the connectivity test report. I wanted to convert this into nice formatted table. Port Query Port Query – Display the status of TCP and UDP ports, troubleshoot TCP/IP connectivity and security, return LDAP base query info, SMTP, POP3, IMAP4 status, enumerate SQL …

Use PowerShell function to check if servers are accessible

Recently I had to check quickly if all of managed servers are accessible. As SCOM monitoring wasn’t set yet in my environment I had to create simple script to do that. One of the easiest method to check if server is up is to test availability of network share. Test-Path There are many ways to check if server is accessible like for example using ping, checking some specific service but …

Test LDAP Connection with PowerShell

In this article you will find out how to test LDAP Connection to your domain controllers. It is very similar to previous post about Test-PortConnection function. In this example we will focus on making an LDAP connection using ADSI. On the beginning of function we need to check if DC name provided as a parameter is valid: Usage: Final script: