centos7 java1.8卸载_Centos7下安装与卸载Jdk1.8
Centos7下安装与卸载Jdk1.8
查看已经安装的jdk
[root@bogon jre]# rpm -qa|grep jdk
java-1.8.0-openjdk-headless-1.8.0.65-3.b17.el7.x86_64
java-1.7.0-openjdk-1.7.0.91-2.6.2.3.el7.x86_64
java-1.7.0-openjdk-headless-1.7.0.91-2.6.2.3.el7.x86_64
java-1.8.0-openjdk-1.8.0.65-3.b17.el7.x86_64
卸载命令
[root@bogon jre]# yum -y remove java-1.8.0-openjdk-headless-1.8.0.65-3.b17.el7.x86_64
卸载完成之后Java命令不被识别
[root@bogon lib]# java -version
bash: java: command not found…
安装
去官网下载jdk:http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
解压到安装目录
[root@bogon software]# tar -zxvf jdk-8u101-linux-x64.tar.gz -C /usr/local/java/
安装完毕之后在/etc/profile文件末尾添加
[root@bogon software]# vim /etc/profile
export JAVA_HOME=/usr/local/java/jdk1.8.0_101
export JRE_HOME=${JAVA_HOME}/jre
export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib
export PATH=${JAVA_HOME}/bin:$PATH
使/etc/profile生效
[root@bogon jdk1.8.0_101]# source /etc/profile
检测安装是否成功
[root@bogon jdk1.8.0_101]# java -version
java version “1.8.0_101”
Java(TM) SE Runtime Environment (build 1.8.0_101-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.101-b13, mixed mode)
[root@bogon jdk1.8.0_101]# javac
Usage: javacwhere possible options include:
-g Generate all debugging info
-g:none Generate no debugging info
-g:{lines,vars,source} Generate only some debugging info
-nowarn Generate no warnings
-verbose Output messages about what the compiler is doing
-deprecation Output source locations where deprecated APIs are used
-classpath Specify where to find user class files and annotation processors
-cp Specify where to find user class files and annotation processors
-sourcepath Specify where to find input source files
-bootclasspath Override location of bootstrap class files
-extdirs Override location of installed extensions
-endorseddirs Override location of endorsed standards path
-proc:{none,only} Control whether annotation processing and/or compilation is done.
-processor [,,…] Names of the annotation processors to run; bypasses default discovery process
-processorpath Specify where to find annotation processors
-parameters Generate metadata for reflection on method parameters
-d Specify where to place generated class files
-s Specify where to place generated source files
-h Specify where to place generated native header files
-implicit:{none,class} Specify whether or not to generate class files for implicitly referenced files
-encoding Specify character encoding used by source files
-source Provide source compatibility with specified release
-target Generate class files for specific VM version
-profile Check that API used is available in the specified profile
-version Version information
-help Print a synopsis of standard options
-Akey[=value] Options to pass to annotation processors
-X Print a synopsis of nonstandard options
-JPass directly to the runtime system
-Werror Terminate compilation if warnings occur
@Read options and filenames from file
centos7 java1.8卸载_Centos7下安装与卸载Jdk1.8相关推荐
- python3.6.8卸载_CentOS7下安装python3.6.8的教程详解
由于最近有个任务需要在python环境下跑,项目是python3.6 + tensorflow1.3.1.现总结安装环境: 卸载Python3.6方法: 首先用命令: whereis python 查 ...
- centos7远程访问mysql数据库_CentOS7下安装mysql最快捷方式及mysql远程访问连接实现详解...
由于本人使用源码安装时出现许多错误,导致最后安装依然失败,故不推荐源码安装.现分享下成功安装的案例. 1.CentOS7下安装mysql步骤: (1)首先必须添加mysql社区repo通过输入命令: ...
- mysql5.6解压包卸载_windows下安装、卸载mysql服务的方法(mysql 5.6 zip解压版安装教程)...
MySQL是一个小巧玲珑但功能强大的数据库,目前十分流行.但是官网给出的安装包有两种格式,一个是msi格式,一个是zip格式的.很多人下了zip格式的解压发现没有setup.exe,面对一堆文件一头雾 ...
- yum 卸载java_linux下安装、卸载java
安装java: 1. 下载jdk: 在http://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-ja ...
- windows 7下如何卸载重装mysql 压缩包版百度经验_windows下安装、卸载mysql服务的方法(mysql 5.6 zip解压...
MySQL是一个小巧玲珑但功能强大的数据库,目前十分流行.但是官网给出的安装包有两种格式,一个是msi格式,一个是zip格式的.很多人下了zip格式的解压发现没有setup.exe,面对一堆文件一头雾 ...
- MySQL——在Linux下安装和卸载MySQL
MySQL--在Linux下安装和卸载MySQL 摘要:本文主要学习了如何在Linux系统中安装和卸载MySQL数据库. 查看有没有安装过MySQL 使用命令查看有没有安装过: 1 [root@loc ...
- ubuntu下安装、卸载软件命令
http://www.2cto.com/os/201210/159589.html ubuntu下安装.卸载软件命令 安装: apt-get install name 卸载: apt-get remo ...
- linux查看mariadb安装卸载,MySQL——在Linux下安装和卸载MariaDB
MySQL--在Linux下安装和卸载MariaDB 摘要:本文主要学习了如何在Linux系统中安装和卸载MariaDB数据库. 查看有没有安装过MariaDB 使用命令查看有没有安装过: 1 [ro ...
- Centos8.2云服务器下安装和卸载Java JDK
Centos8.2云服务器下安装和卸载Java JDK 一.安装 二.卸载 一.安装 先查看下载本机上面有没有已经安装了JDK: java -version 没有安装. 先去官网下载相应的JDK. 下 ...
最新文章
- 浅谈移动类型102、122和161区别
- TCP 拥塞窗口原理
- Masonry('couldn't find a common superview for)
- 网络模块(客户端的连接动作)
- 【Python数据结构】——链表
- ie9 Flash内容无法显示
- 吸顶那个叫什么_为什么我家吸顶灯开灯后一闪一闪的
- 死锁 预防死锁避免死锁_死锁和处理死锁的方法
- django-登装饰器
- kafka 消息顺序写入服务器
- MyBatis框架的基本使用
- C++ 软件备份(拷贝构造函数)
- win10自动修复无法修复你的电脑的解决方法(操作+原理理解)
- 一款手机电脑都能用的进销存财务软件
- 如何将图片变成GIF图?一键完成gif制作
- IBM ITS中国区总经理鞠立老师讲女性的职业规划与发展
- linux下的软件包
- Linux应用程序开发之man手册汉化+开发的简易流程说明
- 力扣 656.金币路径
- Java码农进阶之路~流程控制-循环结构whileforbreak与continue
热门文章
- php正则替换短信模板,【PHP】短信接口(正则匹配)
- docker中使用python zxing实现二维码内容识别
- 母乳喂养,有助婴儿身心健康
- 使用sqlloader导入数据(千万级)-oracle
- 跨服务同步数据(MYSQL),@Scheduled定时任务,HttpClient分批发送数据,JSONobject,策略模式+简单工厂,异步@Async+CompletableFuture使用
- 计算机分辨率无法调整,电脑分辨率突然变小且无法调整的解决方法
- 服务器cpu是否支持超频,服务器处理器也能玩超频,LGA1366神器X5698超至6.2GHz
- 机器学习之贝叶斯分类算法(nlp)
- 浅析TypeScript setTimeout语法
- php读取文件和字符串编码