Novell Home

How can I find a file on my system?

Novell Cool Solutions: Question & Answer

Posted: 13 Jan 2005

Q:
How can I find a file on my system?

A:
At the command prompt, change to the root directory and use the 'find' command:
cd \
find . -name <FILENAME> -print
As you'll see, this command is system intensive and takes a while.

Another way is to use the 'locate' command. Run 'updatedb' first to build a database of the file locations:
updatedb
locate <FILENAME>
Though the 'updatedb' command takes a while, it only needs to be done periodically to keep the database up to date. After the database is updated , the 'locate' command is very speedy.

Many times, you can use the 'whereis' command for applications:
whereis <FILENAME>

There is also the 'which' command:
which <FILENAME>At the command prompt, change to the root directory and use the 'find' command:
cd \
find . -name <FILENAME> -print
As you'll see, this command is system intensive and takes a while.

Another way is to use the 'locate' command. Run 'updatedb' first to build a database of the file locations:
updatedb
locate <FILENAME>
Though the 'updatedb' command takes a while, it only needs to be done periodically to keep the database up to date. After the database is updated , the 'locate' command is very speedy.

Many times, you can use the 'whereis' command for applications:
whereis <FILENAME>

There is also the 'which' command:
which <FILENAME>

Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com

© 2014 Novell