[英]I want to install Java through the command line but I don't have sudo access.
This is what I have already done: 这是我已经做的:
prompt> wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" "http://download.oracle.com/otn-pub/java/jdk/7u60-b19/jdk-7u60-linux-i586.tar.gz"
Then untar it: 然后解压缩它:
prompt> tar xzf jdk-7u60-linux-i586.tar.gz?AuthParam=1404311550_7de85e3ec1ae4acea63f229d9bf50dbell
Rename it: 重命名:
prompt> mv jdk-7u60-linux-i586.tar.gz?AuthParam=1404311550_7de85e3ec1ae4acea63f229d9bf50dbe jdk-7u60-linux-i586.tar.gz
How to I finish the install without sudo access? 如何在没有sudo访问的情况下完成安装?
You don't really have to install it. 您实际上不必安装它。 You should be able to navigate into [your jdk folder]/bin and run ./javac -version.
您应该能够导航到[您的jdk文件夹] / bin并运行./javac -version。
So just add the bin folder to your path and set $JAVA_HOME and you're good to go. 因此,只需将bin文件夹添加到您的路径并设置$ JAVA_HOME,您就可以开始了。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.