Monday, May 1, 2017

Error: Which: no javac in (/sbin:/bin:/usr/sbin:/usr/bin) when installing a Plugin for Logstash

This took me down a rabbit hole, but ended up being an easy solution.

The solution was, in addition to the JRE environment, I had to install the JDK as well.

If you do both and still have the issue, ensure you have the path variable in your profile.

Mine is as such:

JAVA_HOME=/usr/java/jre1.8.0_131
PATH=$JAVA_HOME/bin:$PATH
export PATH JAVA_HOME

Check your profile. I did so by sudo nano /etc/profile

added those lines just about the "pathmunge ()" line

When I only had the JRE installed, if I ran "which javac" I'd receive a path error. After installing the JDK, that command worked successfully and my Logstash Plugins installed without error as well.

No comments:

Post a Comment