memory-management

High kernel memory usage in Kubernetes Node

僤鯓⒐⒋嵵緔 提交于 2020-12-12 06:43:29
问题 I am pretty desperate searching for a solution to this. I am running a Kubernetes Cluster (v1.16.7) on AWS. Node specs are : It is an Amazon EC2 t3.medium instance with 4GB RAM and AMI: k8s-1.11-debian-stretch-amd64-hvm-ebs-2018-08-17 with kernel: 4.9.0-7-amd64 My main problem is that I see increased memory usage in the kernel, which leads to faster memory starvation issues in my node. More specifically: free -m : total used free shared buff/cache available Mem: 3895 3470 130 3 294 204 Swap:

Is it safe to call deleteLater right after emitting a signal with the object?

走远了吗. 提交于 2020-12-12 05:41:52
问题 I believe the following code is safe, but I have not been able to confirm it: void someMethod(Process *process) { emit signalWithProcess(process); process->deleteLater(); } I'm not sure if process still exists when the signals are called and auto or queued connections are used. For direct connections, the code above is correct because the slots are called synchronously. AFAIK, for slots on the same thread as the object, it is also correct because deleteLater() posts a new event to the object

Is it safe to call deleteLater right after emitting a signal with the object?

一世执手 提交于 2020-12-12 05:41:17
问题 I believe the following code is safe, but I have not been able to confirm it: void someMethod(Process *process) { emit signalWithProcess(process); process->deleteLater(); } I'm not sure if process still exists when the signals are called and auto or queued connections are used. For direct connections, the code above is correct because the slots are called synchronously. AFAIK, for slots on the same thread as the object, it is also correct because deleteLater() posts a new event to the object

Is it safe to call deleteLater right after emitting a signal with the object?

扶醉桌前 提交于 2020-12-12 05:41:05
问题 I believe the following code is safe, but I have not been able to confirm it: void someMethod(Process *process) { emit signalWithProcess(process); process->deleteLater(); } I'm not sure if process still exists when the signals are called and auto or queued connections are used. For direct connections, the code above is correct because the slots are called synchronously. AFAIK, for slots on the same thread as the object, it is also correct because deleteLater() posts a new event to the object

Is it safe to call deleteLater right after emitting a signal with the object?

时光毁灭记忆、已成空白 提交于 2020-12-12 05:41:00
问题 I believe the following code is safe, but I have not been able to confirm it: void someMethod(Process *process) { emit signalWithProcess(process); process->deleteLater(); } I'm not sure if process still exists when the signals are called and auto or queued connections are used. For direct connections, the code above is correct because the slots are called synchronously. AFAIK, for slots on the same thread as the object, it is also correct because deleteLater() posts a new event to the object

How to expand allocated memory in place

梦想与她 提交于 2020-12-05 20:21:22
问题 Is there something like std::realloc but do nothing if it fails to expand the existing memory (of course it will let you know it failed)? I mean truly expand in place. Not copy to a newly created memory chunk. 回答1: Contrary to what other answers say, the function you need could be provided by the C standard ibrary. It isn't for some reason or other. It was considered for an adition to the C standard, see e.g. http://www.open-std.org/JTC1/SC22/wg14/www/docs/n1527.pdf (search for try_realloc).

How to expand allocated memory in place

旧街凉风 提交于 2020-12-05 20:15:30
问题 Is there something like std::realloc but do nothing if it fails to expand the existing memory (of course it will let you know it failed)? I mean truly expand in place. Not copy to a newly created memory chunk. 回答1: Contrary to what other answers say, the function you need could be provided by the C standard ibrary. It isn't for some reason or other. It was considered for an adition to the C standard, see e.g. http://www.open-std.org/JTC1/SC22/wg14/www/docs/n1527.pdf (search for try_realloc).

How to expand allocated memory in place

心已入冬 提交于 2020-12-05 20:10:35
问题 Is there something like std::realloc but do nothing if it fails to expand the existing memory (of course it will let you know it failed)? I mean truly expand in place. Not copy to a newly created memory chunk. 回答1: Contrary to what other answers say, the function you need could be provided by the C standard ibrary. It isn't for some reason or other. It was considered for an adition to the C standard, see e.g. http://www.open-std.org/JTC1/SC22/wg14/www/docs/n1527.pdf (search for try_realloc).

How to expand allocated memory in place

别等时光非礼了梦想. 提交于 2020-12-05 20:10:25
问题 Is there something like std::realloc but do nothing if it fails to expand the existing memory (of course it will let you know it failed)? I mean truly expand in place. Not copy to a newly created memory chunk. 回答1: Contrary to what other answers say, the function you need could be provided by the C standard ibrary. It isn't for some reason or other. It was considered for an adition to the C standard, see e.g. http://www.open-std.org/JTC1/SC22/wg14/www/docs/n1527.pdf (search for try_realloc).

How to expand allocated memory in place

三世轮回 提交于 2020-12-05 20:07:58
问题 Is there something like std::realloc but do nothing if it fails to expand the existing memory (of course it will let you know it failed)? I mean truly expand in place. Not copy to a newly created memory chunk. 回答1: Contrary to what other answers say, the function you need could be provided by the C standard ibrary. It isn't for some reason or other. It was considered for an adition to the C standard, see e.g. http://www.open-std.org/JTC1/SC22/wg14/www/docs/n1527.pdf (search for try_realloc).