Java EE安装程序在Mac OS X Mavericks上崩溃 [英] Java EE installer crashing on Mac OS X Mavericks

查看:138
本文介绍了Java EE安装程序在Mac OS X Mavericks上崩溃的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

试图在操作系统10.9 Mavericks上安装Java EE 7 / Glassfish 4,并且每次都会崩溃。我已经尝试安装Apple JDK和Oracle JDK,但都没有工作。有没有人遇到过这个?我记得在10.8上安装,它工作得很好。
$ b

环境变量:
$ b $ $ $ echo $ JAVA_HOME

/Library/Java/JavaVirtualMachines/jdk1.7.0_45.jdk/Contents/Home



输出:

  $ chmod + x java_ee_sdk-7-jdk7-macosx-x64.sh 

$ ./java_ee_sdk-7-jdk7-macosx-x64.sh

提取安装程序档案...
提取安装程序运行库...提取安装程序
资源...提取安装程序元数据...

欢迎使用GlassFish安装程序

使用用户定义的JAVA_HOME:
/Library/Java/JavaVirtualMachines/jdk1.7.0_45.jdk/Contents/Home
输入设置... SwixML 1.5(#144)

#Java运行时环境检测到一个致命错误:

#SIGSEGV(0xb)在pc = 0x0000000119956af9,pid = 5178, (Java):Java HotSpot(TM)tid = 50183

#JRE版本:Java™SE运行时环境(7.0_45-b18)(build 1.7.0_45-b18)
# 64位服务器虚拟机(24.45-b08混合模式bs d-amd64压缩的oops)
#有问题的帧:
#C 0x0000000119956af9

#无法写入核心转储。核心转储已被禁用。要启用核心转储,请在再次启动Java之前尝试ulimit -c unlimited

#包含更多信息的错误报告文件另存为:
#/ var / folders / 4t / 7dky_l096m1fdl5gncg_w__80000gn /T//hs_err_pid5178.log

#如果您想提交错误报告,请访问:
#http://bugreport.sun.com/bugreport/crash.jsp
#崩溃发生在Java虚拟机之外的本地代码中。
#查看有问题的框架来报告错误。
#/tmp/install.111513141256/install/bin/engine-wrapper:line 139:5178中止陷阱:6 $ {JAVA_HOME} / bin / java $ {JAVA_OPTIONS}
-Dinstall.engine = $ {theInstallEngine} -Dinstaller.resources.url = $ {MEDIALOC} / -Ddefault.resources.url = file:$ {INSTALL_HOME} / lib / resources / -classpath $ {theCP} -Dsims.native-file-dir = $ { INSTALL_HOME} / lib
org.openinstaller.core.EngineBootstrap $ {INSTALLPROPS}


解决方案

我知道这是一个古老的问题,但我遇到了同样的问题,并认为我的解决方案可能在未来帮助其他人。



我在这里找到了答案: https://apple.stackexchange.com/a/115708/89930



总而言之,您需要设置几个变量,然后以静默模式运行安装程序。

首先创建一个名为'silent_install_answer_file'的新文本文件并添加以下内容,更新值a需要:

  ClusteredInstance.Configuration.CLUSTER_NAME = c1 
ClusteredInstance.Configuration.CREATE_CLUSTER = false
ClusteredInstance .Configuration.DOMAIN_NAME = domain1
ClusteredInstance.Configuration.INSTANCE_NAME = instance1
ClusteredInstance.Configuration.SERVER_ADMIN_PORT = 4848
ClusteredInstance.Configuration.SERVER_HOST_NAME = localhost
ConfigType.Option.CREATE_CLUSTEREDINSTANCE = CREATE_CLUSTEREDINSTANCE
ConfigType.Option.CREATE_DOMAIN = CREATE_DOMAIN
ConfigType.Option.CREATE_STANDALONEINSTANCE = CREATE_STANDALONEINSTANCE
ConfigType.Option.NO_CONFIGURATION = NO_CONFIGURATION
Domain.Configuration.ADMIN_PASSWORD =密码
域。 Configuration.ADMIN_PASSWORD_REENTER =密码
Domain.Configuration.ADMIN_PORT = 4848
Domain.Configuration.ADMIN_USER = admin
Domain.Configuration.CREATE_SERVICE = false
Domain.Configuration.DOMAIN_NAME = domain1
Domain.Configuration.HTTP_PORT = 8080
Domain.Configuration.SER VICE_NAME = domain1Service
Domain.Configuration.START_SERVER = false
InstallHome.directory.INSTALL_HOME = / usr / local / glassfish4
InstallType.Option.CONFIG_ONLY = CONFIG_ONLY
InstallType.Option.INSTALL_AND_CONFIG = INSTALL_AND_CONFIG
InstallType.Option.INSTALL_ONLY = INSTALL_ONLY
InstallUserType.Option.ADVANCED_USER = ADVANCED_USER
InstallUserType.Option.BASIC_USER = BASIC_USER
JDKSelection.directory.HIDDEN_JDK =
JDKSelection JDKSelection.directory.JDK_TYPE_IN =
JDKSelection.directory.JDK_TYPED_IN_CHOICE = false
RegistrationOptions.regoptions.CREATE_NEWACCT = CREATE_NEWACCT
RegistrationOptions.regoptions.DUMMY_PROP =
RegistrationOptions.regoptions.SKIP_REGISTRATION = SKIP_REGISTRATION
RegistrationOptions.regoptions.USE_EXISTINGACCT = USE_EXISTINGACCT
RegistrationOptions.regoptions.USERNAME =
RegistrationOptions.regoptions.USERPASSWORD =
SOAccountCreation .accountinfo.COMPANYNAME =
SOAccountCreation.accountinfo.COUNTRY_DROP_DOWN =
SOAccountCreation.accountinfo.COUNTRY =
SOAccountCreation.accountinfo.EMAIL =
SOAccountCreation.accountinfo.FIRSTNAME =
SOAccountCreation .accountinfo.LASTNAME =
SOAccountCreation.accountinfo.PASSWORD =
SOAccountCreation.accountinfo.REENTERPASSWORD =
StandaloneInstance.Configuration.INSTANCE_NAME = instance1
StandaloneInstance.Configuration.SERVER_ADMIN_PORT = 4848
StandaloneInstance.Configuration.SERVER_HOST_NAME = localhost
UpdateTool.Configuration.ALLOW_UPDATE_CHECK = true
UpdateTool.Configuration.BOOTSTRAP_UPDATETOOL = true
UpdateTool.Configuration.PROXY_HOST =
UpdateTool.Configuration.PROXY_PORT =

检查JAVA_HOME环境变量是否设置正确:



export JAVA_HOME =$(/ usr / libexec / java_home)



创建 / Users / username / temp 目录,如果它没有t已经存在( mkdir / Users / username / temp )。

最后,使用sudo运行安装程序。您可能还需要同时设置DISPLAY变量:



$ sudo DISPLAY =:0 ./java_ee_sdk-7-jdk7-macosx -x64.sh -a silent_install_answer_file -l / Users / username / temp -s



安装程序可能需要几分钟才能完成,因为它在无声模式下运行,所以在此期间可能看不到太多输出,所以请耐心等待。



如果您在静默模式下运行安装程序时遇到问题,GlassFish安装程序文档可能对您有些用处: https://glassfish.java。 net / docs / 4.0 / installation-guide.pdf

一个看似相关的问题: java ee在OSX上安装失败



希望可以帮助别人!


Trying to install Java EE 7/Glassfish 4 on OS 10.9 Mavericks and it crashes every time. I have tried installing the Apple JDK and the Oracle JDK and neither work. Has anyone ran into this? I remember installing on 10.8 and it worked just fine. Thanks!

Environment Variables:

$ echo $JAVA_HOME

/Library/Java/JavaVirtualMachines/jdk1.7.0_45.jdk/Contents/Home

Output:

$ chmod +x java_ee_sdk-7-jdk7-macosx-x64.sh

$ ./java_ee_sdk-7-jdk7-macosx-x64.sh 

Extracting the installer archive...
Extracting the installer runtime... Extracting the installer
resources... Extracting the installer metadata...

Welcome to GlassFish installer

Using the user defined JAVA_HOME :
/Library/Java/JavaVirtualMachines/jdk1.7.0_45.jdk/Contents/Home
Entering setup... SwixML 1.5 (#144)
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x0000000119956af9, pid=5178, tid=50183
#
# JRE version: Java(TM) SE Runtime Environment (7.0_45-b18) (build 1.7.0_45-b18)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (24.45-b08 mixed mode bsd-amd64 compressed oops)
# Problematic frame:
# C  0x0000000119956af9
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /var/folders/4t/7dky_l096m1fdl5gncg_w__80000gn/T//hs_err_pid5178.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
# /tmp/install.111513141256/install/bin/engine-wrapper: line 139:  5178 Abort trap: 6           ${JAVA_HOME}/bin/java ${JAVA_OPTIONS}
-Dinstall.engine=${theInstallEngine} -Dinstaller.resources.url=${MEDIALOC}/ -Ddefault.resources.url=file:${INSTALL_HOME}/lib/resources/ -classpath ${theCP} -Dsims.native-file-dir=${INSTALL_HOME}/lib
org.openinstaller.core.EngineBootstrap ${INSTALLPROPS}

解决方案

I know this is an old question, but I just ran into the same problem and thought my solution may help others in the future.

I found the answer here: https://apple.stackexchange.com/a/115708/89930

To summarise, you need to set a couple of variables and then run the installer in silent mode.

Start by creating a new text file called 'silent_install_answer_file' and add the following contents, updating values as necessary:

ClusteredInstance.Configuration.CLUSTER_NAME=c1
ClusteredInstance.Configuration.CREATE_CLUSTER=false
ClusteredInstance.Configuration.DOMAIN_NAME=domain1
ClusteredInstance.Configuration.INSTANCE_NAME=instance1
ClusteredInstance.Configuration.SERVER_ADMIN_PORT=4848
ClusteredInstance.Configuration.SERVER_HOST_NAME=localhost
ConfigType.Option.CREATE_CLUSTEREDINSTANCE=CREATE_CLUSTEREDINSTANCE
ConfigType.Option.CREATE_DOMAIN=CREATE_DOMAIN
ConfigType.Option.CREATE_STANDALONEINSTANCE=CREATE_STANDALONEINSTANCE
ConfigType.Option.NO_CONFIGURATION=NO_CONFIGURATION
Domain.Configuration.ADMIN_PASSWORD=password
Domain.Configuration.ADMIN_PASSWORD_REENTER=password
Domain.Configuration.ADMIN_PORT=4848
Domain.Configuration.ADMIN_USER=admin
Domain.Configuration.CREATE_SERVICE=false
Domain.Configuration.DOMAIN_NAME=domain1
Domain.Configuration.HTTP_PORT=8080
Domain.Configuration.SERVICE_NAME=domain1Service
Domain.Configuration.START_SERVER=false
InstallHome.directory.INSTALL_HOME=/usr/local/glassfish4
InstallType.Option.CONFIG_ONLY=CONFIG_ONLY
InstallType.Option.INSTALL_AND_CONFIG=INSTALL_AND_CONFIG
InstallType.Option.INSTALL_ONLY=INSTALL_ONLY
InstallUserType.Option.ADVANCED_USER=ADVANCED_USER
InstallUserType.Option.BASIC_USER=BASIC_USER
JDKSelection.directory.HIDDEN_JDK=
JDKSelection.directory.JDK_FROM_LIST_CHOICE=false
JDKSelection.directory.JDK_LIST=
JDKSelection.directory.JDK_TYPE_IN=
JDKSelection.directory.JDK_TYPED_IN_CHOICE=false
RegistrationOptions.regoptions.CREATE_NEWACCT=CREATE_NEWACCT
RegistrationOptions.regoptions.DUMMY_PROP=
RegistrationOptions.regoptions.SKIP_REGISTRATION=SKIP_REGISTRATION
RegistrationOptions.regoptions.USE_EXISTINGACCT=USE_EXISTINGACCT
RegistrationOptions.regoptions.USERNAME=
RegistrationOptions.regoptions.USERPASSWORD=
SOAccountCreation.accountinfo.COMPANYNAME=
SOAccountCreation.accountinfo.COUNTRY_DROP_DOWN=
SOAccountCreation.accountinfo.COUNTRY=
SOAccountCreation.accountinfo.EMAIL=
SOAccountCreation.accountinfo.FIRSTNAME=
SOAccountCreation.accountinfo.LASTNAME=
SOAccountCreation.accountinfo.PASSWORD=
SOAccountCreation.accountinfo.REENTERPASSWORD=
StandaloneInstance.Configuration.INSTANCE_NAME=instance1
StandaloneInstance.Configuration.SERVER_ADMIN_PORT=4848
StandaloneInstance.Configuration.SERVER_HOST_NAME=localhost
UpdateTool.Configuration.ALLOW_UPDATE_CHECK=true
UpdateTool.Configuration.BOOTSTRAP_UPDATETOOL=true
UpdateTool.Configuration.PROXY_HOST=
UpdateTool.Configuration.PROXY_PORT=

Check that the JAVA_HOME environment variable is set appropriately:

export JAVA_HOME="$(/usr/libexec/java_home)"

Create the /Users/username/temp directory if it does not already exist (mkdir /Users/username/temp).

Lastly, run the installer with sudo. You may also need to set the DISPLAY variable at the same time:

$ sudo DISPLAY=:0 ./java_ee_sdk-7-jdk7-macosx-x64.sh -a silent_install_answer_file -l /Users/username/temp -s

The installer may take a few minutes to complete and, as it is running in silent mode, you may not see much output during that time, so be patient.

If you have trouble running the installer in silent mode, the GlassFish installer documentation may be of some use to you: https://glassfish.java.net/docs/4.0/installation-guide.pdf

A seemingly related question: java ee install failing on OSX

Hope that helps someone!

这篇关于Java EE安装程序在Mac OS X Mavericks上崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆