Install Open SSH on Windows with Chocolatey

While Windows PowerShell does come with Remote PowerShell it can be a bit cumbersome to work with. I find SSH to be far simpler in multi-OS environments. (If you're a pure Windows shop, consider sticking with Remote PowerShell).

Setting up SSH is on Windows is now easier then ever with the Chocolatey repository.

#To install Chocolatey - from elevated PowerShell Prompt
iwr -UseBasicParsing | iex

#To install openssh with ssh daemon
choco install openssh -params '"/SSHServerFeature"' -y

At this point you should be able to ssh from this machine and to this machine

#To connect to another ssh server from the host with ssh installed
ssh remoteserverip or hostname

To connect to this Windows machine, use your preferred ssh client and login as a user with local admin on the machine. i.e. ssh adminstrator@windowsmachineip

Now, optionally you can setup SSH key authentication.
#To enable ssh keyauth
Restart Windows

#To setup ssh keys
cd ~
ssh-keygen.exe -t rsa -f id_rsa
copy .ssh\authorized_keys

Now you should be able to login as this user with the private key. If you're not at least familiar with public/private key setup, I recommend starting with that first.


Popular posts from this blog

Active Directory Authentication with an Oracle Database

Create a custom backup report with BI Publisher for Oracle Enterprise Manager/Cloud Control 13c

Oracle Enterprise Manager notify when Recovery Area low