LoginSignup
12
8

More than 5 years have passed since last update.

javaコマンドでjava.dllがどうこうってエラーが出た

Last updated at Posted at 2014-09-27

おそらく、色々ある事象のうちの一つです。

前提

OSはwindows8.1。
jreインストールしてある。

事象

コマンドラインからjavaコマンドを叩くと、下記エラーが出る。

Error opening registry key 'Software\JavaSoft\Java Runtime Environment'
Error: could not find java.dll
Error: could not find Java SE Runtime ENvironment.

原因

何故かC:\Windows\System32にjava.exeが入っており、
PATHのjava設定よりSystem32設定のほうが前に来ていたため、
javaコマンドはSystem32フォルダのjavaを実行しに行っていた。

そして、そこにjava.dllはなかった。

なんでSystem32に入っていたかは謎です。。

12
8
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
12
8