[nSLUG] Load spikes (Was: Encrypted Emails)

Mike Spencer mspencer at tallships.ca
Wed May 4 16:03:29 ADT 2016


Dop wrote:

> On Tue, 3 May 2016, Mike Spencer wrote:
> 
>> ObLinux: Still haven't figured out how to prevent multimegabyte
>> cp(1) to HD from hogging RAM, bogging down everything else.
>
> A workaround: install mbuffer from
> http://www.maier-komor.de/mbuffer.html...

Just fetched it, will have a look.

> ...and try this:
>
> tar -cf - ./source | mbuffer -r 4m -R 3m | ( cd /some/dest && tar -xvf - )
>
> This will set a max read rate of 4 megabytes per second and maximum
> write rate of 3 megabytes per second when copying ./source into
> /some/dest/.

AFAICT, that's the opposite of what I need.  I seem to have maximal
reads, hogging RAM while writes are delayed -- even to after cp exits.

But I get the point.  Reversing -r and -R values might do it.  Not
clear that this deals with the problem of the system allocating
too much buffer space to a process.  But I see that the -m switch may
be just what I need --  limits % of physical memory used by mbuffer's
buffers. 

TYVM; I'll let you know how it works out.

- Mike

-- 
Michael Spencer                  Nova Scotia, Canada       .~. 
                                                           /V\ 
mspencer at tallships.ca                                     /( )\
http://home.tallships.ca/mspencer/                        ^^-^^


More information about the nSLUG mailing list