Visit Counter

Monday, November 24, 2014

Find a File by Name in UNIX, Solaris, or Linux




Using the find command, one can locate a file by name.

To find a file such as filename.txt anywhere on the system:

# find  /  -name   filename.txt  -print


# find /export/home  -name  core   -print



/export/home/bsp/core
/export/home/alauddin/core
/export/home/khalil/core
/export/home/ashif/core
/export/home/rmohan/core
/export/home/arsalan/core
/export/home/edu/core
/export/home/ayman1/core
/export/home/crizaldo/core
/export/home/farooqa/core
/export/home/roger/core
/export/home/iype/core
/export/home/jamsheer/core
/export/home/farhat/core
/export/home/kamar/core
/export/home/karim/core
/export/home/khaja/core
/export/home/bokka/core
/export/home/libin/core
/export/home/ouseph/core
/export/home/moamen/core
/export/home/murali/core
/export/home/mnabil/core
/export/home/pradeep/core
/export/home/pradeepa/core
/export/home/greg/core
/export/home/ronnie/core
/export/home/muneer/core
/export/home/micheal/core
/export/home/essa/core
/export/home/anshad/core
/export/home/vinesh/core
/export/home/ummar/core
/export/home/victor/core
/export/home/waseem/core
/export/home/ajith/core
/export/home/elefatih/core
/export/home/gireesh/core
/export/home/kunhi/core
/export/home/jaison/core
/export/home/mhassan/core