- 浏览: 251089 次
- 性别:
- 来自: 大连
文章分类
最新评论
-
红小豆:
Criteria和Detachedcriteria的区别及应用 -
fjjiaboming:
那就稍微翻译一下 啊....
Mysql autoReconnect 的问题 -
woyaowenzi:
非常感谢,我正想做一个画线的控件,就和windows的画图板一 ...
一个简单的FLEX画图demo -
guzen:
可以用一下flash builder 4,现在支持绝对定位了, ...
how to use flex layouts -
suifeng:
好!
一个简单的FLEX画图demo
Since this problem seems to popup on different lists, this message has
been cross-posted to the general Red Hat discussion list, the RHEL3
(Taroon) list and the RHEL4 (Nahant) list. My apologies for not having
the time to post this summary sooner.
I would still be banging my head against this problem were it not for
the generous assistance of Tom Sightler <ttsig@xxxxxxxxxxxxx> and Brian
Long <brilong@xxxxxxxxx>.
In general, the out of memory killer (oom-killer) begins killing
processes, even on servers with large amounts (6Gb+) of RAM. In many
cases people report plenty of "free" RAM and are perplexed as to why the
oom-killer is whacking processes. Indications that this has happened
appear in /var/log/messages:
Out of Memory: Killed process [PID] [process name].
In my case I was upgrading various VMware servers from RHEL3 / VMware
GSX to RHEL4 / VMware Server. One of the virtual machines on a server
with 16Gb of RAM kept getting whacked by the oom-killer. Needless to
say, this was quite frustrating.
As it turns out, the problem was low memory exhaustion. Quoting Tom:
"The kernel uses low memory to track allocations of all memory thus a
system with 16GB of memory will use significantly more low memory than a
system with 4GB, perhaps as much as 4 times. This extra pressure
happens from the moment you turn the system on before you do anything at
all because the kernel structures have to be sized for the potential of
tracking allocations in four times as much memory."
You can check the status of low & high memory a couple of ways:
# egrep 'High|Low' /proc/meminfo
HighTotal: 5111780 kB
HighFree: 1172 kB
LowTotal: 795688 kB
LowFree: 16788 kB
# free -lm
total used free shared buffers cached
Mem: 5769 5751 17 0 8 5267
Low: 777 760 16 0 0 0
High: 4991 4990 1 0 0 0
-/+ buffers/cache: 475 5293
Swap: 4773 0 4773
When low memory is exhausted, it doesn't matter how much high memory is
available, the oom-killer will begin whacking processes to keep the
server alive.
There are a couple of solutions to this problem:
If possible, upgrade to 64-bit Linux. This is the best solution because
*all* memory becomes low memory. If you run out of low memory in this
case, then you're *really* out of memory. ;-)
If limited to 32-bit Linux, the best solution is to run the hugemem
kernel. This kernel splits low/high memory differently, and in most
cases should provide enough low memory to map high memory. In most
cases this is an easy fix - simply install the hugemem kernel RPM &
reboot.
If running the 32-bit hugemem kernel isn't an option either, you can try
setting /proc/sys/vm/lower_zone_protection to a value of 250 or more.
This will cause the kernel to try to be more aggressive in defending the
low zone from allocating memory that could potentially be allocated in
the high memory zone. As far as I know, this option isn't available
until the 2.6.x kernel. Some experimentation to find the best setting
for your environment will probably be necessary. You can check & set
this value on the fly via:
# cat /proc/sys/vm/lower_zone_protection
# echo "250" > /proc/sys/vm/lower_zone_protection
To set this option on boot, add the following to /etc/sysctl.conf:
vm.lower_zone_protection = 250
As a last-ditch effort, you can disable the oom-killer. This option can
cause the server to hang, so use it with extreme caution (and at your
own risk)!
Check status of oom-killer:
# cat /proc/sys/vm/oom-kill
Turn oom-killer off/on:
# echo "0" > /proc/sys/vm/oom-kill
# echo "1" > /proc/sys/vm/oom-kill
To make this change take effect at boot time, add the following
to /etc/sysctl.conf:
vm.oom-kill = 0
For processes that would have been killed, but weren't because the oom-
killer is disabled, you'll see the following message
in /var/log/messages:
"Would have oom-killed but /proc/sys/vm/oom-kill is disabled"
Sorry for being so long-winded. I hope this helps others who have
struggled with this problem.
发表评论
-
redhat as5.4 安装网站截图软件CutyCapt
2012-02-23 09:21 2042先安装Qt47 Java代码 收藏代码 增加qt4 ... -
linux中将前台进程转入后台的方法
2011-09-07 17:31 2722今天在网上偶然看到一个不错的建议。先更新一下: 以前在使用no ... -
Vnstat: 简单实用的网络流量统计工具
2011-05-18 22:02 1430http://www.linuxeden.com/html/s ... -
视频网站架构
2011-01-23 01:01 1541http://www.doorsolutions.cn/ 概述 ... -
how to install ffmpeg
2011-01-23 00:33 1507A little while back, I posted a ... -
CentOS安装MPlayer
2010-05-31 14:36 1481http://wiki.centos.org/TipsAndT ... -
linux下tomcat启动80端口不能访问的问题
2009-06-15 21:18 7044service iptables save [code=&a ... -
Understanding memory usage on Linux
2009-06-12 10:50 1131This entry is for those people ... -
上传文件到linux时出现的乱码
2009-04-30 16:32 2102遇到见很郁闷的事。 维护一个很老的代码,编码都是gbk的,别 ... -
gdb 使用手册
2009-04-28 16:46 2060简述 一 列文件清单 二 ... -
OOM 机制
2009-03-26 21:40 1184When a system runs out of memor ... -
A Quick Benchmark: Gzip vs. Bzip2 vs. LZMA
2009-03-09 09:50 1452How the test files were selecte ... -
linux 网络配置
2009-03-03 15:54 1129网络信息查看 查看网路接口信息 1.了解lin ... -
linux下删除文件出错
2009-01-12 16:27 2043今天忘记把程序停止, ... -
linux下自动备份mysql数据库
2009-01-12 16:22 1096新建文件: vi /home/bzhang/mysql_aut ... -
计划任务工具 cron 的配置和说明
2009-01-12 10:01 1062计划任务工具 cron 的配置和说明 作者: 北南南 ... -
用vsFTPd自架Linux网络安装服务器,以及Redhat局域网安装的解决办法
2009-01-05 12:06 1282ZZ FROM: http://www.linuxsir.or ... -
Clock in a Linux Guest Runs More Slowly or Quickly
2009-01-04 10:55 2046Clock in a Linux Guest R ... -
IPTABLE 学习
2008-12-30 15:40 936To be continued... -
VSFTP的时间错误
2008-12-30 10:31 820vsftp的配置问题 /etc/vsftpd/vsftpd.c ...
相关推荐
ANDROIDBITMAP内存限制OOM,OUTOFMEMORY.pdf
ANDROIDBITMAP内存限制OOM,OUTOFMEMORY[文].pdf
Android 加载大图及多图避免程序出现OOM(OutOfMemory)异常 1、高效加载大图片 我们在编写Android程序的时候经常要用到许多图片,不同图片总是会有不同的形状、不同的大小,但在大多数情况下,这些图片都会大于我们...
OOM分析工具-MemoryAnalyzer JVM dump分析利器
NULL 博文链接:https://shuechaolau.iteye.com/blog/1558046
1 概述 Android的设计理念之一,便是应用程序退出,但进程还会继续存在系统以便...Android基于Linux的系统,其实Linux有类似的内存管理策略——OOM killer,全称(Out Of Memory Killer), OOM的策略更多的是用于分配内存
关于Android out of memory错误的分析
前面一节重点分享了Linux的内存分配策略,基于上述的分配策略,为了规避超售的风险,Linux采了一种OOM Killer的机制,即系统可用内存(包括Swap)即将使用完之前,选择性的Kill掉一些进程以求释放一些内存
Linux系统的OOM Killer处理机制.docx
kubernetes-oom-event-generator 容器启动时生成Kubernetes事件,并指示该容器先前已被杀死。设计控制器侦听Kubernetes API中的新事件和事件更改。 每次收到有关事件的通知时,它都会根据事件的Reason和所涉及对象的...
Android内存回收机制策略 1、GC 2、lowmemorykiller GC GC是java虚拟机的内存...OOM(Out Of Memory) : Android内存管理机制及优化方法(https://www.2cto.com/kf/201805/741791.html) 简言之,即应用占用的最大内存
如果不能使用,请修改根目录下的project.property的android:target为你当前有的target(不知道怎么改的同学可以从8到21一个个数字去试哦) ...但打开时无自动聚焦,这个问题有需要的同学可以自己加上去哦。...
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory 1: node::Abort() [node] 2: 0x8cd49c [node] 3: v8::Utils::ReportOOMFailure(char const*, bool) [node] 4: v8::...
Mar 9 11:29:16 xxxxxx kernel: mysqld invoked oom-killer: gfp_mask=0x201da, order=0, oom_adj=0, oom_score_adj=0 Mar 9 11:29:16 xxxxxx kernel: mysqld cpuset=/ mems_allowed=0 Mar 9 11:29:16 x
事件驱动解析是把文件转换成xml,然后一边读取一边解析,这样就对内存的占用就会很少,可以很好的处理poi出现OOM的问题。 maven添加需要的jar包 <groupId>org.apache.poi <artifactId>poi <version>3.15 ...
jvm java oom分析 OutOfMemory 内存溢出分析工具
heart_oom_protect 一个Erlang OTP库,可保护心脏免于被Linux内核的OOM Killer杀死 建造 $ rebar3 compile
OOM全称”Out Of Memory”,即内存溢出。 内存溢出已经是软件开发历史上存在了近40年的“老大难”问题。在操作系统上运行各种软件时,软件所需申请的内存远远超出了物理内存所承受的大小,就叫内存溢出。 内存溢出...
android图片墙,解决oom 博客地址: http://blog.csdn.net/pangzaifei/article/details/37763753