Portqry Examples Extra Quality ◉

TCP port 80 (http) is LISTENING

Example:

portqry -n app01 -p tcp -e 443 if %errorlevel% equ 0 ( echo Service OK ) else if %errorlevel% equ 2 ( echo Firewall likely blocking ) portqry examples

portqry -n fileserver -p tcp -e 445 -smb TCP port 80 (http) is LISTENING Example: portqry

This is the most common use case—checking if a web server, SQL instance, or RDP port is open. portqry examples

If you are documenting a firewall change or sending logs to a vendor, piping the output to a text file is essential.