readlink

Command that prints symbolic links. In easy words, it will print a real link location, or location at which that link points at. It shows the real path of the symbolic links, and also follows them recursively.

In the example below, link2 points to link1, link3 points to link2, and link4 points to link3. Since we have used recursive argument -f, readlink will find link4 and go to its location, once found, he follows the path to link2, then from link2 to link1 and it is dead end or final path.

# readlink -f link4

Leave a Reply