[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: grep freezes system



30.12.2002 13:57:56, Robert.Land@t-online.de (Robert Land) wrote:

>On Sun, Dec 29, 2002 at 11:10:36PM +0100, Michael Naumann wrote:
>> I'm fairly sure, that the memory consumption of grep is quite independent
>> of the number of files/dirs to be searched. Except for transferirng
>> memory Buffers from "free" to "cached", which can again be
>> viewed as free.
>
>What makes you think this? On the first view and with my
>rather sparse knowledge I would assume this too. Grep only
>needs to extract the searched word, put it to the desired
>output, forget and look for the next files. Why should grep
>buffer anything?

I did not want to say that grep buffers anything.
Yet, depending on how you look at your system, you may observe, that
during a long running grep the amount of cached memory (as shown
by "free") will constantly increase. Ok, that of course is not
grep that does this, but rather the kernel itself.

Cheers, Michael





Reply to: