Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have no root access to java JDK 7 so I install java JDK to a folder and extract it

Then if I call it:

./bin/java -version

it works and shows the version. but now I want to configure Eclipse to use that new version but it requires to link it to OpenJDK which I dont know how to install it to my desired folder as I did for the step above. so briefly, how can I install openJDK inside my folder and make it work?


share|improve this question

migrated from Apr 24 '13 at 17:40

This question came from our site for professional and enthusiast programmers.

edit your eclipse.ini file and add a "-vm" with the full path to the java command to use

share|improve this answer
when I dont have privilege means I cant edit that file. – user2254866 Apr 24 '13 at 15:56
Do not install Eclipse from the repositories. That is outdated in almost all distributions. Just unzip a download from the Eclipse website to any directory you like. There you can also edit the eclipse.ini. – Bananeweizen Apr 24 '13 at 18:58

Don't sudo apt-get install sun-java7-jdk work as a unprivileged user? (i couldn't comment sorry).

You could check out

That may help you.

share|improve this answer
"sudo (pron.: /ˈsuːduː/[2] or /ˈsuːdoʊ/) is a program for Unix-like computer operating systems that allows users to run programs with the security privileges of another user (normally the superuser, or root)." - – vijay Apr 24 '13 at 15:45
@Tyler no it doesnt work for unprivileged user. – user2254866 Apr 24 '13 at 15:47
Oh okay my bad, never tried anything as a unprivileged user. Thanks for the feedback. – Tyler Apr 24 '13 at 15:48

You can try to just download the ubuntu deb packages and extract them to a local folder. Execute apt-get -y --print-uris install openjdk-7-jdk to show you what packages you need, then download and extract them.

script to do everything:

apt-get -y --print-uris install openjdk-7-jdk | grep "http.*deb" -o | xargs wget
for d in *.deb; do dpkg -x "$d" openjdk; done
rm *.deb

Now you should have everything extracted to a folder openjdk.

From what I've tried the java installed like this seems to work fine, you just neet to point eclipse to the new vm.

share|improve this answer

Your Answer


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