#### 故障描述
启动机器上部署的服务时,会报错 Cannot allocate memory - fork(2)
#### 故障分析
1. 检查dmesg日志
2. 检查message日志
3. 检查内存硬件错误
#### 日志信息
# less /var/log/message
Aug 24 16:36:49 bjsjs_71_73 puppet-agent[74662]: Certificate Re quest fingerprint (SHA256): DF:AF:04:3E:66:F5:98:02:F2:17:11:19 :64:27:DC:F1:DE:15:49:14:27:3B:BD:1E:80:76:7D:C7:35:41:44:3A
Aug 24 16:36:50 bjsjs_71_73 puppet-agent[74662]: Caching certif icate for ca
Aug 24 16:37:26 bjsjs_71_73 puppet-agent[77199]: Caching certif icate for nm003.shopping.hadoop.sjs.ted
Aug 24 16:37:26 bjsjs_71_73 puppet-agent[77199]: Caching certif icate_revocation_list for ca
Aug 24 16:37:26 bjsjs_71_73 puppet-agent[77199]: Caching certif icate for nm003.shopping.hadoop.sjs.ted
Aug 24 16:37:26 bjsjs_71_73 puppet-agent[77199]: Unable to fetc h my node definition, but the agent run will continue:
Aug 24 16:37:26 bjsjs_71_73 puppet-agent[77199]: Error 400 on S ERVER: Cannot allocate memory - fork(2)
Aug 24 16:37:26 bjsjs_71_73 puppet-agent[77199]: Retrieving plu ginfacts
Aug 24 16:37:26 bjsjs_71_73 puppet-agent[77199]: Retrieving plu gin
#### 结论
1. 这边检查时,无法复现。(未重复,故障消失)
2. 很有可能就是应用占用内存过多,没释放,导致新申请内存失败
3. 不排除某些内核参数设置不适合当前应用,导致内存充足,但应用申请内存失败
文章最后更新时间:
2017年05月17日 23:24:11