Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Running service iptables (start|stop|restart) isn't displaying the usual [FAILED]|[SUCCESS] messages I'm used to on previous machines. This is a new server, but I've updated everything via yum (I'm running CentOS 6.2). This isn't really a problem, per se, but it's slightly bugging me. Anyone know what's up?

EDIT: Also, it seems I don't have an /etc/sysconfig/iptables This is strange.

share|improve this question
up vote 2 down vote accepted

What you are seeing is normal for the case of a missing /etc/sysconfig/iptables file. If you check the $? exit code for service iptables start | restart it will be 6

# Do not start if there is no config file.
[ ! -f "$IPTABLES_DATA" ] && return 6

The stop function subsequently has nothing to do so just exit's with 0

# Do not stop if iptables module is not loaded.
[ ! -e "$PROC_IPTABLES_NAMES" ] && return 0

So it's all good.

share|improve this answer
Well, I imported a /etc/sysconfig/iptables from one of my other servers, and like you said, that fixed it. Green checkmark for you! Thanks! However, isn't iptables supposed to manually generate that? Any idea why it didn't? – Rob Jul 8 '12 at 8:46

strace service iptables, getenforce to see the SELinux and id to check you are root

share|improve this answer
or you could just read the /etc/init.d/iptables script and see what's happening. – Iain Jul 8 '12 at 8:10
I'd go /bin/bash -x before I launched straight into strace. – womble Jul 8 '12 at 8:36

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.