Powershell doesn't recognize openssl even after I added it to the system path

时间:2017-08-04 12:21:25

标签: powershell cmd openssl

I am on a 64bit Windows 10. I installed Win64 OpenSSL v1.1.0f and added the install directory C:\OpenSSL-Win64\bin to my system PATH. Upon running it in cmd or Powershell, I get:

openssl : The term 'openssl' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.

What else am I missing?

2 个答案:

答案 0 :(得分:7)

如果你在Powershell中运行它,请检查$ env:path以确保" C:\ OpenSSL-Win64 \ bin"在那里。以前的注释都引用了cmd.exe中的PATH变量,您的错误消息表明您没有使用它。

如果不是,请在Powershell中运行以下命令

$env:path = $env:path + ";C:\OpenSSL-Win64\bin"

答案 1 :(得分:0)

每当您更改env变量时,可能需要关闭会话并打开一个新的Powershell,它在当前会话中不起作用。