[lug] Tools to navigate Unix links backwards?
bgiles
bgiles at coyotesong.com
Mon Jul 26 09:30:30 MDT 2010
On 07/23/2010 09:36 AM, Vince Dean wrote:
> I've inherited a system that depends on a complicated directory
> structure with multiple links, both hard and symbolic, to some of the
> files and directories.
>
I don't know if this has already been mentioned but you can find hard
links with
find / -type f -links +1 -ls
The -ls gives you the inode. Sort on that and all hard links are
grouped together. You definitely want to remember to specify regular
files only - every directory has a link count over 1. Special files
also commonly have hard links.
Symlinks are trivial to find, of course
find / -type l
Bear
More information about the LUG
mailing list