0

I am experiencing an issue with a indexing program running much longer than expected. I want to rule out the possibility of a recursive symbolic link. How could I find a symbolic link that is recursive at some level?

Steven C. Howell
  • 467
  • 1
  • 6
  • 14
  • 5
    [previously](http://unix.stackexchange.com/questions/99159/is-there-an-algorithm-to-decide-if-a-symlink-loops), [previously](http://unix.stackexchange.com/questions/79571/symbolic-link-recursion-what-makes-it-reset) – Jeff Schaller Apr 18 '16 at 01:46
  • @JeffSchaller, The first link does detect recursive symbolic links. Thank you for pointing me to that. I saw the second question you linked before posting this question. That does not provide a way to find such a link. – Steven C. Howell Apr 18 '16 at 02:29

1 Answers1

7

This related question, provides a way to identify a recursive symbolic link using the find command:

$ find -L . 
.
./a
./a/b
./a/b/c
./a/b/c/d
find: File system loop detected; `./a/b/c/d/e' is part of the same file system loop as `./a/b'.
find: `./a/b/e': Too many levels of symbolic links
Steven C. Howell
  • 467
  • 1
  • 6
  • 14