Monday, April 20, 2026

Enable OpenSSH on Windows 11


  1. Step 1: Install OpenSSH Server

    You can do this via PowerShell (run as Administrator):

    1. Check if it's already available: Get-WindowsCapability -Online | Where-Object Name -like 'OpenSSH.Server*'

    2. If State is NotPresent, install it: Add-WindowsCapability -Online -Name OpenSSH.Server~~~~0.0.1.0

    Step 2: Start the Service & Set to Automatic

    Installation doesn't automatically start the "listener." Run these commands:

    1. Start the service: Start-Service sshd

    2. Set it to start whenever Windows boots: Set-Service -Name sshd -StartupType 'Automatic'

    Step 3: Verify the Firewall Rule Again

    Now that the server is installed, Windows should have automatically generated the rules. Run your original command again: Get-NetFirewallRule -Name *OpenSSH-Server* | select Name, DisplayName, Enabled

    It should now show OpenSSH-Server-In-TCP as True.


    Step 4: Final Connection Test

    Go back to your Oracle Linux (ol8) terminal and try to "poke" the port to see if the timeout is gone:

    nc -zv 192.###.##.98 22

    If it says "Connection refused" instead of "Timed out": This is actually progress! It means the network is open, but the service might need a restart. Restart-Service sshd

    If it still times out: Check if you have a third-party antivirus (like McAfee, Norton, or Quick Heal) installed on Windows. These often have their own "Stealth Mode" or firewalls that block Port 22 regardless of Windows' internal settings.

    Once you get a "Succeeded" or "Connected" message from the nc command, your sgpt command for SFTP should work immediately. Do you have any third-party security software running on that Windows 11 box?

No comments:

Post a Comment

Enable OpenSSH on Windows 11

Step 1: Install OpenSSH Server You can do this via PowerShell (run as Administrator ): Check if it's already available: Get-WindowsCapab...