Date: Sun, 26 Jul 2020 10:39:16 -0500 From: Valeri Galtsev <galtsev@kicp.uchicago.edu> To: freebsd-questions@freebsd.org Subject: Re: Ask stupid questions and you'll get a stupid answers, was: Technological advantages over Linux Message-ID: <27ca8c6c-6b06-6ad4-7af0-2b88f51a3856@kicp.uchicago.edu> In-Reply-To: <20200726151835.GA35966@admin.sibptus.ru> References: <CAEJNuHxC7i%2Bq7cq65=my6mJZDdiK4gpQsKjMU1nvsm=Ri4On%2Bg@mail.gmail.com> <ce61b5e9-b71c-e5b7-c64d-f79884c87435@watters.ws> <20200725152412.GJ92589@admin.sibptus.ru> <CAGBxaX=Ktr-pqtT8FU37ajkYonVLYT_WhSenn23Tj5b=i0d-8g@mail.gmail.com> <20200725162403.GA4721@admin.sibptus.ru> <CAGBxaXmBZcCWqAZFR9OSyRGrqGFU%2BqCAZ8CfOi=0oXAmf-2=tA@mail.gmail.com> <20200725182554.deffc63058a7c9f6d343ef06@sohara.org> <04df312d-9b2b-1873-2117-79a49e089bd9@kicp.uchicago.edu> <20200726063256.GA22924@admin.sibptus.ru> <20200726093909.ee5e14e643d31da4dad5c804@sohara.org> <20200726151835.GA35966@admin.sibptus.ru>
next in thread | previous in thread | raw e-mail | index | archive | help
On 7/26/20 10:18 AM, Victor Sudakov wrote: > Steve O'Hara-Smith wrote: >> >>> FreeBSD freezes, then kills some innocent random processes like >>> local_unbound, then it may slowly recover. Sometimes it guesses >>> correctly and kills the offender (firefox most often). >> >> What else would you have it do ? Kill the largest process ? Kill >> the last process to call malloc ? There is no good response to OOM. The OS >> has no way to know which processes you care about most. > I agree, Steve. Killing a process is a bad thing always. > AFAIK the Linux OOM killer uses multiple weighted criteria to decide > which process to kill. Each process has an oom_score showing its > eligibility to be killed. > My understanding of Linux OOM killer lies along same lines though my understanding is much more simplified: kill minimal number of processes to recover maximum amount of resources. Another speculative way to say it would be: process owning maximum amount of RAM that keeps allocating more RAM is first candidate. > So at least Linux attemps intelligent killing. What about FreeBSD? > Yes, but still I have to admit: killing a process is a bad thing. But under some circumstances it is better than system unresponsive for long time. In first case you can investigate logs of what process was killed etc. In second case if you had to press power button... That said, I never had any of my FreeBSD machines unresponsive. And that refers to a bunch of servers with dozens of jails, my workstation, my laptop. That probably is why I am so ignorant about Out Of Memory situation handling by FreeBSD. Never happened to me. I must confess, these are decently large RAM machines. No swap on servers and workstation. Swap of the same size as RAM (16GB) on laptop. And I still do not consider myself lucky. Valeri -- ++++++++++++++++++++++++++++++++++++++++ Valeri Galtsev Sr System Administrator Department of Astronomy and Astrophysics Kavli Institute for Cosmological Physics University of Chicago Phone: 773-702-4247 ++++++++++++++++++++++++++++++++++++++++
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?27ca8c6c-6b06-6ad4-7af0-2b88f51a3856>