首先,切换到jdk安装包所在目录:

[rot@centos6 Downloads]# ./jdk-6u45-linux-x64-rpm.bin
Unpacking...
Checksumming...
Extracting...
UnZipSFX 5.50 of February , by Info-ZIP (Zip-Bugs@lists.wku.edu).
inflating: jdk-6u45-linux-amd64.rpm
inflating: sun-javadb-common-10.6.-1.1.i386.rpm
inflating: sun-javadb-core-10.6.-1.1.i386.rpm
inflating: sun-javadb-client-10.6.-1.1.i386.rpm
inflating: sun-javadb-demo-10.6.-1.1.i386.rpm
inflating: sun-javadb-docs-10.6.-1.1.i386.rpm
inflating: sun-javadb-javadoc-10.6.-1.1.i386.rpm
Preparing... ########################################### [%]
:jdk ########################################### [%]
Unpacking JAR files...
rt.jar...
jsse.jar...
charsets.jar...
tools.jar...
localedata.jar...
plugin.jar...
javaws.jar...
deploy.jar...
Installing JavaDB
Preparing... ########################################### [%]
:sun-javadb-common ########################################### [ %]
:sun-javadb-core ########################################### [ %]
:sun-javadb-client ########################################### [ %]
:sun-javadb-demo ########################################### [ %]
:sun-javadb-docs ########################################### [ %]
:sun-javadb-javadoc ########################################### [%] Done.

配置环境变量:(出现lib/dt.jar: Permission denied,就是权限不够,请切换至/usr/java/jdk1..0_45/lib目录执行chmod 775 *.jar)

[root@centos6 Downloads]# export JAVA_HOME=/usr/java/jdk1..0_45/
[root@centos6 Downloads]# export PATH=$PATH:$JAVA_HOME/bin
[root@centos6 Downloads]# export CLASSPATH=.;$JAVA_HOME/lib/dt.jar;$JAVA_HOME/lib/tools.jar
bash: /usr/java/jdk1..0_45//lib/dt.jar: Permission denied
bash: /usr/java/jdk1..0_45//lib/tools.jar: Permission denied

使环境变量生效:修改.bashrc

[root@centos6 ~]# vi /etc/profile

#jdk1. env
export JAVA_HOME=/usr/java/jdk1..0_45
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
export PATH=$PATH:$JAVA_HOME/bin

CentOS6.4下安装JDK1.6的更多相关文章

  1. CentOS6.5下安装JDK1.7+MYSQL5.5+TOMCAT7+nginx1.7.5环境安装文档

    ----------------CentOS6.5下安装JDK1.7+MYSQL5.5+TOMCAT7+nginx1.7.5环境安装文档----------------------- [JDK1.7安 ...

  2. CentOS6.4 下安装 jdk1.7.0_67

    1.卸载系统自带的jdk 1.1.查看该操作系统上是否已经安装了jdk [root@xhTest-1 ~]# rpm -qa | grep jdk 1.2.删除系统自带的jdk [root@xhTes ...

  3. centos7和centos6通过yum安装JDK1.8

    centos7和centos6通过yum安装JDK1.8 查看JDK的安装路径# java -version============================查看Linux系统版本信息# cat ...

  4. 【转载】CentOS6.5_X64下安装配置MongoDB数据库

    [转载]CentOS6.5_X64下安装配置MongoDB数据库 2014-05-16 10:07:09|  分类: 默认分类|举报|字号 订阅      下载LOFTER客户端 本文转载自zhm&l ...

  5. CentOS6.5下安装apache2.2和PHP 5.5.28

    CentOS6.5下安装apache2.2 1. 准备程序 :httpd-2.2.27.tar.gz 下载地址:http://httpd.apache.org/download.cgi#apache2 ...

  6. CentOS6.5下安装配置MySQL

    CentOS6.5下安装配置MySQL,配置方法如下: 安装mysql数据库:# yum install -y mysql-server mysql mysql-deve 查看mysql-server ...

  7. CentOS 6系统下安装 JDK1.6

    CentOS 6系统下安装 JDK1.6 JDK(Java Development Kit)是Sun Microsystems针对Java开发员的产品.自从Java推出以来,JDK已经成为使用最广泛的 ...

  8. centos 7下安装jdk1.8

    本篇文章主要介绍在centos7 环境下安装jdk1.8并配置环境变量. 安装步骤 1.下载网址   https://www.oracle.com/technetwork/java/javase/do ...

  9. Linux下安装jdk1.7

    Linux下安装jdk1.7 1.进入 /usr/local下创建一个文件夹software,用来存放安装包. [root@192 ~]# cd /usr/local/ 2.创建文件夹 [root@1 ...

随机推荐

  1. poj3077---进位

    #include <stdio.h> #include <stdlib.h> #include<string.h> ]; ]; int main() { int n ...

  2. heap creation

    There two methods to construct a heap from a unordered set of array. If a array has size n, it can b ...

  3. SRM 581 D2 L3:TreeUnionDiv2,Floyd算法

    题目来源:http://community.topcoder.com//stat?c=problem_statement&pm=12587&rd=15501 这道题目开始以为是要在无向 ...

  4. ACM/ICPC2014鞍山现场赛E hdu5074Hatsune Miku

    题目链接:pid=5074">http://acm.hdu.edu.cn/showproblem.php?pid=5074 题意: 给定一个m*m的矩阵mp.然后给定一个长度为n的序列 ...

  5. web开发 - 从零开始 - 01 - 常见样式

    1.width  &  height 2.background : a.background-color b.background-image:url() c.background-repea ...

  6. CSS3 border属性的妙用

    .ribbon { background: #45c9c8; position: absolute; width: 75px; height: 25px; line-height: 25px; top ...

  7. oracle日期函数集锦

    oracle 中select TO_CHAR(sysdate,'Mon') from dual; Question:出来是中文的“6月” 我想要英文的怎么办? Answer:select to_cha ...

  8. 20151204--JDBC

    <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding= ...

  9. jQuery EasyUI combobox多选和赋值

    定义select <select id="ID" name=empVO.acunid class="easyui-combobox" required=& ...

  10. JavaWeb核心编程之(三.5)HTTP请求和接受表单数据

    HTTP简介WEB浏览器与WEB拂去其之间的一问一答的交互过程, 必须遵循一定的规则,这个规则就是HTTP协议HTTP是hypertext transfer protocol(超文本传输协议)的简写, ...