“CABUORCH-1697”的版本间的差异
来自qingwei personal wiki
(→问题) |
(→在NSO docker安装ntool) |
||
第20行: | 第20行: | ||
yum install ant | yum install ant | ||
+ | # 安装ntool, 将ntool 拷贝到下面目录 | ||
+ | cd /mnt/datafs/ncs-run/packages | ||
+ | make -C ntool/src clean all | ||
</source> | </source> | ||
+ | |||
=== 问题 === | === 问题 === | ||
<source lang="shell"> | <source lang="shell"> |
2018年5月28日 (一) 07:29的版本
描述
Investigation: CLI to XML Conversion for NSO
tool
https://github.com/NSO-developer/ntool
在NSO docker安装ntool
# 修改 repo
# editing both /etc/yum.repos.d/epel.repo and /etc/yum.repos.d/epel-testing.repo files, commenting all entries starting with mirrorlist=... and uncommenting all the entries starting with baseurl=....
# 配置代理
bash-4.2# export http_proxy=http://proxy-wsa.esl.cisco.com:80
bash-4.2# export https_proxy=http://proxy-wsa.esl.cisco.com:80
bash-4.2# env | grep proxy
http_proxy=http://proxy-wsa.esl.cisco.com:80
https_proxy=http://proxy-wsa.esl.cisco.com:80
# 安装 make
yum install make
# 安装 ant
yum install ant
# 安装ntool, 将ntool 拷贝到下面目录
cd /mnt/datafs/ncs-run/packages
make -C ntool/src clean all
问题
/usr/bin/ant: Failed to set JAVACMD
Error: JAVA_HOME is not defined correctly.
We cannot execute /usr/bin/java/bin/java
make: *** [javac] Error 1
make: Leaving directory `/mnt/datafs/ncs-run/packages/ntool/src'
# JAVA_HOME配置错误
# 找到Jdk 位置,修改JAVA_HOME
bash-4.2# find /usr/ -name *jdk* -type d
/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.151-1.b12.el7_4.x86_64
/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.171-8.b10.el7_5.x86_64
/usr/lib/jvm-exports/java-1.8.0-openjdk-1.8.0.171-8.b10.el7_5.x86_64 #用这个jdk
# export JAVA_HOME
bash-4.2# export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.171-8.b10.el7_5.x86_64