公司在美国托管的某台服务器出现异常,异常现象如下:
  1. load average 30+ 以上
  2. service iptables start 无法启动,同时大量iptable进行在后台运行(60个)
Linux iptables-config配置导致iptables服务无法启动
 
判断过程:
  1. 起初认为是一个综合性问题,因为该服务器运行的服务较多,环境也比较复杂,访问量也非常大。 
  2. 安装sysstat软件包,yum install sysstat ,发现安装软件过程非常顺利,不太像一台load 30+应用服务器应有的反馈。后来通过iostat,mpstat,vmstat命令确实证明了load高的瓶颈不在io
  3. killall kill iptables进程无效。通过手工kill无法生效。目标确定在iptables上。
  4. 最终结果:发现/etc/sysconfig/iptables-config配置项:
Linux iptables-config配置导致iptables服务无法启动# Unload modules on restart and stop
Linux iptables-config配置导致iptables服务无法启动#     Value: yes|no,    default: yes
Linux iptables-config配置导致iptables服务无法启动# This option has to be 'yes' to get to a sane state for a firewall
Linux iptables-config配置导致iptables服务无法启动# restart or stop. Only set to 'no' if there are problems unloading netfilter
Linux iptables-config配置导致iptables服务无法启动# modules.
Linux iptables-config配置导致iptables服务无法启动IPTABLES_MODULES_UNLOAD="no"
       就是这个“no”,导致了iptables服务在重启和关闭,需要卸载相关模块时出现异常。RadHat系列linux,如果iptables过滤模块要生效,默认是使用netfiler模块的。如果设置为“no”,就会导致如上截图所显示 modprobe -q --iptbls_filter 产生30个锁死进程,引起load达到30。
   
      感慨和总结:现网模块默认配置文件,不敢修改啊!!!出人命的!!!
 
 
 

转载于:https://blog.51cto.com/jinpeng/1093850

相关文章:

  • 2022-12-23
  • 2021-09-25
  • 2021-12-01
  • 2022-01-30
  • 2021-04-28
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-03-04
  • 2022-12-23
  • 2021-09-26
  • 2021-05-25
  • 2022-12-23
  • 2021-12-04
  • 2021-08-22
相关资源
相似解决方案