Linux中‘aclocal-1.15‘ is missing on your system

9 篇文章 0 订阅
在部署分布式存储系统MFS时,遇到make阶段aclocal-1.15命令缺失的错误。问题分析发现是automake版本过低。通过升级automake和autoconf,解决了这个问题。升级过程中遇到了权限、版本不匹配和文件上传顺序导致的问题,最终成功升级并完成安装。
摘要由CSDN通过智能技术生成

与我遇到的问题类似,先抄于此:

因业务需要部署分布式存储,新分配了三台RHE机器,在部署安装MFS时,make阶段出现以下错误提示:
错误提示:

CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/sh /home/agssvYX/moosefs-3.0/moosefs-3.0/missing aclocal-1.15 -I m4
/home/agssvYX/moosefs-3.0/moosefs-3.0/missing: line 81: aclocal-1.15: command not found
WARNING: 'aclocal-1.15' is missing on your system.
         You should only need it if you modified 'acinclude.m4' or
         'configure.ac' or m4 files included by 'configure.ac'.
         The 'aclocal' program is part of the GNU Automake package:
         <http://www.gnu.org/software/automake>
         It also requires GNU Autoconf, GNU m4 and Perl in order to run:
         <http://www.gnu.org/software/autoconf>
         <http://www.gnu.org/software/m4/>
         <http://www.perl.org/>
make: *** [aclocal.m4] Error 127
问题分析:
1.找不到aclocal-1.15命令,有可能是没有权限访问这个命令,也有可能路径没有搜索到,也可能是根本没有安装这个程序,执行命令:sudo find / -name aclocal,能找到aclocal在/usr/share/aclocal和/usr/bin/aclocal
2.经查aclocal属于automake的一部分,关于aclocal的解释见:http://www.adp-gmbh.ch/misc/tools/configure/aclocal.html ,它主要在进行makefile时,用来定义文件放置的地方,会产生autom4te.cache和aclocal.m4这两个文件,但是错误中是说aclocal-1.15找不到,会不会是版本问题,执行命令:aclocal --version,发现:aclocal (GNU automake) 1.11.1,也就是说系统版本有点低
3.接下来有两种方案:第一,修改makefile中的执行版本,第二,升级系统版本。先尝试第一方案,找到Makefile进行搜索:/aclocal,找到:ACLOCAL = ${SHELL} /home/agssvYX/moosefs-3.0/moosefs-3.0/missing aclocal-1.15,本打算修改下,但看到:# Makefile.in generated by automake 1.15.1 from Makefile.am.,也就是说Makefile是由automake1.15生成的,执行命令:automake --version,提示:automake (GNU automake) 1.11.1,至此找到关键性问题:automake版本太低

升级automake
1.下载automake-1.15, ftp://ftp.gnu.org/gnu/automake/automake-1.15.tar.gz
2.执行命令:./configure --prefix=/usr/local/automake-1.15,提示错误:configure: error: Autoconf 2.65 or better is required.
3.查看autoconf版本:autoconf --version,提示:autoconf (GNU Autoconf) 2.63,即是autoconf版本过低

升级autoconf
1.下载autoconf-2.65,http://ftpmirror.gnu.org/autoconf/autoconf-2.65.tar.gz
2.执行命令:./configure --prefix=/usr/local/autoconf-2.65,然后执行:sudo make,提示:sh: build-aux/git-version-gen: Permission denied autom4te: /usr/bin/m4 failed with exit status: 1 aclocal-1.11: autom4te failed with exit status: 1,对build-aux/git-version-gen进行赋权:sudo chmod 777 build-aux/git-version-gen,再次执行:sudo make&&sudo make install没有问题
3.卸载旧版本autoconf:sudo rpm -e --nodeps autoconf-2.59,创建软链:sudo ln -s /usr/local/autoconf-2.65/bin/autoconf /usr/bin/autoconf,赋权:sudo chmod 777 -R /usr/local/autoconf-2.65,sudo chmod 777 /usr/bin/autoconf
4.查看autoconf版本:autoconf --version,提示:autoconf (GNU Autoconf) 2.65,升级成功
5.回到automake,进行sudo make,出现错误:Can't locate /aclocal in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) ,好一顿搜索发现原来是因为先解压后上传服务器导致的
6.上传automake-1.15压缩包,然后进行解压,执行:./configure --prefix=/usr/local/automake-1.15&&sudo make&&sudo make install完成安装
7.卸载旧版本的automake:sudo rpm -e --nodeps automake,创建软链:sudo ln -s /usr/local/automake-1.15/bin/automake /usr/bin/automake,赋权:sudo chmod -R 777 /usr/local/automake-1.15/,sudo chmod 777 /usr/bin/automake
8.查看automake版本:automake --version,提示:automake (GNU automake) 1.15,升级成功
————————————————
版权声明:本文为CSDN博主「Angryshark_128」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/weixin_42078760/article/details/88059619

  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值