On Tue, 1 Sep 2009 10:11:42 -0400 Vivek Goyal <vgoyal@xxxxxxxxxx> wrote: > > > > - Somebody also gave an example where there is a memory hogging process and > > > > possibly pushes out some processes to swap. It does not sound fair to > > > > charge those proccess for that swap writeout. These processes never > > > > requested swap IO. > > > > I think that swap writeouts should be charged to the memory hogging > > process, because the process consumes more resources and it should get > > a penalty. > > > > A process requesting memory gets IO penalty? IMHO, swapping is a kernel > mechanism and kernel's way of providing extended RAM. If we want to solve > the issue of memory hogging by a process then right way to solve is to use > memory controller and not by charging the process for IO activity. > Instead, proabably a more suitable way is to charge swap activity to root > group (where by default all the kernel related activity goes). > I agree. It't memcg's job. (Support dirty_ratio in memcg is necessary, I think) background-write-out-to-swap-for-memory-shortage should be handled as kernel I/O. If swap-out-by-memcg bacause of its limit is a problem, dirty_ratio for memcg should be implemetned. Thanks, -Kame -- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel