[root@izm5eab8t820b79js38tbxz ~]# java -version
-bash: java: command not found

出现上面问题,解决方法:

[root@izm5eab8t820b79js38tbxz ~]# source /etc/profile

  最后在测试是否安装成功:

[root@izm5eab8t820b79js38tbxz ~]# java -version
java version "1.8.0_241"
Java(TM) SE Runtime Environment (build 1.8.0_241-b07)
Java HotSpot(TM) 64-Bit Server VM (build 25.241-b07, mixed mode)
[root@izm5eab8t820b79js38tbxz ~]# 

 

相关文章:

  • 2021-05-15
  • 2021-07-09
  • 2021-08-23
  • 2021-04-06
  • 2021-06-09
  • 2021-09-10
猜你喜欢
  • 2021-08-19
  • 2022-12-23
  • 2021-09-05
  • 2021-07-17
  • 2021-07-22
  • 2021-08-11
  • 2021-10-11
相关资源
相似解决方案