lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1a91e772-4150-4d28-9c67-cb6d0478af79@redhat.com>
Date: Tue, 2 Apr 2024 11:48:16 +0200
From: David Hildenbrand <david@...hat.com>
To: Oleksandr Natalenko <oleksandr@...alenko.name>,
 linux-kernel@...r.kernel.org
Cc: vincentdelor@...e.fr, Andrew Morton <akpm@...ux-foundation.org>,
 linux-mm@...ck.org
Subject: Re: Increase Default vm_max_map_count to Improve Compatibility with
 Modern Games

On 02.04.24 09:34, Oleksandr Natalenko wrote:
> Hello.
> 
> On středa 20. března 2024 22:05:34, CEST vincentdelor@...e.fr wrote:
>> Hello,
>>
>> I am writing to highlight an issue impacting many Linux users, especially those who enjoy modern gaming. The current default setting of `vm_max_map_count` at 65530 has been linked to crashes or launch failures in several contemporary games.
>>
>> To address this, I have opened a detailed bug report (218616 – Increase Default vm_max_map_count to Improve Gaming Experience on Linux) available at: 218616 – Increase Default vm_max_map_count to Improve Gaming Experience on Linux (kernel.org) .
>>
>>
>> We have identified that several modern games such as Hogwarts Legacy, Star Citizen, and others experience crashes or fail to start on Linux due to the default `vm_max_map_count` being set to 65530. These issues can be mitigated by increasing the `vm_max_map_count` value to over 1048576, which has been confirmed to resolve the crashes without introducing additional bugs related to map handling.
>>
>> This issue affects a wide range of users and has been noted in distributions like Fedora and Pop!_OS, which have already adjusted this value to accommodate modern gaming requirements.
>>
>> For reference, here is the change for Fedora:
>> https://fedoraproject.org/wiki/Changes/IncreaseVmMaxMapCount
>>
>> Here is a list of games affected by this low value in vm_max_map_count as reported to Valve:
>>
>> THE FINALS
>> https://github.com/ValveSoftware/Proton/issues/7317#issuecomment-1974837850
>>
>> Hogwarts Legacy
>> https://github.com/ValveSoftware/Proton/issues/6510#issuecomment-1422781100
>>
>> DayZ
>> https://github.com/ValveSoftware/Proton/issues/3899#issuecomment-1304397069
>>
>> Counter-Strike 2
>> https://github.com/ValveSoftware/Proton/issues/2704#issuecomment-1705199788
>>
>>
>> **Steps to Reproduce:**
>> 1. Install Ubuntu or other distribution with `vm_max_map_count` being set to 65530 and attempt to run affected games such as Hogwarts Legacy or Star Citizen.
>> 2. Observe that the games crash or fail to start with the default `vm_max_map_count` setting.
>> 3. Modify `/etc/sysctl.conf` to include `vm.max_map_count=1048576` (or another sufficiently high value).
>> 4. Reboot the system and observe that the games now run without issue.
>>
>> **Expected Result:**
>> Games should run without crashing or failing to start due to `vm_max_map_count` limitations.
>>
>> **Actual Result:**
>> Games crash or fail to start unless `vm_max_map_count` is manually increased.
>>
>> **Suggested Fix:**
>> Increase the default `vm_max_map_count` value in Linux to a value greater than 1048576 to accommodate modern gaming software requirements.
>>
>> **Affected Games:**
>> - Hogwarts Legacy
>> - Star Citizen
>> - THE FINALS
>> - DayZ
>> - Counter-Strike 2
>> - Payday 2
>> - (and potentially others)
>>
>> **References:**
>> - Fedora's change documentation: https://fedoraproject.org/wiki/Changes/IncreaseVmMaxMapCount
>> - Various user reports and confirmations on gaming performance improvement with increased `vm_max_map_count`.
>>
>> I appreciate your time and consideration and welcome any feedback or suggestions on this matter.
>>
>> Best regards,
>>
>> Vincent DELOR
>>
>>
> 
> Adding more lists and people to Cc. This email was sent to LKML only meaning it is highly likely no one really saw it.
> 
> Andrew et al., what do you think?

Using a high VMA count usually implies that the application is doing 
something suboptimal. Having many VMAs can degrade performance of MM 
operations and result in memory waste.

Running into VMA limits usually implies that the application is not 
optimized and should handle things differently. Likely, the memory 
allocator is doing something "bad" (e.g., mmap()+munmap() instead of 
MADV_DONTNEED) and should be optimized.

I don't think we should be raising the limit for everybody out there.

-- 
Cheers,

David / dhildenb


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ