- 浏览: 801616 次
- 性别:
- 来自: 哈尔滨
文章分类
最新评论
-
doloveme:
$sudo cp MONACO_Linux.ttf /usr/ ...
terminator 的配置 -
腾讯rep:
lowser
RSA加密算法c++简单实现 -
csuhanyong:
好YD啊,好YD
一图流:机械键盘各轴区别 -
doloveme:
1。其中:extman ,extmail下载http://ww ...
Ubuntu下安装postfix+extmail邮件服务器 -
doloveme:
repo sync出现“fatal: '../platform ...
Android 编译环境配置搭建(Ubuntu 12.04)及环境导致编译错误QA
在Red hat linux enterprise 5 上安装 eclipse(2009-04-12 11:22:47)
1.安装JDK
我的机器上安装的是jdk6.版本是jdk1.6.0_13,下载的文件是jdk-6u13-linux-i586.bin,并且配置好环境变量,详情参
考我的文章“在Red hat linux enterprise 5 上安装 JDK 6.0"
2. 下载Eclipse
我下载的是eclipse-jee-ganymede-SR2-linux-gtk.tar.gz 其是JAVA EE
eclipse,能够创建Web工程,EJB工程等企业应用相关的工程.
3.安装eclipse
将下载的eclipse-jee-ganymede-SR2-linux-gtk.tar.gz拷贝到你想安装Eclipse的目录下(我这里是/usr
/java,执行如下命令,
# tar -zxvf eclipse-jee-ganymede-SR2-linux-gtk.tar.gz
执行这个命令后你会看到在你所选择的目录下有了一个叫eclipse的文件夹,我这里是/usr/java/eclipse
在完成上面的步骤之后,你可能会认为你也大功告成了,但有可能出现的问题是当启动Eclipse时,其提示当前的JDK版本与eclipse要求的版本不
匹配,其原因是当启动Eclipse时其默认使用linux自带的jdk 如jdk
1.4.2_x等,其并没有使用我们安装的JDK1.6x.那么如何解决这个问题呢?
请看如下:
首先需要把新安装的jdk添加到alternatives
# alternatives --install /usr/bin/java java
/usr/java/jdk1.6.0_13/jre/bin/java 2
然后使用--display选项可以查看目前系统可用的JDK:
# ./alternatives --display java
确认无误后,就可以使用--config参数来选择想用的JDK了:
# ./alternatives --config java
共有 3 个程序提供“java”。
选择 命令
-----------------------------------------------
*+ 1 /usr/lib/jvm/jre-1.4.2-gcj/bin/java
2 /usr/java/jdk1.6.0_13/jre/bin/java
3 /usr/java/jdk1.6.0_13/bin/java
按 Enter 来保存当前选择[+],或键入选择号码:2
这里我们输入2并按 Enter 来保存.
到此为止你以为没问题了,但当你重新启动eclispe时 ,其可能自动关闭,为什么呢?请看如下,
" Summary
SELinux is preventing /usr/java/eclipse/eclipse from loading
/usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.so which
requires text
relocation.
Detailed Description
The /usr/java/eclipse/eclipse application attempted to load
/usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.so which
requires text
relocation. This is a potential security problem. Most
libraries do not
need this permission. Libraries are sometimes coded incorrectly
and request
this permission. The
http://people.redhat.com/drepper/selinux-mem.html web
page explains how to remove this requirement. You can configure
SELinux
temporarily to allow
/usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.so to
use relocation as a workaround, until the library is fixed.
Please file a
http://bugzilla.redhat.com/bugzilla/enter_bug.cgi against this
package.
Allowing Access
If you trust /usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.so
to run
correctly, you can change the file context to textrel_shlib_t.
"chcon -t
textrel_shlib_t
/usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.so"
The following command will allow this access:
chcon -t textrel_shlib_t
/usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.so
Additional Information
Source Context
system_u:system_r:unconfined_t:SystemLow-
SystemHigh
Target Context system_u:object_r:usr_t
Target Objects
/usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.s
o [ file ]
Affected RPM Packages
Policy RPM selinux-policy-2.4.6-30.el5
Selinux Enabled True
Policy Type targeted
MLS Enabled True
Enforcing Mode Enforcing
Plugin Name plugins.allow_execmod
Host Name localhost.localdomain
Platform Linux localhost.localdomain
2.6.18-8.el5xen #1 SMP
Fri Jan 26 14:42:21 EST 2007 i686 i686
Alert Count 1
Line Numbers
Raw Audit Messages
avc: denied { execmod } for comm="eclipse" dev=dm-0 egid=0 euid=0
exe="/usr/java/eclipse/eclipse" exit=-13 fsgid=0 fsuid=0 gid=0
items=0
name="libjvm.so"
path="/usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.so"
pid=3579 scontext=system_u:system_r:unconfined_t:s0-s0:c0.c1023
sgid=0
subj=system_u:system_r:unconfined_t:s0-s0:c0.c1023 suid=0
tclass=file
tcontext=system_u:object_r:usr_t:s0 tty=(none) uid=0
"
根据这个信息提示系统建议我们使用如下命令去解决问题
#chcon -t textrel_shlib_t
/usr/java/jdk1.6.0_13/jre/lib/i386/client/libjvm.so
执行完这个命令后,重新启动eclipse,你会发现我们终于成功了.
4.为Eclipse创建一个link在桌面上.
右击图形界面——〉选择"新建启动器(New
Launcher)"——〉名称(Name)输入Eclipse——〉命令(Command)选择Eclipse解压目录/usr/java
/eclipse——〉图标(Icon)可以选择Eclipse的图标——〉点击确定完成,然后你就可以双击图形界面中的快速启动来启动你的
eclipse了,当然也可以在shell下执行eclipse根目录下的执行文件来启动eclipse!
发表评论
-
linux生成指定大小的文件
2015-08-26 16:02 1655# dd if=/dev/zero of=50M.file ... -
恢复 git reset -hard 的误操作
2014-08-30 15:10 859有时候使用Git工作得小心翼翼,特别是涉及到一些高级操作,例如 ... -
安装下载jamesAMES邮件服务器
2014-08-22 14:24 775UBUNTU下的JAMES邮件服务器 下载文件james- ... -
ubuntu james 2.3 部署
2014-08-22 14:23 797参考文章 1、需要用到很多权限和1024下的端口,用roo ... -
E: Sub-process /usr/bin/dpkg returned an error code (1)
2014-08-21 10:40 829Sub-process /usr/bin/dpkg retu ... -
Ubuntu系统如何设置vpn
2014-06-20 09:28 221因为一些原因,我们可能需要使用vpn,很 ... -
部署Exchange2007
2014-06-06 10:02 525Exchange邮件服务器是一个不错的通信消息平台, ... -
ubuntu 挂载(感觉挂载iso相当舒服)
2014-06-03 17:20 918当然首先在/media目录下先新建个文件夹当挂载点先以挂载 ... -
InputStream、OutputStream、String的相互转换
2014-06-03 17:19 5491、字符串转inputStream Java ... -
Windows XP格式化U盘为NTFS的方法
2014-06-03 10:41 742大于4G的U盘,最好将其格式化为NTFS格式,因为FAT3 ... -
google hosts
2014-05-31 11:29 250127.0.0.1localhost 127.0.1.1h ... -
google hosts
2014-05-30 18:03 4#Google Services START203.208.4 ... -
terminator 的配置
2014-05-15 09:15 1376让termintor 文字背景和ubuntu 一样 ... -
Ubuntu下安装postfix+extmail邮件服务器
2014-05-10 12:19 1777系统:ubuntu-10.04.3-server-amd64 ... -
Discuz X2.5 取消登陆密码错误15分钟限制的方法
2014-05-09 15:15 1247个人不推荐取消登录密码错误15分钟后再试的限制,就现在有限制 ... -
Ubuntu下搭建FTP服务器
2014-05-08 19:24 785后台一直提示wordperss版本和插件有更新,看着碍眼,决 ... -
Ubuntu 使用 Discuz搭建论坛
2014-05-08 19:22 7571. 安装LAMP 具体参考http://www.linu ... -
ubuntu 12.04卸载 vmware
2014-05-06 14:27 657在ubuntu 安装玩VMware 9 后,始终卸载不掉,一 ... -
ssh打洞
2014-05-04 22:41 1026目的:要求能在家里或其他外网环境访问在公司内网中我的工作电脑网 ... -
ubuntu无root权限,如何将用户添加到sudo组中去?
2014-05-04 17:21 1865最近下载了debian6.0,在vmware中安装完成之后发 ...
相关推荐
Red Hat Enterprise Linux 5的安装Red Hat Enterprise Linux 5的安装Red Hat Enterprise Linux 5的安装Red Hat Enterprise Linux 5的安装Red Hat Enterprise Linux 5的安装
Red Hat Enterprise Linux 5 安装手册详细介绍了红帽子企业版的安装过程,图片清晰,简单易懂,保证按此操作能顺利安装,让你轻松掌握Red Hat Enterprise Linux 5 安装过程。
Linux安装的详细操作步骤及注意事项。
虚拟机Red Hat Enterprise Linux 6 64位安装
Red Hat Enterprise Linux 5 安装配置 Apache + MySQL
在Red hat enterprise Linux 5上安装VMWareTools详细步骤。 上海嵌入式家园-开发板商城 联系人:贺工(嵌入式高级系统工程师) 电话: 13917077026 QQ: 844698468 MSN: embedclub@hotmail.com Email:embedclub@vip....
Red Hat Enterprise Linux 7.5版 百度网盘下载两个文件后解压
Red Hat Enterprise Linux 8.0安装(全网最详细版).docx
Red hat Linux AS4.0安Red hat Linux AS4.0安装Oracle9.2.04详细步骤2008-11-06 17:55官方论坛 http://www.oracle.com.cn tzzxcb 下面以 $ 开头的命令都是由oracle执行的 # 开头的命令都是由root执行的 一、 ...
Red Hat Enterprise Linux 7高薪运维入门 文字版 Red Hat Enterprise Linux 7高薪运维入门 文字版 Red Hat Enterprise Linux 7高薪运维入门 文字版
文件里面包含了Red Hat Enterprise Linux7-9系统镜像下载(官方镜像)
Red Hat Linux 入门指南 Red Hat Linux 入门指南 Red Hat Linux 入门指南
RedHat Linux 5企业版在VMware虚拟机上的安装做一个详细一点的图解教程,希望可以给刚接触linux的朋友一点帮助
Red Hat 系统使用 CentOS的yum源配置文件,CentOS-Base.repo,Red Hat Enterprise Linux Server release 6.8 (Santiago)测试可用, release 6.5, release 6.9应该也可以
The System Administrator's Guide documents relevant information regarding the deployment, configuration, and administration of Red Hat Enterprise Linux 7. It is oriented towards system administrators ...
red hat enterprise linux 5下安装Oracle10g red hat enterprise linux 5下安装Oracle10g red hat enterprise linux 5下安装Oracle10g
在Red Hat Enterprise Linux 5 上安装RAC环境
在Red Hat Enterprise Linux 6.0下安装Oracle 11g有很多注意点,这篇文章很详细的介绍了安装过程
Red Hat Linux 9光盘启动安装过程图解
LINUX宝典LINUX宝典LINUX宝典LINUX宝典LINUX宝典LINUX宝典