【Ubuntu手记】 How to install jdk in Ubuntu 11.10

来源:互联网 发布:java四种循环 编辑:程序博客网 时间:2024/06/05 17:14

install jdk in linux is easy,you don not need to download jdk alone,

open your Termianl:

1. apt-cache search jdk

a list of jdk for you as follow:

default-jdk - Standard Java or Java compatible Development Kitdefault-jdk-doc - Standard Java or Java compatible Development Kit (documentation)default-jre - Standard Java or Java compatible Runtimedefault-jre-headless - Standard Java or Java compatible Runtime (headless)gcj-4.4-jdk - gcj and classpath development tools for Java(TM)gcj-4.6-jdk - gcj and classpath development tools for Java(TM)gcj-jdk - gcj and classpath development tools for Java(TM)gcj-native-helper - Standard helper tools for creating gcj native packageslibcommons-lang-java - Extension of the java.lang packagelibcommons-lang-java-doc - Extension of the java.lang packagelibhessian-java - Java implementation of a binary protocol for web serviceslibhessian-java-doc - Documentation for libhessian-javalibpg-java - Java database (JDBC) driver for PostgreSQLlibpg-java-doc - Java database (JDBC) driver for PostgreSQL (documentation)mauve - free test suite for the Java Class librariesjde - JDEE, Java Development Environment for Emacs(en)fakeroot-ng - Gives a fake root environmentfreemind - Java Program for creating and viewing Mindmapsgcj-4.5-jdk - gcj and classpath development tools for Java(TM)japitools - Java API compatibility testing toolsjava3ds-fileloader - Java3D 3DS File Loaderjtreg - Regression Test Harness for the OpenJDK platformlibcommons-launcher-java - cross platform java application launcherlibcommons-math-java - Java lightweight mathematics and statistics componentslibcommons-math-java-doc - Java lightweight mathematics and statistics components - documentationlibhibernate-commons-annotations-java - Hibernate Commons Annotationslibicu4j-4.2-java - Library for Unicode support and internalisationlibicu4j-4.4-java - Library for Unicode support and internalisationlibicu4j-java - Library for unicode support and internalisationlibitext1-java - Java Library to generate PDF on the Flylibjboss-aop-java - JBoss Aspect Oriented Programming (AOP) frameworklibjboss-common-java - The JBoss Common Projectlibjboss-marshalling-java - alternative serialization APIlibjson-simple-java - Simple, lightweight and efficient JSON toolkit for Javalibjxp-java - Java template engine/script processorlibmaven-enforcer-plugin-java - Maven build rule execution frameworklibnb-javaparser-java - Parser for the Java language which is good for use in toolslibpicocontainer-java - Java library implementing the Dependency Injection patternlibslf4j-java - Simple Logging Facade for Javalibtrove-java - high performance collections for javalibtrove-java-doc - high performance collections for javalibwagon-java - tools to manage Maven artifacts and deploymentmmake - Makefile generator for Java programssubstance - cross-platform look & feel for Swing applicationssubstance-doc - cross-platform look & feel for Swing applications - documentationtestng - testing framework for Javausepackage - utility to manage environment variables from within dotfilesuwsgi-app-integration-plugins - plugins for integration of uWSGI and applicationuwsgi-plugin-jvm-openjdk-6 - Java plugin for uWSGI (OpenJDK 6)uwsgi-plugin-jwsgi-openjdk-6 - JWSGI plugin for uWSGI (OpenJDK 6)visualvm - All-in-One Java Troubleshooting Toolicedtea-6-jre-cacao - Alternative JVM for OpenJDK, using Cacaoicedtea-6-jre-jamvm - Alternative JVM for OpenJDK, using JamVMicedtea-plugin - web browser plugin based on OpenJDK and IcedTea to execute Java appletslibreoffice - office productivity suiteopenjdk-6-dbg - Java runtime based on OpenJDK (debugging symbols)openjdk-6-demo - Java runtime based on OpenJDK (demos and examples)openjdk-6-doc - OpenJDK Development Kit (JDK) documentationopenjdk-6-jdk - OpenJDK Development Kit (JDK)openjdk-6-jre - OpenJDK Java runtime, using Hotspot JITopenjdk-6-jre-headless - OpenJDK Java runtime, using Hotspot JIT (headless)openjdk-6-jre-lib - OpenJDK Java runtime (architecture independent libraries)openjdk-6-source - OpenJDK Development Kit (JDK) source filesicedtea-7-jre-jamvm - Alternative JVM for OpenJDK, using JamVMopenjdk-6-jre-zero - Alternative JVM for OpenJDK, using Zero/Sharkopenjdk-7-dbg - Java runtime based on OpenJDK (debugging symbols)openjdk-7-demo - Java runtime based on OpenJDK (demos and examples)openjdk-7-doc - OpenJDK Development Kit (JDK) documentationopenjdk-7-jdk - OpenJDK Development Kit (JDK)openjdk-7-jre - OpenJDK Java runtime, using Hotspot JITopenjdk-7-jre-headless - OpenJDK Java runtime, using Hotspot JIT (headless)openjdk-7-jre-lib - OpenJDK Java runtime (architecture independent libraries)openjdk-7-jre-zero - Alternative JVM for OpenJDK, using Zero/Sharkopenjdk-7-source - OpenJDK Development Kit (JDK) source files


Choose what you want :

2. sudo apt-get install openjdk-6-jdk


it get start to install.
不需要再配置环境变量即可直接使用