Why java and javac commands report different versions in Red Hat Enterprise Linux 6?

Solution Verified - Updated -

Issue

  • Why the different version are reported from java and javac?
# /usr/bin/javac -version
javac 1.6.0_32
# /usr/bin/java -version
java version "1.7.0_65"
  • How did it happen after installation?
  • How can we avoid it?

Environment

Red Hat Enterprise Linux 6

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content