Find in files with subfolders hangs

chimsol
2014-04-16
2014-05-12
  • chimsol
    chimsol
    2014-04-16

    npp v.6.5.4
    Windows Server 2008 R2

    Searching for text in multiple files with subfolders box checked causes the program to hang within seconds and not respond. This didn't used to be a problem, but it's been happening more as the number of folders on the server increases. With the subfolders checkbox unchecked, results come up quick. Any ideas?

     
  • Loreia2
    Loreia2
    2014-04-16

    Hi chimsol,

    can you share a listing of all files in that directory, subdirs included?

    BR,
    Loreia

     
  • chimsol
    chimsol
    2014-04-16

    That's quite a big list, folders and subs total over 16,000.

     
  • Loreia2
    Loreia2
    2014-04-17

    Hi chimsol,

    N++ does not use a separate thread to search on harddrive, this might make application unresponsive if it had to search a large number of files.

    Does waiting help? Can you see results after a while, or does application hang forever?

    BR,
    Loreia

     
  • chimsol
    chimsol
    2014-04-17

    I think I gave it some time to respond but it never did. Right away it says Not Responding in the title bar. When I try to close it, I get a message box saying it is not responding. Should I just wait to see if it recovers?

     
  • StanE
    StanE
    2014-04-17

    How big are the files in overall? If you didn't it already, try to limit the searched files by using the filter input. AntiVirus program can also reduce the scanning speed. Also take into account, that the very first scan (e. g. after system start) of a folder structure is ~90% slower than all further scannings. Also the "match case" option should speed up the search, since the program doesn't need to lower case / upper case the seached file contests (but that's only my assumption). Use it if possible.

     
  • chimsol
    chimsol
    2014-04-17

    I'm filtering the file type to .asp files, not even 1MB each.

     
  • Loreia2
    Loreia2
    2014-04-21

    Hi,

    can you make a copy of the while directory and try to repeat search with just 500 files in it, then with 1000, then 5000 and finally 10.000.
    Does the application hang even with smaller number of files?
    I would like to know if the application really hangs, or it simply takes a long time.

    BR,
    Loreia

     
  • chimsol
    chimsol
    2014-04-30

    The application works fine with smaller number of files. I did a search on all files and folders and left it alone, and at first it said "not responding" but after a while came back with results. I guess the search time increases the more folders are added.

     
  • dail8859
    dail8859
    2014-05-01

    Yeah, unfortunately the "Find in Files" blocks N++ completely until the search is complete. I would love to see the search done in a background thread so you at least know N++ is still responsive.

     
  • THEVENOT Guy
    THEVENOT Guy
    2014-05-12

    Hello chimsol, dail8859, and All,

    As Dail8859, I agree that a background search in files would be an improvement !

    But, if you're "working" on one or few files, while a search in files is running, you may use the method below :

    • 1) First, move the "working" files(s) in a second instance of Notepad++, with a right click on each tab

    • 2) Then, go back to the first instance to start the desired search in files, in a big amount of files

    • 3) Finally, return to the second instance and go on modifying your preferred files !

    I, personally, did a test, searching the string the in every text file, contained in my (C:) drive, of my Win XP configuration => process of 50s, about. In the meanwhile, in the second instance of N++, I was quite able to modify some other text files and save them :-)

    Cheers,

    guy038

     
    Last edit: THEVENOT Guy 2014-05-12