Re: Balloon pressuring page cache

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

 



On 04.02.20 09:40, Michael S. Tsirkin wrote:
> On Tue, Feb 04, 2020 at 09:35:21AM +0100, David Hildenbrand wrote:
>>>>> I would say reverting probably makes sense. I'm not sure there is much
>>>>> value to having a shrinker running deflation when you are actively trying
>>>>> to increase the balloon. It would make more sense to wait until you are
>>>>> actually about to start hitting oom.
>>>>
>>>> I think the shrinker makes sense for free page hinting feature
>>>> (everything on free_page_list).
>>>>
>>>> So instead of only reverting, I think we should split it up and always
>>>> register the shrinker for VIRTIO_BALLOON_F_FREE_PAGE_HINT and the OOM
>>>> notifier (as before) for VIRTIO_BALLOON_F_MUST_TELL_HOST.
>>
>> s/VIRTIO_BALLOON_F_MUST_TELL_HOST/VIRTIO_BALLOON_F_DEFLATE_ON_OOM/
>>
>> :)
> 
> Well VIRTIO_BALLOON_F_MUST_TELL_HOST is also broken by shrinker
> with VIRTIO_BALLOON_F_FREE_PAGE_HINT as that code adds buffers
> but does not wait for them to be used even with VIRTIO_BALLOON_F_MUST_TELL_HOST.
> We never noticed because QEMU does not advertize
> VIRTIO_BALLOON_F_MUST_TELL_HOST.

Will try to figure out how to best undo this mess :)

> 
> 
>>>>
>>>> (Of course, adapting what is being done in the shrinker and in the OOM
>>>> notifier)
>>>
>>> David,
>>>
>>> Please keep me posted. I decided to adapt the same solution as the virtio
>>> balloon for the VMware balloon. If the verdict is that this is damaging and
>>> the OOM notifier should be used instead, I will submit patches to move to
>>> OOM notifier as well.
>>
>> Will do. It all sounds sub-optimal to me at this point ... but I prefer
>> the old variant where a simple "drop_slab()" won't deflate the balloon.
>> That looks broken to me.
> 
> Okay. Could you post a patch?

I can give it a shot.

-- 
Thanks,

David / dhildenb

_______________________________________________
Virtualization mailing list
Virtualization@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linuxfoundation.org/mailman/listinfo/virtualization



[Index of Archives]     [KVM Development]     [Libvirt Development]     [Libvirt Users]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux