错因:

没有定义JAVA_HOME 也没有jre 环境变量配置

也就是说,我们没有配置好jdk的环境变量

在双击启动apache-tomcat-8.5.31\bin\startup.bat 时,出现 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环境的问题!

注意:CLASS_PATH 中有个小点!!!

CLASS_PATH       .;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\lib\tools.jar;   JAVA_HOME        D:\Eclipse\JDK    #jdk安装目录CATALINA_BASE    E:\jarTools\apache-tomcat-8.5.31    #tomcat安装目录CATALINA_HOME    E:\jarTools\apache-tomcat-8.5.31    #tomcat安装目录

最后可以打开cmd测试以下java,java -version ,如果出现下图,代表配置成功,否则就看看你哪里打错了,或者路径问题啦!

解决问题:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined相关推荐

  1. 解决Neither the JAVA_HOME nor the JRE_HOME environment variable is defined问题

    问题描述: 在cmd窗口使用 startup 命令启动Tomcat时,出现 Neither the JAVA_HOME nor the JRE_HOME environment variable is ...

  2. pssh批量执行启动tomcat报错:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

    文章目录 问题描述 问题分析 解决问题 问题描述 我这边一共4台主机,4台主机tomca路径一致.我想想通过pssh命令工具直接将4台主机的tomcat启动,命令如下: [root@hadoop-ma ...

  3. 解决Neither the JAVA_HOME nor the JRE_HOME environment variable is defined At least one of these...问题

    文章目录 1. 复现问题 2. 分析问题 3. 解决问题 4. 总结问题 1. 复现问题 今天把前端项目部署到本地tomcat下,在双击startup.bat时的弹框一闪而过,但不知道问题出现在哪里. ...

  4. Tomcat服务器环境配置--查看bat文件(解决Neither the JAVA_HOME nor the JRE_HOME environment variable is defined问题)

    1. Tomcat环境配置 环境变量配置,博主以为无非就是在系统变量[path]中加上Tomcat目录的bin文件夹路径呗,然后上网一搜,果然就是配置Tomcat的bin目录和lib目录,于是在系统变 ...

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

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

  6. Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

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

  7. jenkins 远程启动tomcat报错:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

    异常现象: jenkins 远程启动tomcat报错:Neither the JAVA_HOME nor the JRE_HOME environment variable is defined 解决 ...

  8. Neither the JAVA_HOME nor the JRE_HOME environment variable is defined 完美解决(tomcat error)

    error: Linux下启动和关闭tomcat报错,如下图所示: Neither the JAVA_HOME nor the JRE_HOME environment variable is def ...

  9. 解决JAVA_HOME nor the JRE_HOME environment variable is defined

    从别的地方复制了一个tomcat, 启动后一闪即退, 使用记事本打开 startup.bat文件, 在文件底部修改, 并追加如下内容 call "%EXECUTABLE%" run ...

最新文章

  1. json对象和json字符串转换方法
  2. 关于文字邮件日文乱码的问题
  3. Unity3D专访——真正的面试
  4. ExcelBDD-Java开源组件发布了!
  5. 国内用户ios android比例,国内iOS、Android系统的设备总量已达到了2亿
  6. java和opencv配置_Java——OpenCVWindows配置和项目中jar包的简单配置
  7. CentOS6.x下GitLab安装
  8. hystrix 源码 线程池隔离_Hystrix源码学习--线程池隔离
  9. excel二极管伏安特性曲线_【刘敏蔷老师】半导体二极管的原理及应用
  10. 报错,> 1055 - Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggregated column
  11. 制作单机俄罗斯方块游戏总结(一)
  12. java win10 x64下载地址_javawin10 64位
  13. python怎样终止程序_python终止程序
  14. linux yum apr,CentOS安装、配置APR和tomcat
  15. 国际数棋(图形界面、网络版、AI)
  16. 淘宝双十一实时显示成交数据是怎么实现的?
  17. 高仿富途牛牛-组件化-界面美化
  18. 黑白照片转换成彩色照片(无需任何编程)
  19. 【密码学RSA】rsa_p高位泄露(2021四川省数字创新赛题)
  20. 【转载】MLC(Multi-Label Classification) 多标签分类

热门文章

  1. 往事如烟 - 42岁退休的小帅
  2. 安卓原神QQ机器人搭建教程
  3. C语言中的字符串转数字函数常见问题详解
  4. 批量提取html title,怎样批量提取网站的标题和链接呢?
  5. hadoop自定义排序,分组排序
  6. 定点运算,浮点运算,算术逻辑单元
  7. 求解“背包问题”的“粒子群算法”
  8. Linux新手入门教程(精华版)
  9. tp5实现删除服务器或本地文件和文件夹
  10. 哪个证券APP可以设置条件单?