Forum › Forums › New users › New Users and General Questions › Search file system for files by text content
- This topic has 33 replies, 6 voices, and was last updated Jan 24-8:05 am by BobC.
-
AuthorPosts
-
January 20, 2023 at 4:15 pm #97811Moderator
BobC
::Searchmonkey found “geoblocked” in the .odt files without any help. It was quick, too.
Attachments:
January 21, 2023 at 6:09 am #97864Memberandfree
::Thank you all for the info.
I’m not sure if anything I installed in my computer added any functionality to searchmonkey, but it does search files by name and contents, including text files, .pdf, odt, doc and docx !
I don’t think so. About an odt file, I wrote earlier:
zzzFM also doesn’t find it. Searchmonkey does.
It finds an odt file, but then it crashes
It also finds pdf & other files, but, as I wrote, it crashes to a “Segmentation fault” when I do a search to the whole of the “Documents” folder (obviously, this folder contains something that causes this effect). If overlooking it, Searchmonkey seems to be the simplest way for a search to the totality of the files.
Please, ignore the attachment, it was just a test to see if I can attach a txt file.
- This reply was modified 3 months, 2 weeks ago by andfree.
- This reply was modified 3 months, 2 weeks ago by andfree.
- This reply was modified 3 months, 2 weeks ago by andfree.
Attachments:
January 21, 2023 at 7:23 am #97871ModeratorBobC
::run searchmonkey from a terminal and resize the windows so you can see both the output in the terminal and the searchmonkey window. Show us the search criteria by posting a screenshot before you click start. When does the error occur (immediately when you click search, after some items appear, after lots of items appear, at the end of the search, when you clink on a file the serch found?). Then do another screen print when the error occurs.
What kind of machine do you have?
Does it have enough memory?
Is it reasonably fast?
How many files are in the area you searched?
Post your full inxi output as a .txt file attachment to the post so we can see what you have. I searched 1.5TB with millions of files and I didn’t get any errors.January 21, 2023 at 8:48 am #97873Memberandfree
::Thanks for your help. The search criteria were just these ones:
Containing: garden Folders: /home/user/Documents/ Recurse foldersAfter crashing, the Searchmonkey window disappears & the terminal shows a “Segmentation fault”, as I have already posted.
But I don’t think anymore that a specific file is the culprit. I searched each subfolder separately several times and it crashed only two times, about two different subfolders, but when I repeated the search to these two subfolders, no crash happened again. I find it more possible that it has to do with the system specs.Again,Ican’tattach the full inxi output.I post it here:- This reply was modified 3 months, 2 weeks ago by andfree.
- This reply was modified 3 months, 2 weeks ago by andfree.
- This reply was modified 3 months, 2 weeks ago by andfree.
Attachments:
January 21, 2023 at 8:54 am #97877ModeratorBobC
::andfree, please post screenshots of the searchmonkey screens before clicking and when halted like I asked above so we can see exactly what was in the fields that caused it to halt. I think pressing the PrtScr or Print key should run the screenshot program.
To upload the full-inxi-output file, first rename it to full-inxi-output.txt and then the site should allow you to upload it.
January 21, 2023 at 9:09 am #97880ModeratorBobC
::How big is your Swap?
I see it is 32 bit and only has 1 gb of memory. If you can, try the same thing on a big, fast 64 bit machine to see if it still gets the error.
Maybe someone else can help figure out the segmentation fault error.
Look at my searchmonkey screenshot and check each field to see if you have similar syntax. Obviously I can’t possibly recreate your error if I don’t run the exact same search.
January 21, 2023 at 9:16 am #97881Memberandfree
::I attach the screenshot before the search. After the crash (if it happens), there’s nothing to attach, because, as I wrote, the window disappears.
Attachments:
January 21, 2023 at 9:29 am #97884Memberandfree
::How big is your Swap?
See the attachment.
I see it is 32 bit and only has 1 gb of memory. If you can, try the same thing on a big, fast 64 bit machine to see if it still gets the error.
Unfortunately, I use only old, 32 bit machines, and the other ones have only 512MB of RAM.
Look at my searchmonkey screenshot and check each field to see if you have similar syntax.
As you can see in my previous attachment, I don’t specify the “Files” field.
Attachments:
January 21, 2023 at 1:05 pm #97889ModeratorBobC
::Ok, It is a bug in the program and it happens if you use regular expression search without specifying the filename. https://sourceforge.net/p/searchmonkey/bugs/20/
I suggest using Wildcard search instead. See pics below, you need to go to Options tab and change searches to Wildcard instead of Regular expressions, then go to Settings >> Preferences >> System tab and click Save now.
Then I put an asterik in the Files field and my string in the Containing field, and specify whatever folders.
This worked on the Basic tab as well as the Advanced tab searches.
The bug was reported in 2019 it looks, but was never fixed, and I can’t tell if the author has been maintaining it since then.
I am running 0.8.3 GTK version. I might have compiled it myself, I forget. What version are you running?
- This reply was modified 3 months, 2 weeks ago by BobC. Reason: added link to bug issue
January 22, 2023 at 5:57 am #97960Memberandfree
::Many thanks for your efforts.
I am running 0.8.3 GTK version (…) What version are you running?
The same one.
change searches to Wildcard instead of Regular expressions
put an asterik in the Files field
All done, but, unfortunately, it crashes again, on both the Basic & the Advanced tab searches, at the same point of the progress. I tend to believe that insufficient memory is the cause.
January 22, 2023 at 8:41 am #97966MemberXunzi_23
::On a memory strapped system swap space is critical.
Did you ensure you have that setup correctly.
- This reply was modified 3 months, 2 weeks ago by Xunzi_23.
January 22, 2023 at 8:57 am #97968Memberandfree
::On a memory strapped system swap space is critical.
Did you ensure you have that setup correctly.
Thank you for helping me. How can I ensure it? Does the info I have attached to my #97884 post help to this?
January 22, 2023 at 9:59 am #97975ModeratorBobC
::I don’t know if swap is the problem. When you ran the inxi you attached it wasn’t being used. But we don’t know if the search was running near the point of failure then. Increasing the swap size would require reducing the size of the main partition first.
PS: I wonder if creating a larger swap FILE on your main partition might be a possibility? I’ve never tried THAT.
You might be a candidate for zram, given your 1gb memory size.
To know if you are running out of swap or memory, you would need to monitor (run htop in a window) memory and swap usage while running the search.
Maybe try searching a smaller area or restrict the types of files searched? That might tell you if the problem is related to the size of the search.
If all else fails due to lack of resources, I guess you need to use “budget” searching methods… One thing it does teach is that using fancy file formats instead of simpler text ones has a big price.
- This reply was modified 3 months, 2 weeks ago by BobC.
- This reply was modified 3 months, 2 weeks ago by BobC.
January 22, 2023 at 10:32 am #97979Memberandfree
::Thanks for the reply.
To know if you are running out of swap or memory, you would need to monitor (run htop in a window) memory and swap usage while running the search.
Unfortunately, I see nothing strange before crash.
Maybe try searching a smaller area or restrict the types of files searched? That might tell you if the problem is related to the size of the search.
As I wrote in my #97873 post:
I searched each subfolder separately several times and it crashed only two times, about two different subfolders, but when I repeated the search to these two subfolders, no crash happened again.
This was that made me think that insufficient memory and not a “bad” file causes the problem.
January 22, 2023 at 10:59 am #97987ModeratorBobC
::Are you sure you made the same changes to your settings that I made? I was also crashing with “segmentation fault”.
My best suggestion at this point is for you to double check your settings against the pics I posted for wildcard search which stopped the crashing on mine, and post screenshots of the same screens so we can double check them.
If not, it is possible the problem is related to 32 bit or something else, but that doesn’t seem likely to me.
-
AuthorPosts
- You must be logged in to reply to this topic.






