Skip to main content
The 2026 Annual Developer Survey is live— take the Survey today!

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

15
  • 1
    Definitly the Dr01d I was lookin' for^^ Thank you a whole lot for your dedicated answer. Commented Sep 24, 2021 at 10:28
  • The suggested feature request is underway in form of a pull request to their feature_request.md which I have accordingly changed. Though, I am not 100 % sure, this is the way they want to receive their feature requests. Anyhow, I went with your last approach, before testing what adding sysctl -w vm.max_map_count=262144 as a line directly in etc/profile under wsl -d docker-desktop could do, expecting it to be read on docker-desktop startup before any container is started, as docker-desktop itself is listed as a distro under wsl --list. Commented Sep 24, 2021 at 10:42
  • Hence, I considered that whenever Docker-Desktop is started, it might read /etc/profile of this distro going by the same name. Thereagainst, /etc/profile appears not to be read when starting docker-desktop. Notably, it is read and effectively changes mmap-count when starting wsl -d docker-desktop similar to the result of your last approach when starting the seperate WSL (e. g. openSUSE Leap 15.2^^). Isn't it the way, that docker-desktop itself starts the wsl distro docker-desktop and hence should just as well read this profile and set the mmap-count defined within it? Commented Sep 24, 2021 at 10:52
  • @ToOolzZz Not necessarily. Docker Desktop is likely starting up as a non-interactive, non-login shell, perhaps not intentionally, but because they pass commands to it through wsl when they start it up. For instance, if you do wsl -e bash -c "echo 1", the 1 will be output, but it will not read /etc/profile because it is not a login shell. Commented Sep 24, 2021 at 17:56
  • 1
    Yes, I precautiously articulated my test result, not to oppose it completely against this statement regarding the minimum Windows build in the doc under link provided in my comment. I have the impression that .wslconfig is older than build 19041 as apparently is this kernelCommandLine-key in it. But maybe, they refer to at least one other .wslconfig-key which will not be functional in an older build. Commented Sep 28, 2021 at 18:33