Jenkins构建提示:

[SSH] executing...
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program

解决办法:

  方法1:直接在在脚本前添加java环境变量

  方法2:如果是在 /etc/profile 中导入的环境变量,那么在/root/.bashrc中加入相同环境变量

  

export JAVA_HOME=/root/jdk/jdk1.8.0_171
export PATH=$JAVA_HOME/bin:$PATH
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
export JRE_HOME=$JAVA_HOME/jre

  

  

Jenkins启动Tomcat时提示Neither the JAVA_HOME nor the JRE_HOME environment variable is defined的更多相关文章

  1. tomcat启动报错:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined At least one of these environment variable

    linux 下 启动tomcat 报: Neither the JAVA_HOME nor the JRE_HOME environment variable is definedAt least o ...

  2. tomcat启动报错:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

      windows系统: 部署了一个Tomcat8.5.15,bin目录下startup.bat执行,结果提示Neither the JAVA_HOME nor the JRE_HOME enviro ...

  3. Tomcat问题:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined ,At least one of these environment variable is needed to run this program

    一眼就能看出来是jdk的环境有问题,但是用了这么久的jdk一直都配置的好好的,怎么一到Tomcat上就这么矫情了. 最后查解决方案,原来是我的jdk从官网直接下载的,虽然我修改了java_home,但 ...

  4. linux tomcat启动报错:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

    解决方法: 1.先找出java安装路径 $ which java /data/apps/java/jdk1.8.0_91/bin/java 2.在catalina.sh中加入配置 JAVA_HOME= ...

  5. [转]Tomcat----Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

    对于使用IDE开发的程序员来讲,并不是所有人都对自己用来吃饭的工具了如指掌.常在阴沟跑,哪能不翻船.为此我把自己使用Tomcat/Eclipse的一些经验教训整理了一下,会陆续的贴出来,也许会帮到和我 ...

  6. 启动tomcat 报错:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

    [root@localhost META-INF]# systemctl start tomcat Job for tomcat.service failed because the control ...

  7. CentOS Tomcat启动 Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

    链接:http://blog.csdn.net/shangdiyisi/article/details/9477521 [bravoinfo@bravoinfo-hk-01 apache-tomcat ...

  8. linux安装tomcat Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

    这两天我们的开发机重启了好几次,发现每次重启后我的tomcat总是没有启动.检查java路径,配置正确,后来拿普通账号启动tomcat时报如下的错: Neither the JAVA_HOME nor ...

  9. Java项目启动时候报Neither the JAVA_HOME nor the JRE_HOME environment variable is defined 解决办法

    今天在发布Java项目的时候又遇到    Neither the JAVA_HOME nor the JRE_HOME environment variable is defined  At leas ...

随机推荐

  1. 熟练使用Linux系统信息类命令

    系统信息类命令 – dmesg命令 dmesg命令用实例名和物理名称来标识连到系统上的设备. dmesg命令显示系统诊断信息.操作系统版本号.物理内存大小以及其他信息. 系统启动时,屏幕上会显示系统C ...

  2. C++ - memset的效率和源码分析

      void *memset(void *s, int ch, size_t n); 作用:将s所指向的某一块内存中的每个字节的内容全部设置为ch指定的ASCII值, 块的大小由第三个参数指定,这个函 ...

  3. 【理论】python使用celery异步处理请求

    Flask中使用celery队列处理执行时间较长的请求. 一. 安装celery pip install celery flask redis 二. celery简介 Celery是个异步分布式任务队 ...

  4. snmp获取设备相关管理信息

    在本文中,作者将向我们展示如何用snmp代理监视网络设备,甚至发送软件警告. 网络上很多代理在为我们服务.只要我们开启UDP/161,162端口,这些代理就会以Management Informati ...

  5. 方便好使的java.util.Properties类

    今天偶然碰到这个类,发现jdk中这些平时不大用到的类还挺好玩儿的,用起来也特别实在方便,随便写点记录下. java.util.Properties是对properties这类配置文件的映射.支持key ...

  6. SQL中INNER JOIN的用法

    SQL join 用于根据两个或多个表中的列之间的关系,从这些表中查询数据. Join 和 Key 有时为了得到完整的结果,我们需要从两个或更多的表中获取结果.我们就需要执行 join. 数据库中的表 ...

  7. DOCKER windows 7 详细安装教程

    DOCKER windows安装 编者: xiaym 日期:2015年1月20日 排版工具: 马克飞象 QQ: 252536711 DOCKER windows安装 1.下载程序包 2. 设置环境变量 ...

  8. 记一次 .net core publish 之后找不到视图文件的问题

    周末将VS从15.3 升级到15.5 ,之后又将VS版本由社区版,升级为企业版. 于是问题来了: 项目publish 之后找不到视图文件了??? 问题很是蛋疼,后来仔细想了一下,也没有动什么东西.查看 ...

  9. linux之cut

    [linux之cut] -b:字节 -c:字符 -d:自定义域 -f:域范围 参考:http://wenku.baidu.com/view/9399bc8383d049649b66588b.html

  10. synchronized的简单理解

    synchronized能够保证在同一时刻只有一个线程执行该段代码. 使用synchronized能够防止多个线程同时并发访问程序的某些资源. synchronized既可以修饰变量,也可以修饰方法, ...