PyCharm在Linux安装出现报错-Java Runtime (class file version 55.0)
在Linux桌面下安装PyCharm的时候出现如下报错
root@ubuntu:~# cd pycharm-community-2021.1.1
root@ubuntu:~/pycharm-community-2021.1.1# ls
bin classpath.txt Install-Linux-tar.txt license
brokenPlugins.db help jbr plugins
build.txt icons.db lib product-info.json
root@ubuntu:~/pycharm-community-2021.1.1# cd bin/
root@ubuntu:~/pycharm-community-2021.1.1/bin# ls
format.sh inspect.sh printenv.py pycharm.svg
fsnotifier libdbm64.so pycharm64.vmoptions pycharm.vmoptions
fsnotifier64 log.xml pycharm.png restart.py
idea.properties ltedit.sh pycharm.sh
root@ubuntu:~/pycharm-community-2021.1.1/bin# ./pycharm.sh
Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.UnsupportedClassVersionError: com/intellij/idea/Main has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:756)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:468)
at java.net.URLClassLoader.access$100(URLClassLoader.java:74)
at java.net.URLClassLoader$1.run(URLClassLoader.java:369)
at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:355)
at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:601)
root@ubuntu:~/pycharm-community-2021.1.1/bin#

此问题为Java版本太低,需要使用新的jdk版本
49 = Java 5
50 = Java 6
51 = Java 7
52 = Java 8
53 = Java 9
54 = Java 10
55 = Java 11
56 = Java 12
57 = Java 13
58 = Java 14
59 = Java 15
60 = Java 16
安装Java
root@ubuntu:~# tar xvf jdk-16.0.1_linux-aarch64_bin.tar.gz
root@ubuntu:~# mv jdk-16.0.1 /usr/local/
root@ubuntu:~# cd /usr/local/
root@ubuntu:/usr/local# ls
Ascend dcmi games jdk-16.0.1 lib python3.7.5 share
bin etc include jdk1.8.0_291 man sbin src
root@ubuntu:/usr/local# vim /etc/profile
root@ubuntu:/usr/local# source /etc/profile
环境变量配置文件
root@ubuntu:/usr/local# cat /etc/profile
# /etc/profile: system-wide .profile file for the Bourne shell (sh(1))
# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...).
if [ "${PS1-}" ]; then
if [ "${BASH-}" ] && [ "$BASH" != "/bin/sh" ]; then
# The file bash.bashrc already sets the default PS1.
# PS1='\h:\w\$ '
if [ -f /etc/bash.bashrc ]; then
. /etc/bash.bashrc
fi
else
if [ "`id -u`" -eq 0 ]; then
PS1='# '
else
PS1='$ '
fi
fi
fi
if [ -d /etc/profile.d ]; then
for i in /etc/profile.d/*.sh; do
if [ -r $i ]; then
. $i
fi
done
unset i
fi
#用于设置python3.7.5库文件路径
export LD_LIBRARY_PATH=/usr/local/python3.7.5/lib:$LD_LIBRARY_PATH
#如果用户环境存在多个python3版本,则指定使用python3.7.5版本
export PATH=/usr/local/python3.7.5/bin:$PATH
# control log level. 0-DEBUG, 1-INFO, 2-WARNING, 3-ERROR, default level is WARNING.
export GLOG_v=2
# Conda environmental options
LOCAL_ASCEND=/usr/local/Ascend # the root directory of run package
# lib libraries that the run package depends on
export LD_LIBRARY_PATH=${LOCAL_ASCEND}/add-ons/:${LOCAL_ASCEND}/ascend-toolkit/latest/fwkacllib/lib64:${LOCAL_ASCEND}/driver/lib64:${LOCAL_ASCEND}/ascend-toolkit/latest/opp/op_impl/built-in/ai_core/tbe/op_tiling:${LD_LIBRARY_PATH}
# Environment variables that must be configured
export TBE_IMPL_PATH=${LOCAL_ASCEND}/ascend-toolkit/latest/opp/op_impl/built-in/ai_core/tbe # TBE operator implementation tool path
export ASCEND_OPP_PATH=${LOCAL_ASCEND}/ascend-toolkit/latest/opp # OPP path
export PATH=${LOCAL_ASCEND}/ascend-toolkit/latest/fwkacllib/ccec_compiler/bin/:${PATH} # TBE operator compilation tool path
export PYTHONPATH=${TBE_IMPL_PATH}:${PYTHONPATH} # Python library that TBE implementation depends on
export JAVA_HOME=/usr/local/jdk-16.0.1
export JRE_HOME=/usr/local/jdk-16.0.1/jre/
export CLASSPATH=$CLASSPATH:$JAVA_HOME/lib:$JAVA_HOME/jre/lib
export PATH=$JAVA_HOME/bin:$JAVA_HOME/jre/bin:$PATH:$HOME/bin
root@ubuntu:/usr/local#

PyCharm在Linux安装出现报错-Java Runtime (class file version 55.0)的更多相关文章
- java运行报错 has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
解决方法: 解决办法: 在项目的属性里设置jdk版本,方法是右击项目-->properties-->java compiler --> Enable project specific ...
- 解决Python3.7安装pygame报错You are using pip version 10.0.1, however version 19.1 is available.
背景: 学习python开发中,需要用到pygame插件,因此按照参考书<Python编程实践,从入门到实践>指引安装Pygame包. 但是利用pip 命令安装 .whl 文件时,报错(如 ...
- 云笔记项目- 上传文件报错"java.lang.IllegalStateException: File has been moved - cannot be read again"
在做文件上传时,当写入上传的文件到文件时,会报错“java.lang.IllegalStateException: File has been moved - cannot be read again ...
- 8.4 sikuli 集成进eclipse 报错:Unsupported major.minor version 51.0
8.3中的问题Win32Util.dll: Can't load 32-bit .dll on a AMD 64 bit platform 解决之后,执行还是会有报错:Unsupported maj ...
- Linux安装Apache报错:Cannot find a valid baseurl for repo: base/7/x86_64解决方案
最近使用CentOS7学习,安装安装Apache时候,使用yum安装Apache报错:本文适合CentOS7和RHEL7 # yum install httpd 出现:cannot find a va ...
- 关于spark入门报错 java.io.FileNotFoundException: File file:/home/dummy/spark_log/file1.txt does not exist
不想看废话的可以直接拉到最底看总结 废话开始: master: master主机存在文件,却报 执行spark-shell语句: ./spark-shell --master spark://ma ...
- go搭建beego框架 go安装bee报错 github.com/derekparker/delve@v1.4.0: parsing go.mod:
go搭建beego框架 go安装bee报错 go使用beego框架的时候,需要安装bee,安装的时候遇到一些坑报错,这里跟大家分享一下,有助于快速安装bee,搭建好beego环境 1. 首先切换到go ...
- tomcat启动报错:Unsupported major.minor version 51.0
myeclipse中添加项目后,发现项目启动时报错:Unsupported major.minor version 51.0 因为tomcat使用的jdk版本不支持你项目的jdk版本,需要你在myec ...
- linux安装oracle 报错[INS-20802] Oracle Net Configuration Assistant failed 解决办法
[INS-20802] Oracle Net Configuration Assistant failed 首先从LinuxIDC.com下载这个补丁包,然后用 unzip p8670579_1120 ...
- Linux安装oracle报错解决
安装报错:[oracle@centos1 database]$ ./runInstaller Starting Oracle Universal Installer... Checking insta ...
随机推荐
- 【摘】python和它的装饰器
python和它的装饰器 即使你没听过装饰器,你也一定知道@staticmethod 作为函数的装饰器,你可以这样写 def mydecorator(function): def wrapped(*a ...
- 使用bat脚本判断远程SVN文件是否有修改
在Windows上, 使用 svn status -u -q %dir% 可以列出svn仓库的状态: M 8295 build.bat * 8306 E:\game\bzk\dev\tools\pro ...
- 西瓜书3.4 解题报告(python 多分类学习 十折交叉法)
偷懒找了UCI上最小的一个数据集,数据大约是集装箱起重机的转动速度.角度,判断其力量大小(我不懂起重机啊啊啊) 虽然不懂但并不妨碍写代码分类,显然标记就是力量,分为0.3.0.5.0.7三种.具体的模 ...
- CF527D 题解
题意:数轴上有 \(n\) 个点,第 \(i\) 个点的坐标为 \(x_i\),权值为 \(w_i\).两个点 \(i,j\) 之间存在一条边当且仅当 \(abs(x_i-x_j)\geq w_i+w ...
- 关于git错误:Git未能顺利结束(退出码 128)的解决办法
如图: 问题原因: 主要是:用户名.邮箱.用户密钥跟github官网上配置的不一致 https://blog.csdn.net/weixin_52517585/article/details/1269 ...
- 高并发解决方案之 redis原子操作(适用于秒杀场景)
秒杀活动: 秒杀场景一般会在电商网站或(APP/小程序)举行一些活动或者节假日在12306网站上抢票时遇到.对于一些稀缺或者特价商品,一般会在约定时间点对其进行限量销售,因为这些商品的特殊性,会吸引大 ...
- IT工具知识-09:OpenWrt设置旁路由
0.使用背景 设备:N1 固件:filppy打包的60+ 1.使用方法 1.1知道主路由的IP地址(例如192.168.1.1) 1.2在OpenWrt管理界面下进行设置 进入OpenWrt管理界面 ...
- vue项目部署后页面加载首次很慢的优化方案
参考: vue项目首次加载特别慢需要怎么配置? 1.看看你的依赖包是不是全局引入的,改为组件内按需引入,可大大降低加载时长.或者将组件引入方式改为cdn引入.需要注意的是,两种引入方式不能共存. 2. ...
- 利用fread读取二进制文件的bug
最近在做一个项目时需要读取二进制文件,我用C语言的fread进行读取,代码如下: FILE *fp; int read_data; fopen_s(&fp, file_path, " ...
- github pic test