Adding swap didn't work. There is no rule when problem appears. It can wait weeks. It can appear twice in day. Most of times it will exist any time long, before i will reboot server. Rarely it can cure itself without reboot. On a 2GB machine with 2. It is sometimes possible to avoid the condition when allocating gradually, and it does not occur at all when the allocations are in a single process.
This test case was created to resemble the launch of a multiprocess web browser with several tabs open, which is where I first heard about the issue. Reproducing with the web browser was less predictable but still possible. I've run about a dozen tests so far, and have not been able to trigger the condition except possibly one time the first time , whereas I can trigger it every time under the unpatched kernel. I didn't give kswapd any time to recover on its own I was expecting the old behaviour , so I don't know if it would have done so without the additional allocation.
I have not seen any similar behaviour since that first test, but will be doing more testing today, and will update again if I do. I'm using arch linux with kernel 4. Where I work, we're currently on Linux 3. Various things we've read says that it might be related to kernel memory fragmentation.
In some cases, disabling NUMA might help. We also changed our databases to use directio ie. Doesn't thrash Linux virtual memory doing useless buffering for a database server that already does it's own caching. The weird thing is memory and swap both aren't that full. It seems like Google Docs is the worst offender for triggering this issue. Also in my case I had no swap, and sufficient free memory.
Would be interested to know if this works for you. Comment 9 serianox UTC same problem here, cp chromebook , happens on several different distros like arch, ubuntu, xubuntu. I downgraded to the 4. Linux localhost 4. Apparently, I compiled out something causing the trouble, but I didn't try to bisect what was the culprit.
This bug seems to affect 2Gb models only. Do you have the 2Gb or 4Gb version? What are the changes you made on your kernel? Even today, if I boot stock arch kernel, the bug regresses; if I boot linux-c, kswapd0 is still. In theory, I could experiment with different configurations in between stock's and mine to triage the issue. I was happy with performance. Until today. I noticed lags. For some reason this bug appeared suddenly. There was no update. Kernel version is 3. Stock ChromeOS kernel.
If you don't have any memory problem and use the free command, you will see so much memory used as cache, but if you have a memory problem, Linux reduce the cache for serve the memory allocation requests, without any need to drop cache you can use sar -B and looking for majft and pgscank values, for other values man sar. Krischna Gabriel 3 2 2 bronze badges. What are sar majft and pgscank?
I couldn't find them on my machine or in my package manager pacman. Seems pretty normal to me. Zaz You need to install it then. I added the information to my question. Thanks for the help! Doesn't seem to make any difference. Did you do 1st item in the list above? Add this to your Dockerfile. The question is, if you ran ever out of memory, or have to change swappiness or a less swapping factor, i. As A value of 0 instructs the kernel not to initiate swap until the amount of free and file-backed pages is less than the high water mark in a zone.
Reference: kernel. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Does ES6 make JavaScript frameworks obsolete? Podcast Do polyglots have an edge when it comes to mastering programming Featured on Meta.
Re: kswapd0 must die Finally I solved this issue by compiling a custom kernel. I cannot say for sure which option fixed the problem, so I will post my kernel configuration here in the hopes that someone who knows more about it can figure it out.
Essentially, I am saying that out-of-control kswapd0, which seems to be a common problem, is a bug in the kernel, but I do not know how to triage or diagnose this bug. Incidentally, I did not compile a custom kernel for this purpose, but to handle another problem with DMA zones that affects my emu10k1's hardware MIDI synthesizer.
I do not think the issues are related in any way. My custom kernel configuration, in which kswapd0 does not go wild: Code:. December 2nd, 8. I intentionally gave no further information. I don't want to find out what's going on; I just want to know how to kill it if that is in fact possible. How can I terminate the kswapd0 process?
0コメント