Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

After installing Java and try to view it's version I'm getting the below error:

saran@ubuntu:/usr/lib/jvm/jdk1.7.0_21/bin$ java -version
bash: /usr/bin/java: cannot execute binary file
share|improve this question
Can you post the output of "ls -l /usr/lib/jvm/jdk1.7.0_21/bin"? –  Hendre Apr 22 '13 at 7:29
add comment

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.