Quantcast
Channel: How can I find broken symlinks - Unix & Linux Stack Exchange
Viewing all articles
Browse latest Browse all 14

Answer by ArturZ for How can I find broken symlinks

$
0
0

find . -xtype l will skip broken links pointing to files in inaccessible directories. You can just search for links to inaccessible files:

find . -type l ! -readable

This works correctly for cyclic symlinks and is also more efficient than using -exec test … with find command.


Viewing all articles
Browse latest Browse all 14

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>