Solved

Searching for soft-links

Posted on 2001-06-05
4
293 Views
Last Modified: 2010-04-21
Hi.  Can someone show me how to search my directory and all subdirectories for soft-links?

-Alex
0
Comment
Question by:Alex_Tong
4 Comments
 
LVL 38

Accepted Solution

by:
yuzh earned 10 total points
Comment Utility
Hi  Alex_Tong,

   You cd to you home directory, then type in the following
command:

   find . -type l -print

   this will print all the soft-links file on your screen,
you can save this list to a file use:
   find .

   . stand for the current dir. If you login as ROOT, you
can print all the soft-links in your system use:

   find / -type l -print


   
0
 
LVL 6

Expert Comment

by:Talmash
Comment Utility
hi ,

in addition :

try :
ls -l | grep lrwx at each directory :

ls -l * | grep lrwx
ls -l */* | grep lrwx
ls -l */*/* | grep lrwx
ls -l */*/*/* | grep lrwx
ls -l */*/*/*/* | grep lrwx

etc..

but this for certain deep tree .

Tal
0
 
LVL 5

Expert Comment

by:Nisus091197
Comment Utility
... or ls -lR | grep '^lrwx'

using find is the best way.

Regards, Nisus.
http://www.omnimodo.com
0
 

Expert Comment

by:saila
Comment Utility
if you searching soft links in all the dirs the u can use

find / -type l -ls | more

if u are searching for a particular file  the
find / -type l -ls | grep filename
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Hello fellow BSD lovers, I've created a patch process for patching openjdk6 for BSD (FreeBSD specifically), although I tried to keep all BSD versions in mind when creating my patch. Welcome to OpenJDK6 on BSD First let me start with a little …
I have been running these systems for a few years now and I am just very happy with them.   I just wanted to share the manual that I have created for upgrades and other things.  Oooh yes! FreeBSD makes me happy (as a server), no maintenance and I al…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now