[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
I am not sure if this is a bug. But the change can be very important for
From: |
Enjay Linux |
Subject: |
I am not sure if this is a bug. But the change can be very important for people using bigger media and search files on it |
Date: |
Fri, 23 Mar 2012 09:44:19 +0530 |
I am using 1-3 TB disks
Searching file is always very crucial for me and more importantly making it
more faster is always the challenge for me
with find it takes lot of time to find any file on such a big media
So I prefer to use locate to find files. No problems but
when I want to find files based on their size or modification/creation date
and time I prefer using combination of find and locate as shown below
find $(locate filename*) anyfindoption
where any filename* is any file that I am trying to find as well as
anyfindoption is the option that I use to find files by size / date / time
It all works perfectly until there are normal file names
but as and when there is a file name with spaces
find reads the output of locate in divided form
Eg. if file name is (this is my file.txt) without brackets
find will read it all as different files like this, is, my, file.txt
and so it will generate error saying
find: `/home/enjay/this': No such file or directory
find: `is': No such file or directory
find: `my': No such file or directory
find: `folder': No such file or directory
find: `/home/enjay/this': No such file or directory
find: `is': No such file or directory
find: `my': No such file or directory
find: `folder/this': No such file or directory
find: `is': No such file or directory
find: `my': No such file or directory
find: `file.txt': No such file or directory
Same thing happens if I cat the output of locate as in below eg.
cat: /home/enjay/this: No such file or directory
cat: is: No such file or directory
cat: my: No such file or directory
cat: folder: No such file or directory
cat: /home/enjay/this: No such file or directory
cat: is: No such file or directory
cat: my: No such file or directory
cat: folder/this: No such file or directory
cat: is: No such file or directory
cat: my: No such file or directory
cat: file.txt: No such file or directory
If this is the default behavior I don't have any problem as such but I
would certainly like to find files in faster way no matter if there is some
other different way to do it.
--
Thanks & Regards
*
Chaitanya Parekh
**Project Manager - ELI*
---------------------------------------------------------------------------------------------------------------------------
*Enjay IT Solutions Ltd. * 09376607650 <#> |
address@hidden
*www.enjayworld.com* *
www.enjayworld.co.in*
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- I am not sure if this is a bug. But the change can be very important for people using bigger media and search files on it,
Enjay Linux <=