nixCraft Linux Forum

nixCraft

Linux Tech Support Forum

finding files in linux

This is a discussion on finding files in linux within the Linux software forums, part of the Linux Getting Started category; hi! ok, whenever i type find command i get list of all files, what i want is to find specifc ...


Go Back   nixCraft Linux Forum > Linux Getting Started > Linux software

Register FAQ Members List Calendar Forgotten your password? Mark Forums Read
  #1 (permalink)  
Old 07-21-2006, 09:22 PM
Member
User
 
Join Date: Feb 2005
Posts: 66
Rep Power: 0
chiku
Default finding files in linux

hi!

ok, whenever i type find command i get list of all files, what i want is to find specifc files. hmm like music-file.mp3

how do i find such a file using find command?

plz help or give me tutorial
__________________
There's no place like 127.0.0.1
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 07-22-2006, 12:51 AM
sweta's Avatar
Contributors
User
 
Join Date: Feb 2005
Location: New Delhi
My distro: Suse, RHEL, Vista
Posts: 154
Rep Power: 4
sweta will become famous soon enough
Default

To search for files in a directory hierarchy (tree) you need to use find command. To find out file called data.txt in your home directory type command:
Code:
find data.txt
find $HOME -name data.txt
More about command:
http://www.cyberciti.biz/nixcraft/vi...with-find.html
http://www.cyberciti.biz/nixcraft/vi...h-find_23.html
__________________
Friends - v-nessa - missyAdmin - LinuxChix
Reply With Quote
  #3 (permalink)  
Old 08-03-2006, 10:23 AM
Junior Member
 
Join Date: Aug 2006
Posts: 3
Rep Power: 0
tungsten
Default

#find . / -name filename -print

eg.
to find file with name text.txt

#find . / -name text.txt -print

This will search through all filesystem for the file text.txt and list its location
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
View log files under Linux sweta Getting started tutorials 0 05-30-2007 01:31 AM
Linux Finding Files Irrespective of Case chiku Linux software 1 01-16-2007 09:36 PM
Finding machines S/N and Model Type mlperry Linux software 3 10-05-2006 11:15 PM
script finding file and sorting dementeddude Shell scripting 14 07-25-2006 06:30 PM
shell script for finding users not logged on for last 10 day ganes Shell scripting 4 07-06-2005 12:01 PM


All times are GMT +5.5. The time now is 03:40 AM.


Powered by vBulletin® Version 3.7.4 - Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36