keytool 不是 internal/external 命令、可运行的程序或批处理文件

keytool is not recognized as an internal/external command, operable program or batch file

当我使用命令时keytool -genkey -v -keystore MY-RELEASE-KEY.keystore -alias MY_ALIAS_NAME -keyalg RSA -keysize 2048 -validity 10000

我收到这样的错误 'keytool' is not recognized as an internal or external command, operable program or batch file. 我能做什么?

您需要导航到 C:\Program Files\Java\jdk_version\bin 并在那里执行请求