OpenJDK problem on Ubuntu System

本文记录了在Ubuntu系统中使用JBoss和OpenJDK遇到的错误:Java运行时环境检测到致命错误并崩溃的问题。作者尝试用Sun JDK替换OpenJDK,并详细描述了解决过程及最终成功的方法。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

OpenJDK problem on Ubuntu System

Recently I used Ubuntu system. Sometimes, my jboss and openjdk get this error:
#

# A fatal error has been detected by the Java Runtime Environment:

#

# SIGSEGV (0xb) at pc=0xb4d657e3, pid=2992, tid=2124122992

#

# JRE version: 6.0_20-b20

# Java VM: OpenJDK Server VM (19.0-b09 mixed mode linux-x86 )

# Derivative: IcedTea6 1.9.7

# Distribution: Ubuntu 10.10, package 6b20-1.9.7-0ubuntu1

# Problematic frame:

# J org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement()Z

#

# An error report file with more information is saved as:

# /home/luohua/tools/jboss/bin/hs_err_pid2992.log

#

# If you would like to submit a bug report, please include

# instructions how to reproduce the bug and visit:

# https://bugs.launchpad.net/ubuntu/+source/openjdk-6/

#

I read the hs_err_pid2992.log file. It does not make any sence to me. So I try to use sun jdk instead of open jdk to have a try.

I tried to get the software with command
>sudo apt-get install sun-java6-jdk
But I get these error message:

[sudo] password for luohua:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package sun-java6-jdk is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'sun-java6-jdk' has no installation candidate

I tried to solve this with command:
>sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"
>sudo apt-get update

again
>sudo apt-get install sun-java6-jdk

change the JDK
>sudo update-alternatives --config java
>sudo update-alternatives --config javac

check the version with command:
> java -version

java version "1.6.0_24"
Java(TM) SE Runtime Environment (build 1.6.0_24-b07)
Java HotSpot(TM) Server VM (build 19.1-b02, mixed mode)

So, I hope it will work fine in the future.

Open my eclipse and click
[Preferences]---->[Java]----->[Installed JREs]------>[Add] /usr/lib/jvm/java-6-sun
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值