软链接ln -s以及如何解决其产生“Too many levels of symbolic links ”的错误?
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了软链接ln -s以及如何解决其产生“Too many levels of symbolic links ”的错误?相关的知识,希望对你有一定的参考价值。
[[email protected] script]$ ls /etc/init.d/hadoop.sh ls: cannot access /etc/init.d/hadoop.sh: Too many levels of symbolic links [[email protected] script]$ ls /home/hadoop/script/hadoop.sh /etc/init.d/hadoop.sh ls: cannot access /etc/init.d/hadoop.sh: Too many levels of symbolic links /home/hadoop/script/hadoop.sh
解决办法:sudo 删除链接,然后补上全路径。
在做ln的时候要将文件的绝对路径下的完整目录写上去!例子如下:[[email protected] script]$ sudo rm /etc/init.d/hadoop.sh [[email protected] script]$ sudo ln -s /home/hadoop/script/hadoop.sh /etc/init.d/hadoop.sh [[email protected] script]$ /etc/init.d/hadoop.sh st /etc/init.d/hadoop.sh {start|stop|restart|status} [[email protected] script]$ /etc/init.d/hadoop.sh status 11283 ResourceManager 12323 Jps 10836 DataNode 10694 NameNode 11033 SecondaryNameNode 11610 NodeManager 11756 JobHistoryServer
本文出自 “禅剑一如” 博客,请务必保留此出处http://yanconggod.blog.51cto.com/1351649/1903566
以上是关于软链接ln -s以及如何解决其产生“Too many levels of symbolic links ”的错误?的主要内容,如果未能解决你的问题,请参考以下文章