I've got a sudden issue with iptables not running on my CentOS 5.8/DirectAdmin XenVPS. All I have done today is install PHP APC and run an update (although I admittedly didn't pay much attention today - I usually do). Iptables has been running fairly smoothly since I installed it over 6 months ago.
Basically when I try to run iptables -L it tells me:
iptables v1.3.5: can't initialize iptables table `filter': iptables who? (do you need to insmod?) Perhaps iptables or your kernel needs to be upgraded.
I've looked around and tried a few things and it appears that maybe my kernel doesn't have the modules loaded? I've been reading this and tried the two commands they suggest to no avail. Except there does appear to be a mismatch on one bit of output:
-bash-3.2# cd /lib/modules -bash-3.2# ls 2.6.18-194.32.1.el5xen 2.6.18-238.5.1.el5xen 2.6.18-274.7.1.el5xen 184.108.40.206-cs-domU 2.6.18-238.12.1.el5xen 2.6.18-238.9.1.el5xen 220.127.116.11-cs-domU 3.0.1-cs-domU -bash-3.2# depmod -a WARNING: Couldn't open directory /lib/modules/2.6.18-274.18.1.el5xen: No such file or directory FATAL: Could not open /lib/modules/2.6.18-274.18.1.el5xen/modules.dep.temp for writing: No such file or directory
Does this mean the versions are out of sync? If so, what are my next steps to getting this fixed?
As you can probably tell I am still learning how to manage my server so please be very clear in all advice.
Many thanks :)
EDIT: Results of running uname -a as requested.
Linux server1.fortheinter.net 2.6.18-274.18.1.el5xen #1 SMP Thu Feb 9 13:27:02 EST 2012 x86_64 x86_64 x86_64 GNU/Linux
EDIT 2: Results of checking the package list.
-bash-3.2# yum list | grep kernel kernel-headers.x86_64 2.6.18-308.1.1.el5 installed kernel.x86_64 2.6.18-308.1.1.el5 updates kernel-debug.x86_64 2.6.18-308.1.1.el5 updates kernel-debug-devel.x86_64 2.6.18-308.1.1.el5 updates kernel-devel.x86_64 2.6.18-308.1.1.el5 updates kernel-doc.noarch 2.6.18-308.1.1.el5 updates kernel-xen.x86_64 2.6.18-308.1.1.el5 updates kernel-xen-devel.x86_64 2.6.18-308.1.1.el5 updates yum-kernel-module.noarch 1.1.16-21.el5.centos base