Results 1 to 4 of 4
-
10-01-2003, 07:34 PM #1Web Hosting Master
- Join Date
- Aug 2003
- Posts
- 2,625
Find all files per type on a server???
I have root and want to know how to search for a particular file type throughout the server.
Similar to the DOS command line:
dir/s *.exe ----> for example would find all exe files
Thanks.SuperWebHost.com, a Digitally Justified Company
Celebrating our 9th year in Business
Proudly Hosting with CANADIAN bandwidth
Managed Hosting, Multi-Domain Hosting, Colocation, Merchant Accounts
-
10-01-2003, 11:46 PM #2Web Hosting Master
- Join Date
- May 2001
- Posts
- 1,006
locate *.exe | more
Or if want to search for a specific file and where it's located for
example http.conf then type:
locate httpd.conf
If you want to view the file use "cat" before the file.
Regards.WHO AM I? CLICK HERE!
-
10-02-2003, 03:37 PM #3Web Hosting Master
- Join Date
- Feb 2002
- Location
- Vestal, NY
- Posts
- 1,381
You can also try the "find" command ("man find"). It does not use the slocate database so you don't need to run updatedb before searching.
H4Y Technologies LLC .. Since 2001!!
"Smarter, Cheaper, Faster" - SMB, Reseller, VPS, Dedicated, Colo hosting done right.
ZERO PACKETLOSS, ZERO DOWNTIME Dedicated and Colo - USA: IA, CA, NC, OR, NV
**http://h4y.us** **http://iwfhosting.net**Voice: (866)435-5642. *** askus at host4yourself d0t com
-
10-03-2003, 07:54 PM #4Junior Guru Wannabe
- Join Date
- Aug 2002
- Posts
- 35
Why not echo the results into a file?
cd && locate -i *.php > ./phpsearch.txt
i = ignore-case ...so PHP will show up also.