How to Enable SSH Commands in Windows

Data

How to Enable SSH Commands in Windows

SSH (Secure Socket Shell) is a network protocol that can be used to securely access other machines across a network. From our perspective, using SSH can be valuable, especially if you’re looking to interact with Linux virtual machines such as Matillion servers. For example, SSH protocols could be used to:

  • Log into a Linux virtual machine
  • Copy files to/from a Linux virtual machine
  • Generate SSH keys that can be used for SSH authentication
  • Configure authentication to a remote Git repository without entering a password each time you push, pull, etc.

How to Enable SSH Commands in Windows 10

In Windows 10, SSH commands can be executed through PowerShell natively; however, the functionality must be enabled by following these steps:

Open the START menu and open Manage optional features:

Select Add a feature:

Search for SSH and install both the OpenSSH Client and the OpenSSH Server:

Restart your machine (or sign out and in again) to automatically add the set of SSH commands to your PATH environment variable. You should now be able to execute the ssh command from PowerShell:

If you see the usage message above, you can stop here and everything is set up. If not, you may have an error similar to the following:

If you see this error, keep reading to add the commands to your PATH environment variable directly.

Adding the OpenSSH Commands to Your PATH Environment Variable

Open the START menu and open Edit the system environment variables:

Select Environment Variables:

Select your Path system variable and select Edit:

Select to add a New variable and enter the location of the OpenSSH folder as a variable. By default, this should be C:\Windows\System32\OpenSSH. Then hit OK a few times to close the various menus:

You should now be able to execute the ssh command from PowerShell:

Congratulations! You now have a working SSH command that could be used to do a variety of things, as mentioned at the top of this post:

  • Log into a Linux virtual machine
  • Copy files to/from a Linux virtual machine
  • Generate SSH keys that can be used for SSH authentication
  • Configure authentication to a remote Git repository without entering a password

Check back next week for another post that builds upon this one!

More About the Author

Chris Hastie

Data Lead
Querying Stock Data with an API Query Profile in Matillion ETL Matillion ETL is a GUI-based orchestration and transformation tool for data movement that has many functionalities, including querying ...
Snowflake External Access: Retrieve Data from an API Recently, Snowflake released external access integrations into general availability. This allows Snowflake admins to create secure ...

See more from this author →

InterWorks uses cookies to allow us to better understand how the site is used. By continuing to use this site, you consent to this policy. Review Policy OK

×

Interworks GmbH
Ratinger Straße 9
40213 Düsseldorf
Germany
Geschäftsführer: Mel Stephenson

Kontaktaufnahme: markus@interworks.eu
Telefon: +49 (0)211 5408 5301

Amtsgericht Düsseldorf HRB 79752
UstldNr: DE 313 353 072

×

Love our blog? You should see our emails. Sign up for our newsletter!